1#ifndef YAZE_APP_EDITOR_OVERWORLD_MAP_PROPERTIES_H
2#define YAZE_APP_EDITOR_OVERWORLD_MAP_PROPERTIES_H
8#include "absl/status/status.h"
9#include "absl/status/statusor.h"
23struct SharedClipboard;
39 const std::vector<OverworldPropertyEdit>&,
const std::string&)>;
41 std::function<absl::Status(
const std::string&,
int,
const std::string&)>;
45 std::array<gfx::Bitmap, zelda3::kNumOverworldMaps>* maps_bmp =
nullptr,
46 gui::Canvas* canvas =
nullptr,
int* game_state =
nullptr)
69 std::function<
void(
const std::string&)> insert_callback) {
100 bool& current_map_lock,
101 bool& show_map_properties_panel,
102 bool& show_custom_bg_color_editor,
103 bool& show_overlay_editor,
bool& show_overlay_preview,
110 bool& show_custom_bg_color_editor);
116 bool show_overlay_preview);
120 bool& current_map_lock,
121 bool& show_map_properties_panel,
122 bool& show_custom_bg_color_editor,
123 bool& show_overlay_editor,
int current_mode = 0,
129 const std::vector<OverworldPropertyEdit>& edits,
130 const std::string& description = {});
133 const OverworldPropertyEdit& edit)
const;
135 const OverworldPropertyEdit& edit)
const;
151 bool& show_custom_bg_color_editor);
153 bool& show_overlay_preview,
int& game_state);
179 std::array<gfx::Bitmap, zelda3::kNumOverworldMaps>*
maps_bmp_;
The Rom class is used to load, save, and modify Rom data. This is a generic SNES ROM container and do...
ResourceLabelEditCallback resource_label_edit_callback_
void PrepareMapForGraphicsRefresh(int map_index)
absl::Status ApplyPropertyEdit(const OverworldPropertyEdit &edit)
RefreshCallback refresh_overworld_map_
std::array< gfx::Bitmap, zelda3::kNumOverworldMaps > * maps_bmp_
std::function< void()> RefreshCallback
std::function< void()> edit_tile16_callback_
void RefreshMapProperties()
void SetPropertyEditCallback(PropertyEditCallback callback)
void DrawOverlayEditor(int current_map, bool &show_overlay_editor)
PropertyEditBatchCallback property_edit_batch_callback_
void DrawPropertiesPopup(int current_map, bool &show_map_properties_panel, bool &show_overlay_preview, int &game_state)
void SetTile16EditCallback(std::function< void()> callback)
std::function< bool()> sample_tile16_callback_
RefreshCallback refresh_map_properties_
std::function< void(int, bool)> map_selection_callback_
void RefreshOverworldMap()
RefreshPaletteCallback refresh_tile16_blockset_
void DrawOverlayPreviewOnMap(int current_map, int current_world, bool show_overlay_preview)
absl::Status ApplyPropertyEdits(const std::vector< OverworldPropertyEdit > &edits, const std::string &description={})
absl::Status CheckPropertyEditSupported(const OverworldPropertyEdit &edit) const
void SetEntityCallbacks(std::function< void(const std::string &)> insert_callback)
void DrawMosaicControls(int current_map)
void DrawMapPropertiesPanel(int current_map, bool &show_map_properties_panel)
void SetResourceLabelEditCallback(ResourceLabelEditCallback callback)
MapPropertiesSystem(zelda3::Overworld *overworld, Rom *rom, std::array< gfx::Bitmap, zelda3::kNumOverworldMaps > *maps_bmp=nullptr, gui::Canvas *canvas=nullptr, int *game_state=nullptr)
std::function< void(int)> ForceRefreshGraphicsCallback
absl::Status RefreshTile16Blockset()
void SetTile16SampleCallback(std::function< bool()> callback)
void SetPropertyEditBatchCallback(PropertyEditBatchCallback callback)
void SetRefreshCallbacks(RefreshCallback refresh_map_properties, RefreshCallback refresh_overworld_map, RefreshPaletteCallback refresh_map_palette, RefreshPaletteCallback refresh_tile16_blockset=nullptr, ForceRefreshGraphicsCallback force_refresh_graphics=nullptr)
std::function< void(const std::string &) entity_insert_callback_)
void DrawSpritePropertiesTab(int current_map)
void DrawToolsPopup(int ¤t_mode)
RefreshPaletteCallback refresh_map_palette_
void DrawMusicTab(int current_map)
void DrawBasicPropertiesTab(int current_map)
void DrawCustomFeaturesTab(int current_map)
int CurrentGameState() const
void DrawPalettesPopup(int current_map, int game_state, bool &show_custom_bg_color_editor)
void SetCurrentGameState(int game_state)
void SetupCanvasContextMenu(gui::Canvas &canvas, int current_map, bool ¤t_map_lock, bool &show_map_properties_panel, bool &show_custom_bg_color_editor, bool &show_overlay_editor, int current_mode=0, project::YazeProject *project=nullptr, SharedClipboard *shared_clipboard=nullptr)
void DrawCustomBackgroundColorEditor(int current_map, bool &show_custom_bg_color_editor)
std::function< absl::Status(const OverworldPropertyEdit &)> PropertyEditCallback
absl::StatusOr< int > ReadPropertyValue(const OverworldPropertyEdit &edit) const
std::function< absl::Status( const std::vector< OverworldPropertyEdit > &, const std::string &)> PropertyEditBatchCallback
void DrawCanvasToolbar(int ¤t_world, int ¤t_map, bool ¤t_map_lock, bool &show_map_properties_panel, bool &show_custom_bg_color_editor, bool &show_overlay_editor, bool &show_overlay_preview, int &game_state, EditingMode ¤t_mode, EntityEditMode &entity_edit_mode)
std::function< absl::Status(const std::string &, int, const std::string &)> ResourceLabelEditCallback
absl::Status ApplyPropertyEditDirect(const OverworldPropertyEdit &edit)
zelda3::Overworld * overworld_
void SetMapSelectionCallback(std::function< void(int, bool)> callback)
void ForceRefreshGraphics(int map_index)
std::function< absl::Status()> RefreshPaletteCallback
void RefreshSiblingMapGraphics(int map_index, bool include_self=false)
void DrawTileGraphicsTab(int current_map)
ForceRefreshGraphicsCallback force_refresh_graphics_
void DrawQuickAccessPopup()
std::string GetOverlayDescription(uint16_t overlay_id)
PropertyEditCallback property_edit_callback_
void DrawOverlayControls(int current_map, bool &show_overlay_preview)
absl::Status RefreshMapPalette()
void DrawGraphicsPopup(int current_map, int game_state)
Modern, robust canvas for drawing and manipulating graphics.
Represents the full Overworld data, light and dark world.
Modern project structure with comprehensive settings consolidation.