move zelda3 directory to src from app
This commit is contained in:
@@ -61,7 +61,7 @@ include(util/util.cmake)
|
||||
include(app/gfx/gfx_library.cmake)
|
||||
include(app/net/net_library.cmake)
|
||||
include(app/gui/gui_library.cmake)
|
||||
include(app/zelda3/zelda3_library.cmake)
|
||||
include(zelda3/zelda3_library.cmake)
|
||||
include(app/core/core_library.cmake)
|
||||
|
||||
# Include test support library BEFORE yaze_editor so it can link against it
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
#include "util/platform_paths.h"
|
||||
#include "app/gui/icons.h"
|
||||
#include "util/log.h"
|
||||
#include "app/zelda3/zelda3_labels.h"
|
||||
#include "zelda3/zelda3_labels.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include "yaze_config.h"
|
||||
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/gui/input.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include "util/log.h"
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "dungeon_object_interaction.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/gfx/arena.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "app/gui/icons.h"
|
||||
#include "app/gui/input.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
#include "dungeon_room_loader.h"
|
||||
#include "object_editor_card.h"
|
||||
#include "app/gui/editor_card_manager.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/dungeon/room_entrance.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room_entrance.h"
|
||||
#include "app/gui/editor_layout.h"
|
||||
#include "app/gui/widgets/dungeon_object_emulator_preview.h"
|
||||
#include "app/gui/widgets/palette_editor_widget.h"
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
|
||||
#include "imgui/imgui.h"
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace editor {
|
||||
|
||||
@@ -10,9 +10,9 @@
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/gui/modules/asset_browser.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/dungeon/dungeon_editor_system.h"
|
||||
#include "app/zelda3/dungeon/dungeon_object_editor.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/dungeon_editor_system.h"
|
||||
#include "zelda3/dungeon/dungeon_object_editor.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
namespace yaze::editor {
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/rom.h"
|
||||
// object_renderer.h removed - using ObjectDrawer for production rendering
|
||||
#include "app/zelda3/dungeon/dungeon_object_editor.h"
|
||||
#include "app/zelda3/dungeon/dungeon_editor_system.h"
|
||||
#include "zelda3/dungeon/dungeon_object_editor.h"
|
||||
#include "zelda3/dungeon/dungeon_editor_system.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
|
||||
#include "app/gfx/performance/performance_profiler.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "util/log.h"
|
||||
|
||||
namespace yaze::editor {
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
|
||||
#include "absl/status/status.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/dungeon/room_entrance.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room_entrance.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace editor {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#include "dungeon_room_selector.h"
|
||||
|
||||
#include "app/gui/input.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/dungeon/room_entrance.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room_entrance.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include "util/hex.h"
|
||||
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
#include <functional>
|
||||
#include "imgui/imgui.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room_entrance.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room_entrance.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace editor {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
#define YAZE_APP_EDITOR_DUNGEON_DUNGEON_USAGE_TRACKER_H
|
||||
|
||||
#include "absl/container/flat_hash_map.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace editor {
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
#include "app/gui/editor_layout.h"
|
||||
#include "app/gui/widgets/dungeon_object_emulator_preview.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace editor {
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
#include "app/gui/theme_manager.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/test/test_manager.h"
|
||||
#include "app/zelda3/overworld/overworld_map.h"
|
||||
#include "zelda3/overworld/overworld_map.h"
|
||||
#ifdef YAZE_ENABLE_TESTING
|
||||
#include "app/test/e2e_test_suite.h"
|
||||
#include "app/test/integrated_test_suite.h"
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
#include "app/gui/editor_layout.h"
|
||||
#include "app/gui/modules/asset_browser.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include "imgui_memory_editor.h"
|
||||
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
#include "app/gfx/tilemap.h"
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/screen/dungeon_map.h"
|
||||
#include "app/zelda3/screen/inventory.h"
|
||||
#include "zelda3/screen/dungeon_map.h"
|
||||
#include "zelda3/screen/inventory.h"
|
||||
#include "app/gui/editor_layout.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "app/gui/editor_card_manager.h"
|
||||
#include "app/gui/editor_layout.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/music/tracker.h"
|
||||
#include "zelda3/music/tracker.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
namespace yaze {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
#ifndef YAZE_APP_EDITOR_OVERWORLD_ENTITY_H
|
||||
#define YAZE_APP_EDITOR_OVERWORLD_ENTITY_H
|
||||
|
||||
#include "app/zelda3/common.h"
|
||||
#include "app/zelda3/overworld/overworld_entrance.h"
|
||||
#include "app/zelda3/overworld/overworld_exit.h"
|
||||
#include "app/zelda3/overworld/overworld_item.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "zelda3/overworld/overworld_entrance.h"
|
||||
#include "zelda3/overworld/overworld_exit.h"
|
||||
#include "zelda3/overworld/overworld_item.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
namespace yaze {
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "app/gui/color.h"
|
||||
#include "app/gui/icons.h"
|
||||
#include "app/gui/input.h"
|
||||
#include "app/zelda3/overworld/overworld_map.h"
|
||||
#include "zelda3/overworld/overworld_map.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
namespace yaze {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
#include <functional>
|
||||
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/gui/canvas.h"
|
||||
|
||||
|
||||
@@ -31,9 +31,9 @@
|
||||
#include "app/gui/style.h"
|
||||
#include "app/gui/ui_helpers.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/common.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "app/zelda3/overworld/overworld_map.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld_map.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include "imgui_memory_editor.h"
|
||||
#include "util/file_util.h"
|
||||
|
||||
@@ -1,382 +1,382 @@
|
||||
#ifndef YAZE_APP_EDITOR_OVERWORLDEDITOR_H
|
||||
#define YAZE_APP_EDITOR_OVERWORLDEDITOR_H
|
||||
|
||||
#include "absl/status/status.h"
|
||||
#include "app/editor/editor.h"
|
||||
#include "app/editor/graphics/gfx_group_editor.h"
|
||||
#include "app/editor/palette/palette_editor.h"
|
||||
#include "app/gui/editor_card_manager.h"
|
||||
#include "app/editor/overworld/tile16_editor.h"
|
||||
#include "app/editor/overworld/map_properties.h"
|
||||
#include "app/editor/overworld/overworld_entity_renderer.h"
|
||||
#include "app/gfx/bitmap.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/gfx/tilemap.h"
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/gui/widgets/tile_selector_widget.h"
|
||||
#include "app/gui/input.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include <mutex>
|
||||
|
||||
namespace yaze {
|
||||
namespace editor {
|
||||
|
||||
constexpr unsigned int k4BPP = 4;
|
||||
constexpr unsigned int kByteSize = 3;
|
||||
constexpr unsigned int kMessageIdSize = 5;
|
||||
constexpr unsigned int kNumSheetsToLoad = 223;
|
||||
constexpr unsigned int kOverworldMapSize = 0x200;
|
||||
constexpr ImVec2 kOverworldCanvasSize(kOverworldMapSize * 8,
|
||||
kOverworldMapSize * 8);
|
||||
constexpr ImVec2 kCurrentGfxCanvasSize(0x100 + 1, 0x10 * 0x40 + 1);
|
||||
constexpr ImVec2 kBlocksetCanvasSize(0x100 + 1, 0x4000 + 1);
|
||||
constexpr ImVec2 kGraphicsBinCanvasSize(0x100 + 1, kNumSheetsToLoad * 0x40 + 1);
|
||||
|
||||
constexpr ImGuiTableFlags kOWMapFlags =
|
||||
ImGuiTableFlags_Borders | ImGuiTableFlags_Resizable |
|
||||
ImGuiTableFlags_RowBg | ImGuiTableFlags_SizingStretchProp;
|
||||
|
||||
constexpr absl::string_view kWorldList =
|
||||
"Light World\0Dark World\0Extra World\0";
|
||||
|
||||
constexpr absl::string_view kGamePartComboString = "Part 0\0Part 1\0Part 2\0";
|
||||
|
||||
constexpr absl::string_view kOWMapTable = "#MapSettingsTable";
|
||||
|
||||
/**
|
||||
* @class OverworldEditor
|
||||
* @brief Manipulates the Overworld and OverworldMap data in a Rom.
|
||||
*
|
||||
* The `OverworldEditor` class is responsible for managing the editing and
|
||||
* manipulation of the overworld in a game. The user can drag and drop tiles,
|
||||
* modify OverworldEntrance, OverworldExit, Sprite, and OverworldItem
|
||||
* as well as change the gfx and palettes used in each overworld map.
|
||||
*
|
||||
* The Overworld itself is a series of bitmap images which exist inside each
|
||||
* OverworldMap object. The drawing of the overworld is done using the Canvas
|
||||
* class in conjunction with these underlying Bitmap objects.
|
||||
*
|
||||
* Provides access to the GfxGroupEditor and Tile16Editor through popup windows.
|
||||
*
|
||||
*/
|
||||
class OverworldEditor : public Editor, public gfx::GfxContext {
|
||||
public:
|
||||
explicit OverworldEditor(Rom* rom) : rom_(rom) {
|
||||
type_ = EditorType::kOverworld;
|
||||
gfx_group_editor_.set_rom(rom);
|
||||
// MapPropertiesSystem will be initialized after maps_bmp_ and canvas are ready
|
||||
}
|
||||
|
||||
void Initialize(gfx::IRenderer* renderer, Rom* rom);
|
||||
void Initialize() override;
|
||||
absl::Status Load() override;
|
||||
absl::Status Update() final;
|
||||
absl::Status Undo() override { return absl::UnimplementedError("Undo"); }
|
||||
absl::Status Redo() override { return absl::UnimplementedError("Redo"); }
|
||||
absl::Status Cut() override { return absl::UnimplementedError("Cut"); }
|
||||
absl::Status Copy() override;
|
||||
absl::Status Paste() override;
|
||||
absl::Status Find() override { return absl::UnimplementedError("Find"); }
|
||||
absl::Status Save() override;
|
||||
absl::Status Clear() override;
|
||||
zelda3::Overworld& overworld() { return overworld_; }
|
||||
|
||||
/**
|
||||
* @brief Apply ZSCustomOverworld ASM patch to upgrade ROM version
|
||||
*/
|
||||
absl::Status ApplyZSCustomOverworldASM(int target_version);
|
||||
|
||||
/**
|
||||
* @brief Update ROM version markers and feature flags after ASM patching
|
||||
*/
|
||||
absl::Status UpdateROMVersionMarkers(int target_version);
|
||||
|
||||
int jump_to_tab() { return jump_to_tab_; }
|
||||
int jump_to_tab_ = -1;
|
||||
|
||||
// ROM state methods (from Editor base class)
|
||||
bool IsRomLoaded() const override { return rom_ && rom_->is_loaded(); }
|
||||
std::string GetRomStatus() const override {
|
||||
if (!rom_) return "No ROM loaded";
|
||||
if (!rom_->is_loaded()) return "ROM failed to load";
|
||||
return absl::StrFormat("ROM loaded: %s", rom_->title());
|
||||
}
|
||||
|
||||
// Jump-to functionality
|
||||
void set_current_map(int map_id) {
|
||||
if (map_id >= 0 && map_id < zelda3::kNumOverworldMaps) {
|
||||
current_map_ = map_id;
|
||||
current_world_ = map_id / 0x40; // Calculate which world the map belongs to
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Load the Bitmap objects for each OverworldMap.
|
||||
*
|
||||
* Calls the Overworld class to load the image data and palettes from the Rom,
|
||||
* then renders the area graphics and tile16 blockset Bitmap objects before
|
||||
* assembling the OverworldMap Bitmap objects.
|
||||
*/
|
||||
absl::Status LoadGraphics();
|
||||
|
||||
private:
|
||||
void DrawFullscreenCanvas();
|
||||
void DrawToolset();
|
||||
|
||||
void RefreshChildMap(int map_index);
|
||||
void RefreshOverworldMap();
|
||||
void RefreshOverworldMapOnDemand(int map_index);
|
||||
void RefreshChildMapOnDemand(int map_index);
|
||||
void RefreshMultiAreaMapsSafely(int map_index, zelda3::OverworldMap* map);
|
||||
absl::Status RefreshMapPalette();
|
||||
void RefreshMapProperties();
|
||||
absl::Status RefreshTile16Blockset();
|
||||
void ForceRefreshGraphics(int map_index);
|
||||
void RefreshSiblingMapGraphics(int map_index, bool include_self = false);
|
||||
|
||||
void DrawOverworldMaps();
|
||||
void DrawOverworldEdits();
|
||||
void RenderUpdatedMapBitmap(const ImVec2& click_position,
|
||||
const std::vector<uint8_t>& tile_data);
|
||||
|
||||
/**
|
||||
* @brief Check for changes to the overworld map.
|
||||
*
|
||||
* This function either draws the tile painter with the current tile16 or
|
||||
* group of tile16 data with ow_map_canvas_ and DrawOverworldEdits or it
|
||||
* checks for left mouse button click/drag to select a tile16 or group of
|
||||
* tile16 data from the overworld map canvas. Similar to ZScream selection.
|
||||
*/
|
||||
void CheckForOverworldEdits();
|
||||
|
||||
/**
|
||||
* @brief Draw and create the tile16 IDs that are currently selected.
|
||||
*/
|
||||
void CheckForSelectRectangle();
|
||||
|
||||
// Selected tile IDs for rectangle operations (moved from local static)
|
||||
std::vector<int> selected_tile16_ids_;
|
||||
|
||||
/**
|
||||
* @brief Check for changes to the overworld map. Calls RefreshOverworldMap
|
||||
* and RefreshTile16Blockset on the current map if it is modified and is
|
||||
* actively being edited.
|
||||
*/
|
||||
absl::Status CheckForCurrentMap();
|
||||
void CheckForMousePan();
|
||||
void DrawOverworldCanvas();
|
||||
|
||||
absl::Status DrawTile16Selector();
|
||||
void DrawTile8Selector();
|
||||
absl::Status DrawAreaGraphics();
|
||||
void UpdateBlocksetSelectorState();
|
||||
|
||||
absl::Status LoadSpriteGraphics();
|
||||
|
||||
/**
|
||||
* @brief Create textures for deferred map bitmaps on demand
|
||||
*
|
||||
* This method should be called periodically to create textures for maps
|
||||
* that are needed but haven't had their textures created yet. This allows
|
||||
* for smooth loading without blocking the main thread during ROM loading.
|
||||
*/
|
||||
void ProcessDeferredTextures();
|
||||
|
||||
/**
|
||||
* @brief Ensure a specific map has its texture created
|
||||
*
|
||||
* Call this when a map becomes visible or is about to be rendered.
|
||||
* It will create the texture if it doesn't exist yet.
|
||||
*/
|
||||
void EnsureMapTexture(int map_index);
|
||||
|
||||
void DrawOverworldProperties();
|
||||
void HandleMapInteraction();
|
||||
// SetupOverworldCanvasContextMenu removed (Phase 3B) - now handled by MapPropertiesSystem
|
||||
|
||||
// Canvas pan/zoom helpers (Overworld Refactoring)
|
||||
void HandleOverworldPan();
|
||||
void HandleOverworldZoom();
|
||||
void ResetOverworldView();
|
||||
void CenterOverworldView();
|
||||
|
||||
// Canvas Automation API integration (Phase 4)
|
||||
void SetupCanvasAutomation();
|
||||
gui::Canvas* GetOverworldCanvas() { return &ow_map_canvas_; }
|
||||
|
||||
// Tile operations for automation callbacks
|
||||
bool AutomationSetTile(int x, int y, int tile_id);
|
||||
int AutomationGetTile(int x, int y);
|
||||
|
||||
/**
|
||||
* @brief Scroll the blockset canvas to show the current selected tile16
|
||||
*/
|
||||
void ScrollBlocksetCanvasToCurrentTile();
|
||||
|
||||
// Scratch space canvas methods
|
||||
absl::Status DrawScratchSpace();
|
||||
absl::Status SaveCurrentSelectionToScratch(int slot);
|
||||
absl::Status LoadScratchToSelection(int slot);
|
||||
absl::Status ClearScratchSpace(int slot);
|
||||
void DrawScratchSpaceEdits();
|
||||
void DrawScratchSpacePattern();
|
||||
void DrawScratchSpaceSelection();
|
||||
void UpdateScratchBitmapTile(int tile_x, int tile_y, int tile_id, int slot = -1);
|
||||
|
||||
absl::Status UpdateUsageStats();
|
||||
void DrawUsageGrid();
|
||||
void DrawDebugWindow();
|
||||
|
||||
enum class EditingMode {
|
||||
MOUSE, // Navigation, selection, entity management via context menu
|
||||
DRAW_TILE // Tile painting mode
|
||||
};
|
||||
|
||||
EditingMode current_mode = EditingMode::DRAW_TILE;
|
||||
EditingMode previous_mode = EditingMode::DRAW_TILE;
|
||||
|
||||
// Entity editing state (managed via context menu now)
|
||||
enum class EntityEditMode {
|
||||
NONE,
|
||||
ENTRANCES,
|
||||
EXITS,
|
||||
ITEMS,
|
||||
SPRITES,
|
||||
TRANSPORTS,
|
||||
MUSIC
|
||||
};
|
||||
|
||||
EntityEditMode entity_edit_mode_ = EntityEditMode::NONE;
|
||||
|
||||
enum OverworldProperty {
|
||||
LW_AREA_GFX,
|
||||
DW_AREA_GFX,
|
||||
LW_AREA_PAL,
|
||||
DW_AREA_PAL,
|
||||
LW_SPR_GFX_PART1,
|
||||
LW_SPR_GFX_PART2,
|
||||
DW_SPR_GFX_PART1,
|
||||
DW_SPR_GFX_PART2,
|
||||
LW_SPR_PAL_PART1,
|
||||
LW_SPR_PAL_PART2,
|
||||
DW_SPR_PAL_PART1,
|
||||
DW_SPR_PAL_PART2,
|
||||
};
|
||||
|
||||
int current_world_ = 0;
|
||||
int current_map_ = 0;
|
||||
int current_parent_ = 0;
|
||||
int current_entrance_id_ = 0;
|
||||
int current_exit_id_ = 0;
|
||||
int current_item_id_ = 0;
|
||||
int current_sprite_id_ = 0;
|
||||
int current_blockset_ = 0;
|
||||
int game_state_ = 1;
|
||||
int current_tile16_ = 0;
|
||||
int selected_entrance_ = 0;
|
||||
int selected_usage_map_ = 0xFFFF;
|
||||
|
||||
bool all_gfx_loaded_ = false;
|
||||
bool map_blockset_loaded_ = false;
|
||||
bool selected_tile_loaded_ = false;
|
||||
bool show_tile16_editor_ = false;
|
||||
bool show_gfx_group_editor_ = false;
|
||||
bool show_properties_editor_ = false;
|
||||
bool overworld_canvas_fullscreen_ = false;
|
||||
bool middle_mouse_dragging_ = false;
|
||||
bool is_dragging_entity_ = false;
|
||||
bool dragged_entity_free_movement_ = false;
|
||||
bool current_map_lock_ = false;
|
||||
bool show_custom_bg_color_editor_ = false;
|
||||
bool show_overlay_editor_ = false;
|
||||
bool use_area_specific_bg_color_ = false;
|
||||
bool show_map_properties_panel_ = false;
|
||||
bool show_overlay_preview_ = false;
|
||||
|
||||
// Card visibility states - Start hidden to prevent crash
|
||||
bool show_overworld_canvas_ = true;
|
||||
bool show_tile16_selector_ = false;
|
||||
bool show_tile8_selector_ = false;
|
||||
bool show_area_gfx_ = false;
|
||||
bool show_scratch_ = false;
|
||||
bool show_gfx_groups_ = false;
|
||||
bool show_usage_stats_ = false;
|
||||
bool show_v3_settings_ = false;
|
||||
|
||||
// Map properties system for UI organization
|
||||
std::unique_ptr<MapPropertiesSystem> map_properties_system_;
|
||||
std::unique_ptr<OverworldEntityRenderer> entity_renderer_;
|
||||
|
||||
// Scratch space for large layouts
|
||||
// Scratch space canvas for tile16 drawing (like a mini overworld)
|
||||
struct ScratchSpaceSlot {
|
||||
gfx::Bitmap scratch_bitmap;
|
||||
std::array<std::array<int, 32>, 32> tile_data; // 32x32 grid of tile16 IDs
|
||||
bool in_use = false;
|
||||
std::string name = "Empty";
|
||||
int width = 16; // Default 16x16 tiles
|
||||
int height = 16;
|
||||
// Independent selection system for scratch space
|
||||
std::vector<ImVec2> selected_tiles;
|
||||
std::vector<ImVec2> selected_points;
|
||||
bool select_rect_active = false;
|
||||
};
|
||||
std::array<ScratchSpaceSlot, 4> scratch_spaces_;
|
||||
int current_scratch_slot_ = 0;
|
||||
|
||||
gfx::Tilemap tile16_blockset_;
|
||||
|
||||
Rom* rom_;
|
||||
|
||||
gfx::IRenderer* renderer_;
|
||||
Tile16Editor tile16_editor_{rom_, &tile16_blockset_};
|
||||
GfxGroupEditor gfx_group_editor_;
|
||||
PaletteEditor palette_editor_;
|
||||
|
||||
gfx::SnesPalette palette_;
|
||||
|
||||
gfx::Bitmap selected_tile_bmp_;
|
||||
gfx::Bitmap tile16_blockset_bmp_;
|
||||
gfx::Bitmap current_gfx_bmp_;
|
||||
gfx::Bitmap all_gfx_bmp;
|
||||
|
||||
std::array<gfx::Bitmap, zelda3::kNumOverworldMaps> maps_bmp_;
|
||||
gfx::BitmapTable current_graphics_set_;
|
||||
std::vector<gfx::Bitmap> sprite_previews_;
|
||||
|
||||
// Deferred texture creation for performance optimization
|
||||
// Deferred texture management now handled by gfx::Arena::Get()
|
||||
|
||||
zelda3::Overworld overworld_{rom_};
|
||||
zelda3::OverworldBlockset refresh_blockset_;
|
||||
|
||||
zelda3::Sprite current_sprite_;
|
||||
|
||||
zelda3::OverworldEntrance current_entrance_;
|
||||
zelda3::OverworldExit current_exit_;
|
||||
zelda3::OverworldItem current_item_;
|
||||
zelda3::OverworldEntranceTileTypes entrance_tiletypes_ = {};
|
||||
|
||||
zelda3::GameEntity* current_entity_ = nullptr;
|
||||
zelda3::GameEntity* dragged_entity_ = nullptr;
|
||||
|
||||
gui::Canvas ow_map_canvas_{"OwMap", kOverworldCanvasSize,
|
||||
gui::CanvasGridSize::k64x64};
|
||||
gui::Canvas current_gfx_canvas_{"CurrentGfx", kCurrentGfxCanvasSize,
|
||||
gui::CanvasGridSize::k32x32};
|
||||
gui::Canvas blockset_canvas_{"OwBlockset", kBlocksetCanvasSize,
|
||||
gui::CanvasGridSize::k32x32};
|
||||
std::unique_ptr<gui::TileSelectorWidget> blockset_selector_;
|
||||
gui::Canvas graphics_bin_canvas_{"GraphicsBin", kGraphicsBinCanvasSize,
|
||||
gui::CanvasGridSize::k16x16};
|
||||
gui::Canvas properties_canvas_;
|
||||
gui::Canvas scratch_canvas_{"ScratchSpace", ImVec2(320, 480), gui::CanvasGridSize::k32x32};
|
||||
|
||||
absl::Status status_;
|
||||
};
|
||||
} // namespace editor
|
||||
} // namespace yaze
|
||||
|
||||
#endif
|
||||
#ifndef YAZE_APP_EDITOR_OVERWORLDEDITOR_H
|
||||
#define YAZE_APP_EDITOR_OVERWORLDEDITOR_H
|
||||
|
||||
#include "absl/status/status.h"
|
||||
#include "app/editor/editor.h"
|
||||
#include "app/editor/graphics/gfx_group_editor.h"
|
||||
#include "app/editor/palette/palette_editor.h"
|
||||
#include "app/gui/editor_card_manager.h"
|
||||
#include "app/editor/overworld/tile16_editor.h"
|
||||
#include "app/editor/overworld/map_properties.h"
|
||||
#include "app/editor/overworld/overworld_entity_renderer.h"
|
||||
#include "app/gfx/bitmap.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/gfx/tilemap.h"
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/gui/widgets/tile_selector_widget.h"
|
||||
#include "app/gui/input.h"
|
||||
#include "app/rom.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include <mutex>
|
||||
|
||||
namespace yaze {
|
||||
namespace editor {
|
||||
|
||||
constexpr unsigned int k4BPP = 4;
|
||||
constexpr unsigned int kByteSize = 3;
|
||||
constexpr unsigned int kMessageIdSize = 5;
|
||||
constexpr unsigned int kNumSheetsToLoad = 223;
|
||||
constexpr unsigned int kOverworldMapSize = 0x200;
|
||||
constexpr ImVec2 kOverworldCanvasSize(kOverworldMapSize * 8,
|
||||
kOverworldMapSize * 8);
|
||||
constexpr ImVec2 kCurrentGfxCanvasSize(0x100 + 1, 0x10 * 0x40 + 1);
|
||||
constexpr ImVec2 kBlocksetCanvasSize(0x100 + 1, 0x4000 + 1);
|
||||
constexpr ImVec2 kGraphicsBinCanvasSize(0x100 + 1, kNumSheetsToLoad * 0x40 + 1);
|
||||
|
||||
constexpr ImGuiTableFlags kOWMapFlags =
|
||||
ImGuiTableFlags_Borders | ImGuiTableFlags_Resizable |
|
||||
ImGuiTableFlags_RowBg | ImGuiTableFlags_SizingStretchProp;
|
||||
|
||||
constexpr absl::string_view kWorldList =
|
||||
"Light World\0Dark World\0Extra World\0";
|
||||
|
||||
constexpr absl::string_view kGamePartComboString = "Part 0\0Part 1\0Part 2\0";
|
||||
|
||||
constexpr absl::string_view kOWMapTable = "#MapSettingsTable";
|
||||
|
||||
/**
|
||||
* @class OverworldEditor
|
||||
* @brief Manipulates the Overworld and OverworldMap data in a Rom.
|
||||
*
|
||||
* The `OverworldEditor` class is responsible for managing the editing and
|
||||
* manipulation of the overworld in a game. The user can drag and drop tiles,
|
||||
* modify OverworldEntrance, OverworldExit, Sprite, and OverworldItem
|
||||
* as well as change the gfx and palettes used in each overworld map.
|
||||
*
|
||||
* The Overworld itself is a series of bitmap images which exist inside each
|
||||
* OverworldMap object. The drawing of the overworld is done using the Canvas
|
||||
* class in conjunction with these underlying Bitmap objects.
|
||||
*
|
||||
* Provides access to the GfxGroupEditor and Tile16Editor through popup windows.
|
||||
*
|
||||
*/
|
||||
class OverworldEditor : public Editor, public gfx::GfxContext {
|
||||
public:
|
||||
explicit OverworldEditor(Rom* rom) : rom_(rom) {
|
||||
type_ = EditorType::kOverworld;
|
||||
gfx_group_editor_.set_rom(rom);
|
||||
// MapPropertiesSystem will be initialized after maps_bmp_ and canvas are ready
|
||||
}
|
||||
|
||||
void Initialize(gfx::IRenderer* renderer, Rom* rom);
|
||||
void Initialize() override;
|
||||
absl::Status Load() override;
|
||||
absl::Status Update() final;
|
||||
absl::Status Undo() override { return absl::UnimplementedError("Undo"); }
|
||||
absl::Status Redo() override { return absl::UnimplementedError("Redo"); }
|
||||
absl::Status Cut() override { return absl::UnimplementedError("Cut"); }
|
||||
absl::Status Copy() override;
|
||||
absl::Status Paste() override;
|
||||
absl::Status Find() override { return absl::UnimplementedError("Find"); }
|
||||
absl::Status Save() override;
|
||||
absl::Status Clear() override;
|
||||
zelda3::Overworld& overworld() { return overworld_; }
|
||||
|
||||
/**
|
||||
* @brief Apply ZSCustomOverworld ASM patch to upgrade ROM version
|
||||
*/
|
||||
absl::Status ApplyZSCustomOverworldASM(int target_version);
|
||||
|
||||
/**
|
||||
* @brief Update ROM version markers and feature flags after ASM patching
|
||||
*/
|
||||
absl::Status UpdateROMVersionMarkers(int target_version);
|
||||
|
||||
int jump_to_tab() { return jump_to_tab_; }
|
||||
int jump_to_tab_ = -1;
|
||||
|
||||
// ROM state methods (from Editor base class)
|
||||
bool IsRomLoaded() const override { return rom_ && rom_->is_loaded(); }
|
||||
std::string GetRomStatus() const override {
|
||||
if (!rom_) return "No ROM loaded";
|
||||
if (!rom_->is_loaded()) return "ROM failed to load";
|
||||
return absl::StrFormat("ROM loaded: %s", rom_->title());
|
||||
}
|
||||
|
||||
// Jump-to functionality
|
||||
void set_current_map(int map_id) {
|
||||
if (map_id >= 0 && map_id < zelda3::kNumOverworldMaps) {
|
||||
current_map_ = map_id;
|
||||
current_world_ = map_id / 0x40; // Calculate which world the map belongs to
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Load the Bitmap objects for each OverworldMap.
|
||||
*
|
||||
* Calls the Overworld class to load the image data and palettes from the Rom,
|
||||
* then renders the area graphics and tile16 blockset Bitmap objects before
|
||||
* assembling the OverworldMap Bitmap objects.
|
||||
*/
|
||||
absl::Status LoadGraphics();
|
||||
|
||||
private:
|
||||
void DrawFullscreenCanvas();
|
||||
void DrawToolset();
|
||||
|
||||
void RefreshChildMap(int map_index);
|
||||
void RefreshOverworldMap();
|
||||
void RefreshOverworldMapOnDemand(int map_index);
|
||||
void RefreshChildMapOnDemand(int map_index);
|
||||
void RefreshMultiAreaMapsSafely(int map_index, zelda3::OverworldMap* map);
|
||||
absl::Status RefreshMapPalette();
|
||||
void RefreshMapProperties();
|
||||
absl::Status RefreshTile16Blockset();
|
||||
void ForceRefreshGraphics(int map_index);
|
||||
void RefreshSiblingMapGraphics(int map_index, bool include_self = false);
|
||||
|
||||
void DrawOverworldMaps();
|
||||
void DrawOverworldEdits();
|
||||
void RenderUpdatedMapBitmap(const ImVec2& click_position,
|
||||
const std::vector<uint8_t>& tile_data);
|
||||
|
||||
/**
|
||||
* @brief Check for changes to the overworld map.
|
||||
*
|
||||
* This function either draws the tile painter with the current tile16 or
|
||||
* group of tile16 data with ow_map_canvas_ and DrawOverworldEdits or it
|
||||
* checks for left mouse button click/drag to select a tile16 or group of
|
||||
* tile16 data from the overworld map canvas. Similar to ZScream selection.
|
||||
*/
|
||||
void CheckForOverworldEdits();
|
||||
|
||||
/**
|
||||
* @brief Draw and create the tile16 IDs that are currently selected.
|
||||
*/
|
||||
void CheckForSelectRectangle();
|
||||
|
||||
// Selected tile IDs for rectangle operations (moved from local static)
|
||||
std::vector<int> selected_tile16_ids_;
|
||||
|
||||
/**
|
||||
* @brief Check for changes to the overworld map. Calls RefreshOverworldMap
|
||||
* and RefreshTile16Blockset on the current map if it is modified and is
|
||||
* actively being edited.
|
||||
*/
|
||||
absl::Status CheckForCurrentMap();
|
||||
void CheckForMousePan();
|
||||
void DrawOverworldCanvas();
|
||||
|
||||
absl::Status DrawTile16Selector();
|
||||
void DrawTile8Selector();
|
||||
absl::Status DrawAreaGraphics();
|
||||
void UpdateBlocksetSelectorState();
|
||||
|
||||
absl::Status LoadSpriteGraphics();
|
||||
|
||||
/**
|
||||
* @brief Create textures for deferred map bitmaps on demand
|
||||
*
|
||||
* This method should be called periodically to create textures for maps
|
||||
* that are needed but haven't had their textures created yet. This allows
|
||||
* for smooth loading without blocking the main thread during ROM loading.
|
||||
*/
|
||||
void ProcessDeferredTextures();
|
||||
|
||||
/**
|
||||
* @brief Ensure a specific map has its texture created
|
||||
*
|
||||
* Call this when a map becomes visible or is about to be rendered.
|
||||
* It will create the texture if it doesn't exist yet.
|
||||
*/
|
||||
void EnsureMapTexture(int map_index);
|
||||
|
||||
void DrawOverworldProperties();
|
||||
void HandleMapInteraction();
|
||||
// SetupOverworldCanvasContextMenu removed (Phase 3B) - now handled by MapPropertiesSystem
|
||||
|
||||
// Canvas pan/zoom helpers (Overworld Refactoring)
|
||||
void HandleOverworldPan();
|
||||
void HandleOverworldZoom();
|
||||
void ResetOverworldView();
|
||||
void CenterOverworldView();
|
||||
|
||||
// Canvas Automation API integration (Phase 4)
|
||||
void SetupCanvasAutomation();
|
||||
gui::Canvas* GetOverworldCanvas() { return &ow_map_canvas_; }
|
||||
|
||||
// Tile operations for automation callbacks
|
||||
bool AutomationSetTile(int x, int y, int tile_id);
|
||||
int AutomationGetTile(int x, int y);
|
||||
|
||||
/**
|
||||
* @brief Scroll the blockset canvas to show the current selected tile16
|
||||
*/
|
||||
void ScrollBlocksetCanvasToCurrentTile();
|
||||
|
||||
// Scratch space canvas methods
|
||||
absl::Status DrawScratchSpace();
|
||||
absl::Status SaveCurrentSelectionToScratch(int slot);
|
||||
absl::Status LoadScratchToSelection(int slot);
|
||||
absl::Status ClearScratchSpace(int slot);
|
||||
void DrawScratchSpaceEdits();
|
||||
void DrawScratchSpacePattern();
|
||||
void DrawScratchSpaceSelection();
|
||||
void UpdateScratchBitmapTile(int tile_x, int tile_y, int tile_id, int slot = -1);
|
||||
|
||||
absl::Status UpdateUsageStats();
|
||||
void DrawUsageGrid();
|
||||
void DrawDebugWindow();
|
||||
|
||||
enum class EditingMode {
|
||||
MOUSE, // Navigation, selection, entity management via context menu
|
||||
DRAW_TILE // Tile painting mode
|
||||
};
|
||||
|
||||
EditingMode current_mode = EditingMode::DRAW_TILE;
|
||||
EditingMode previous_mode = EditingMode::DRAW_TILE;
|
||||
|
||||
// Entity editing state (managed via context menu now)
|
||||
enum class EntityEditMode {
|
||||
NONE,
|
||||
ENTRANCES,
|
||||
EXITS,
|
||||
ITEMS,
|
||||
SPRITES,
|
||||
TRANSPORTS,
|
||||
MUSIC
|
||||
};
|
||||
|
||||
EntityEditMode entity_edit_mode_ = EntityEditMode::NONE;
|
||||
|
||||
enum OverworldProperty {
|
||||
LW_AREA_GFX,
|
||||
DW_AREA_GFX,
|
||||
LW_AREA_PAL,
|
||||
DW_AREA_PAL,
|
||||
LW_SPR_GFX_PART1,
|
||||
LW_SPR_GFX_PART2,
|
||||
DW_SPR_GFX_PART1,
|
||||
DW_SPR_GFX_PART2,
|
||||
LW_SPR_PAL_PART1,
|
||||
LW_SPR_PAL_PART2,
|
||||
DW_SPR_PAL_PART1,
|
||||
DW_SPR_PAL_PART2,
|
||||
};
|
||||
|
||||
int current_world_ = 0;
|
||||
int current_map_ = 0;
|
||||
int current_parent_ = 0;
|
||||
int current_entrance_id_ = 0;
|
||||
int current_exit_id_ = 0;
|
||||
int current_item_id_ = 0;
|
||||
int current_sprite_id_ = 0;
|
||||
int current_blockset_ = 0;
|
||||
int game_state_ = 1;
|
||||
int current_tile16_ = 0;
|
||||
int selected_entrance_ = 0;
|
||||
int selected_usage_map_ = 0xFFFF;
|
||||
|
||||
bool all_gfx_loaded_ = false;
|
||||
bool map_blockset_loaded_ = false;
|
||||
bool selected_tile_loaded_ = false;
|
||||
bool show_tile16_editor_ = false;
|
||||
bool show_gfx_group_editor_ = false;
|
||||
bool show_properties_editor_ = false;
|
||||
bool overworld_canvas_fullscreen_ = false;
|
||||
bool middle_mouse_dragging_ = false;
|
||||
bool is_dragging_entity_ = false;
|
||||
bool dragged_entity_free_movement_ = false;
|
||||
bool current_map_lock_ = false;
|
||||
bool show_custom_bg_color_editor_ = false;
|
||||
bool show_overlay_editor_ = false;
|
||||
bool use_area_specific_bg_color_ = false;
|
||||
bool show_map_properties_panel_ = false;
|
||||
bool show_overlay_preview_ = false;
|
||||
|
||||
// Card visibility states - Start hidden to prevent crash
|
||||
bool show_overworld_canvas_ = true;
|
||||
bool show_tile16_selector_ = false;
|
||||
bool show_tile8_selector_ = false;
|
||||
bool show_area_gfx_ = false;
|
||||
bool show_scratch_ = false;
|
||||
bool show_gfx_groups_ = false;
|
||||
bool show_usage_stats_ = false;
|
||||
bool show_v3_settings_ = false;
|
||||
|
||||
// Map properties system for UI organization
|
||||
std::unique_ptr<MapPropertiesSystem> map_properties_system_;
|
||||
std::unique_ptr<OverworldEntityRenderer> entity_renderer_;
|
||||
|
||||
// Scratch space for large layouts
|
||||
// Scratch space canvas for tile16 drawing (like a mini overworld)
|
||||
struct ScratchSpaceSlot {
|
||||
gfx::Bitmap scratch_bitmap;
|
||||
std::array<std::array<int, 32>, 32> tile_data; // 32x32 grid of tile16 IDs
|
||||
bool in_use = false;
|
||||
std::string name = "Empty";
|
||||
int width = 16; // Default 16x16 tiles
|
||||
int height = 16;
|
||||
// Independent selection system for scratch space
|
||||
std::vector<ImVec2> selected_tiles;
|
||||
std::vector<ImVec2> selected_points;
|
||||
bool select_rect_active = false;
|
||||
};
|
||||
std::array<ScratchSpaceSlot, 4> scratch_spaces_;
|
||||
int current_scratch_slot_ = 0;
|
||||
|
||||
gfx::Tilemap tile16_blockset_;
|
||||
|
||||
Rom* rom_;
|
||||
|
||||
gfx::IRenderer* renderer_;
|
||||
Tile16Editor tile16_editor_{rom_, &tile16_blockset_};
|
||||
GfxGroupEditor gfx_group_editor_;
|
||||
PaletteEditor palette_editor_;
|
||||
|
||||
gfx::SnesPalette palette_;
|
||||
|
||||
gfx::Bitmap selected_tile_bmp_;
|
||||
gfx::Bitmap tile16_blockset_bmp_;
|
||||
gfx::Bitmap current_gfx_bmp_;
|
||||
gfx::Bitmap all_gfx_bmp;
|
||||
|
||||
std::array<gfx::Bitmap, zelda3::kNumOverworldMaps> maps_bmp_;
|
||||
gfx::BitmapTable current_graphics_set_;
|
||||
std::vector<gfx::Bitmap> sprite_previews_;
|
||||
|
||||
// Deferred texture creation for performance optimization
|
||||
// Deferred texture management now handled by gfx::Arena::Get()
|
||||
|
||||
zelda3::Overworld overworld_{rom_};
|
||||
zelda3::OverworldBlockset refresh_blockset_;
|
||||
|
||||
zelda3::Sprite current_sprite_;
|
||||
|
||||
zelda3::OverworldEntrance current_entrance_;
|
||||
zelda3::OverworldExit current_exit_;
|
||||
zelda3::OverworldItem current_item_;
|
||||
zelda3::OverworldEntranceTileTypes entrance_tiletypes_ = {};
|
||||
|
||||
zelda3::GameEntity* current_entity_ = nullptr;
|
||||
zelda3::GameEntity* dragged_entity_ = nullptr;
|
||||
|
||||
gui::Canvas ow_map_canvas_{"OwMap", kOverworldCanvasSize,
|
||||
gui::CanvasGridSize::k64x64};
|
||||
gui::Canvas current_gfx_canvas_{"CurrentGfx", kCurrentGfxCanvasSize,
|
||||
gui::CanvasGridSize::k32x32};
|
||||
gui::Canvas blockset_canvas_{"OwBlockset", kBlocksetCanvasSize,
|
||||
gui::CanvasGridSize::k32x32};
|
||||
std::unique_ptr<gui::TileSelectorWidget> blockset_selector_;
|
||||
gui::Canvas graphics_bin_canvas_{"GraphicsBin", kGraphicsBinCanvasSize,
|
||||
gui::CanvasGridSize::k16x16};
|
||||
gui::Canvas properties_canvas_;
|
||||
gui::Canvas scratch_canvas_{"ScratchSpace", ImVec2(320, 480), gui::CanvasGridSize::k32x32};
|
||||
|
||||
absl::Status status_;
|
||||
};
|
||||
} // namespace editor
|
||||
} // namespace yaze
|
||||
|
||||
#endif
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
#include "app/core/features.h"
|
||||
#include "app/editor/overworld/entity.h"
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/zelda3/common.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "util/hex.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
|
||||
#include "app/gfx/bitmap.h"
|
||||
#include "app/gui/canvas.h"
|
||||
#include "app/zelda3/common.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "imgui/imgui.h"
|
||||
|
||||
namespace yaze {
|
||||
|
||||
@@ -27,9 +27,9 @@
|
||||
#include "app/gui/input.h"
|
||||
#include "app/gui/style.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/common.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "app/zelda3/overworld/overworld_map.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld_map.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include "imgui_memory_editor.h"
|
||||
#include "util/hex.h"
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
#include "app/gui/input.h"
|
||||
#include "app/gui/style.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "imgui/imgui.h"
|
||||
#include "util/hex.h"
|
||||
#include "util/log.h"
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "app/gfx/arena.h"
|
||||
#include "app/gui/icons.h"
|
||||
#include "app/gui/input.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
#include "util/hex.h"
|
||||
|
||||
namespace yaze {
|
||||
|
||||
@@ -252,12 +252,11 @@ absl::Status PaletteManager::SaveGroup(const std::string& group_name) {
|
||||
auto color_it = modified_colors_[group_name].find(palette_idx);
|
||||
if (color_it != modified_colors_[group_name].end()) {
|
||||
for (int color_idx : color_it->second) {
|
||||
// Calculate ROM address
|
||||
uint32_t address =
|
||||
GetPaletteAddress(group_name, palette_idx, color_idx);
|
||||
// Calculate ROM address using the helper function
|
||||
uint32_t address = GetPaletteAddress(group_name, palette_idx, color_idx);
|
||||
|
||||
// Write color to ROM
|
||||
RETURN_IF_ERROR(rom_->WriteColor(address, (*palette)[color_idx]));
|
||||
// Write color to ROM - write the 16-bit SNES color value
|
||||
rom_->WriteShort(address, (*palette)[color_idx].snes());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#include "app/gui/widgets/dungeon_object_emulator_preview.h"
|
||||
#include "app/gfx/backend/irenderer.h"
|
||||
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
#include "app/gui/widgets/widget_auto_register.h"
|
||||
#include "app/core/window.h"
|
||||
#include <cstdio>
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/test/test_manager.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "app/editor/overworld/tile16_editor.h"
|
||||
#include "app/gui/icons.h"
|
||||
|
||||
|
||||
@@ -277,7 +277,7 @@ formatter.EndObject();
|
||||
|
||||
Command handlers are designed to work alongside the public C API defined in `incl/yaze.h` and `incl/zelda.h`.
|
||||
|
||||
- Handlers use internal C++ classes from `app/zelda3/`
|
||||
- Handlers use internal C++ classes from `zelda3/`
|
||||
- Output structures align with C API data types where possible
|
||||
- Future: C API bridge will expose commands to external applications
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
#include "absl/time/time.h"
|
||||
#include "absl/strings/string_view.h"
|
||||
#include "app/core/project.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "cli/handlers/agent/common.h"
|
||||
#include "cli/cli.h"
|
||||
#include "cli/service/ai/ai_service.h"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#include "cli/cli.h"
|
||||
#include "app/zelda3/dungeon/dungeon_editor_system.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/dungeon_editor_system.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "absl/flags/flag.h"
|
||||
#include "absl/flags/declare.h"
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
#include "absl/strings/numbers.h"
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/zelda3/dungeon/dungeon_editor_system.h"
|
||||
#include "zelda3/dungeon/dungeon_editor_system.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace cli {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#include "cli/cli.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "cli/handlers/game/overworld_inspect.h"
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
@@ -10,11 +10,11 @@
|
||||
#include "absl/strings/numbers.h"
|
||||
#include "absl/strings/str_cat.h"
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/zelda3/common.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "app/zelda3/overworld/overworld_entrance.h"
|
||||
#include "app/zelda3/overworld/overworld_exit.h"
|
||||
#include "app/zelda3/overworld/overworld_map.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld_entrance.h"
|
||||
#include "zelda3/overworld/overworld_exit.h"
|
||||
#include "zelda3/overworld/overworld_map.h"
|
||||
#include "util/macro.h"
|
||||
|
||||
namespace yaze {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
#include "absl/strings/numbers.h"
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace cli {
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
#include "absl/flags/flag.h"
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/core/project.h"
|
||||
#include "app/zelda3/zelda3_labels.h"
|
||||
#include "zelda3/zelda3_labels.h"
|
||||
|
||||
ABSL_DECLARE_FLAG(bool, mock_rom);
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace cli {
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "absl/strings/str_split.h"
|
||||
#include "absl/strings/str_cat.h"
|
||||
#include "absl/strings/numbers.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "nlohmann/json.hpp"
|
||||
#include "util/macro.h"
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
#include "app/editor/message/message_data.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/overworld/overworld.h"
|
||||
#include "zelda3/overworld/overworld.h"
|
||||
#include "yaze_config.h"
|
||||
|
||||
// Static variables for library state
|
||||
|
||||
@@ -13,9 +13,9 @@
|
||||
#include "app/gfx/bitmap.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
#include "dungeon_object_editor.h"
|
||||
|
||||
namespace yaze {
|
||||
@@ -13,8 +13,8 @@
|
||||
#include "app/gfx/bitmap.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
@@ -10,7 +10,7 @@
|
||||
#include "app/gfx/snes_tile.h"
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
@@ -4,7 +4,7 @@
|
||||
#include <cstring>
|
||||
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
#include "util/log.h"
|
||||
|
||||
// ROM addresses for object data (PC addresses, not SNES)
|
||||
@@ -10,9 +10,9 @@
|
||||
#include "app/gfx/snes_palette.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/snes.h"
|
||||
#include "app/zelda3/dungeon/object_drawer.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/dungeon/object_drawer.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
#include "util/log.h"
|
||||
|
||||
namespace yaze {
|
||||
@@ -9,10 +9,10 @@
|
||||
|
||||
#include "app/rom.h"
|
||||
#include "app/gfx/background_buffer.h"
|
||||
#include "app/zelda3/dungeon/dungeon_rom_addresses.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "app/zelda3/dungeon/room_layout.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/dungeon/dungeon_rom_addresses.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room_layout.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
#include "absl/strings/str_format.h"
|
||||
#include "app/snes.h"
|
||||
#include "app/zelda3/dungeon/dungeon_rom_addresses.h"
|
||||
#include "zelda3/dungeon/dungeon_rom_addresses.h"
|
||||
|
||||
namespace yaze::zelda3 {
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
#include "absl/status/status.h"
|
||||
#include "absl/status/statusor.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/room_object.h"
|
||||
#include "zelda3/dungeon/room_object.h"
|
||||
|
||||
namespace yaze::zelda3 {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#include "room_object.h"
|
||||
|
||||
#include "absl/status/status.h"
|
||||
#include "app/zelda3/dungeon/object_parser.h"
|
||||
#include "zelda3/dungeon/object_parser.h"
|
||||
#include "util/log.h"
|
||||
|
||||
namespace yaze {
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
#include "app/gfx/snes_tile.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/dungeon/object_parser.h"
|
||||
#include "zelda3/dungeon/object_parser.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
@@ -15,8 +15,8 @@
|
||||
#include "app/gfx/snes_tile.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/snes.h"
|
||||
#include "app/zelda3/overworld/overworld_entrance.h"
|
||||
#include "app/zelda3/overworld/overworld_exit.h"
|
||||
#include "zelda3/overworld/overworld_entrance.h"
|
||||
#include "zelda3/overworld/overworld_exit.h"
|
||||
#include "util/hex.h"
|
||||
#include "util/log.h"
|
||||
#include "util/macro.h"
|
||||
@@ -8,11 +8,11 @@
|
||||
#include "absl/status/status.h"
|
||||
#include "app/gfx/snes_tile.h"
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/overworld/overworld_entrance.h"
|
||||
#include "app/zelda3/overworld/overworld_exit.h"
|
||||
#include "app/zelda3/overworld/overworld_item.h"
|
||||
#include "app/zelda3/overworld/overworld_map.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "zelda3/overworld/overworld_entrance.h"
|
||||
#include "zelda3/overworld/overworld_exit.h"
|
||||
#include "zelda3/overworld/overworld_item.h"
|
||||
#include "zelda3/overworld/overworld_map.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
@@ -4,7 +4,7 @@
|
||||
#include <cstdint>
|
||||
|
||||
#include "app/rom.h"
|
||||
#include "app/zelda3/common.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "util/macro.h"
|
||||
|
||||
namespace yaze {
|
||||
@@ -4,7 +4,7 @@
|
||||
#include <cstdint>
|
||||
#include <iostream>
|
||||
|
||||
#include "app/zelda3/common.h"
|
||||
#include "zelda3/common.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
@@ -8,7 +8,7 @@
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include "app/zelda3/common.h"
|
||||
#include "zelda3/common.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,392 +1,392 @@
|
||||
#ifndef YAZE_APP_ZELDA3_SPRITE_H
|
||||
#define YAZE_APP_ZELDA3_SPRITE_H
|
||||
|
||||
#include <SDL.h>
|
||||
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include "app/zelda3/common.h"
|
||||
#include "app/zelda3/sprite/overlord.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
|
||||
static const std::string kSpriteDefaultNames[]{
|
||||
"00 Raven",
|
||||
"01 Vulture",
|
||||
"02 Flying Stalfos Head",
|
||||
"03 No Pointer (Empty",
|
||||
"04 Pull Switch (good",
|
||||
"05 Pull Switch (unused",
|
||||
"06 Pull Switch (bad",
|
||||
"07 Pull Switch (unused",
|
||||
"08 Octorock (one way",
|
||||
"09 Moldorm (Boss",
|
||||
"0A Octorock (four way",
|
||||
"0B Chicken",
|
||||
"0C Octorock (?",
|
||||
"0D Buzzblock",
|
||||
"0E Snapdragon",
|
||||
"0F Octoballoon",
|
||||
"10 Octoballon Hatchlings",
|
||||
"11 Hinox",
|
||||
"12 Moblin",
|
||||
"13 Mini Helmasaure",
|
||||
"14 Gargoyle's Domain Gate",
|
||||
"15 Antifairy",
|
||||
"16 Sahasrahla / Aginah",
|
||||
"17 Bush Hoarder",
|
||||
"18 Mini Moldorm",
|
||||
"19 Poe",
|
||||
"1A Dwarves",
|
||||
"1B Arrow in wall",
|
||||
"1C Statue",
|
||||
"1D Weathervane",
|
||||
"1E Crystal Switch",
|
||||
"1F Bug-Catching Kid",
|
||||
"20 Sluggula",
|
||||
"21 Push Switch",
|
||||
"22 Ropa",
|
||||
"23 Red Bari",
|
||||
"24 Blue Bari",
|
||||
"25 Talking Tree",
|
||||
"26 Hardhat Beetle",
|
||||
"27 Deadrock",
|
||||
"28 Storytellers",
|
||||
"29 Blind Hideout attendant",
|
||||
"2A Sweeping Lady",
|
||||
"2B Storytellers",
|
||||
"2C Lumberjacks",
|
||||
"2D Telepathic Stones",
|
||||
"2E Multipurpose Sprite",
|
||||
"2F Race Npc",
|
||||
"30 Person?",
|
||||
"31 Fortune Teller",
|
||||
"32 Angry Brothers",
|
||||
"33 Pull for items",
|
||||
"34 Scared Girl",
|
||||
"35 Innkeeper",
|
||||
"36 Witch",
|
||||
"37 Waterfall",
|
||||
"38 Arrow Target",
|
||||
"39 Average Middle",
|
||||
"3A Half Magic Bat",
|
||||
"3B Dash Item",
|
||||
"3C Village Kid",
|
||||
"3D Signs? Chicken lady also showed up / Scared ladies outside houses.",
|
||||
"3E Rock Hoarder",
|
||||
"3F Tutorial Soldier",
|
||||
"40 Lightning Lock",
|
||||
"41 Blue Sword Soldier / Used by guards to detect player",
|
||||
"42 Green Sword Soldier",
|
||||
"43 Red Spear Soldier",
|
||||
"44 Assault Sword Soldier",
|
||||
"45 Green Spear Soldier",
|
||||
"46 Blue Archer",
|
||||
"47 Green Archer",
|
||||
"48 Red Javelin Soldier",
|
||||
"49 Red Javelin Soldier 2",
|
||||
"4A Red Bomb Soldiers",
|
||||
"4B Green Soldier Recruits",
|
||||
"4C Geldman",
|
||||
"4D Rabbit",
|
||||
"4E Popo",
|
||||
"4F Popo 2",
|
||||
"50 Cannon Balls",
|
||||
"51 Armos",
|
||||
"52 Giant Zora",
|
||||
"53 Armos Knights (Boss",
|
||||
"54 Lanmolas (Boss",
|
||||
"55 Fireball Zora",
|
||||
"56 Walking Zora",
|
||||
"57 Desert Palace Barriers",
|
||||
"58 Crab",
|
||||
"59 Bird",
|
||||
"5A Squirrel",
|
||||
"5B Spark (Left to Right",
|
||||
"5C Spark (Right to Left",
|
||||
"5D Roller (vertical moving",
|
||||
"5E Roller (vertical moving",
|
||||
"5F Roller",
|
||||
"60 Roller (horizontal moving",
|
||||
"61 Beamos",
|
||||
"62 Master Sword",
|
||||
"63 Devalant (Non",
|
||||
"64 Devalant (Shooter",
|
||||
"65 Shooting Gallery Proprietor",
|
||||
"66 Moving Cannon Ball Shooters (Right",
|
||||
"67 Moving Cannon Ball Shooters (Left",
|
||||
"68 Moving Cannon Ball Shooters (Down",
|
||||
"69 Moving Cannon Ball Shooters (Up",
|
||||
"6A Ball N' Chain Trooper",
|
||||
"6B Cannon Soldier",
|
||||
"6C Mirror Portal",
|
||||
"6D Rat",
|
||||
"6E Rope",
|
||||
"6F Keese",
|
||||
"70 Helmasaur King Fireball",
|
||||
"71 Leever",
|
||||
"72 Activator for the ponds (where you throw in items",
|
||||
"73 Uncle / Priest",
|
||||
"74 Running Man",
|
||||
"75 Bottle Salesman",
|
||||
"76 Princess Zelda",
|
||||
"77 Antifairy (Alternate",
|
||||
"78 Village Elder",
|
||||
"79 Bee",
|
||||
"7A Agahnim",
|
||||
"7B Agahnim Energy Ball",
|
||||
"7C Hyu",
|
||||
"7D Big Spike Trap",
|
||||
"7E Guruguru Bar (Clockwise",
|
||||
"7F Guruguru Bar (Counter Clockwise",
|
||||
"80 Winder",
|
||||
"81 Water Tektite",
|
||||
"82 Antifairy Circle",
|
||||
"83 Green Eyegore",
|
||||
"84 Red Eyegore",
|
||||
"85 Yellow Stalfos",
|
||||
"86 Kodongos",
|
||||
"87 Flames",
|
||||
"88 Mothula (Boss",
|
||||
"89 Mothula's Beam",
|
||||
"8A Spike Trap",
|
||||
"8B Gibdo",
|
||||
"8C Arrghus (Boss",
|
||||
"8D Arrghus spawn",
|
||||
"8E Terrorpin",
|
||||
"8F Slime",
|
||||
"90 Wallmaster",
|
||||
"91 Stalfos Knight",
|
||||
"92 Helmasaur King",
|
||||
"93 Bumper",
|
||||
"94 Swimmers",
|
||||
"95 Eye Laser (Right",
|
||||
"96 Eye Laser (Left",
|
||||
"97 Eye Laser (Down",
|
||||
"98 Eye Laser (Up",
|
||||
"99 Pengator",
|
||||
"9A Kyameron",
|
||||
"9B Wizzrobe",
|
||||
"9C Tadpoles",
|
||||
"9D Tadpoles",
|
||||
"9E Ostrich (Haunted Grove",
|
||||
"9F Flute",
|
||||
"A0 Birds (Haunted Grove",
|
||||
"A1 Freezor",
|
||||
"A2 Kholdstare (Boss",
|
||||
"A3 Kholdstare's Shell",
|
||||
"A4 Falling Ice",
|
||||
"A5 Zazak Fireball",
|
||||
"A6 Red Zazak",
|
||||
"A7 Stalfos",
|
||||
"A8 Bomber Flying Creatures from Darkworld",
|
||||
"A9 Bomber Flying Creatures from Darkworld",
|
||||
"AA Pikit",
|
||||
"AB Maiden",
|
||||
"AC Apple",
|
||||
"AD Lost Old Man",
|
||||
"AE Down Pipe",
|
||||
"AF Up Pipe",
|
||||
"B0 Right Pip",
|
||||
"B1 Left Pipe",
|
||||
"B2 Good bee again?",
|
||||
"B3 Hylian Inscription",
|
||||
"B4 Thief?s chest (not the one that follows you",
|
||||
"B5 Bomb Salesman",
|
||||
"B6 Kiki",
|
||||
"B7 Maiden following you in Blind Dungeon",
|
||||
"B8 Monologue Testing Sprite",
|
||||
"B9 Feuding Friends on Death Mountain",
|
||||
"BA Whirlpool",
|
||||
"BB Salesman / chestgame guy / 300 rupee giver guy / Chest game thief",
|
||||
"BC Drunk in the inn",
|
||||
"BD Vitreous (Large Eyeball",
|
||||
"BE Vitreous (Small Eyeball",
|
||||
"BF Vitreous' Lightning",
|
||||
"C0 Monster in Lake of Ill Omen / Quake Medallion",
|
||||
"C1 Agahnim teleporting Zelda to dark world",
|
||||
"C2 Boulders",
|
||||
"C3 Gibo",
|
||||
"C4 Thief",
|
||||
"C5 Medusa",
|
||||
"C6 Four Way Fireball Spitters (spit when you use your sword",
|
||||
"C7 Hokku",
|
||||
"C8 Big Fairy who heals you",
|
||||
"C9 Tektite",
|
||||
"CA Chain Chomp",
|
||||
"CB Trinexx",
|
||||
"CC Another part of trinexx",
|
||||
"CD Yet another part of trinexx",
|
||||
"CE Blind The Thief (Boss)",
|
||||
"CF Swamola",
|
||||
"D0 Lynel",
|
||||
"D1 Bunny Beam",
|
||||
"D2 Flopping fish",
|
||||
"D3 Stal",
|
||||
"D4 Landmine",
|
||||
"D5 Digging Game Proprietor",
|
||||
"D6 Ganon",
|
||||
"D7 Copy of Ganon",
|
||||
"D8 Heart",
|
||||
"D9 Green Rupee",
|
||||
"DA Blue Rupee",
|
||||
"DB Red Rupee",
|
||||
"DC Bomb Refill (1)",
|
||||
"DD Bomb Refill (4)",
|
||||
"DE Bomb Refill (8)",
|
||||
"DF Small Magic Refill",
|
||||
"E0 Full Magic Refill",
|
||||
"E1 Arrow Refill (5)",
|
||||
"E2 Arrow Refill (10)",
|
||||
"E3 Fairy",
|
||||
"E4 Key",
|
||||
"E5 Big Key",
|
||||
"E6 Shield",
|
||||
"E7 Mushroom",
|
||||
"E8 Fake Master Sword",
|
||||
"E9 Magic Shop dude / His items",
|
||||
"EA Heart Container",
|
||||
"EB Heart Piece",
|
||||
"EC Bushes",
|
||||
"ED Cane Of Somaria Platform",
|
||||
"EE Mantle",
|
||||
"EF Cane of Somaria Platform (Unused)",
|
||||
"F0 Cane of Somaria Platform (Unused)",
|
||||
"F1 Cane of Somaria Platform (Unused)",
|
||||
"F2 Medallion Tablet",
|
||||
"F3",
|
||||
"F4 Falling Rocks",
|
||||
"F5",
|
||||
"F6",
|
||||
"F7",
|
||||
"F8",
|
||||
"F9",
|
||||
"FA",
|
||||
"FB",
|
||||
"FC",
|
||||
"FD",
|
||||
"FE",
|
||||
"FF",
|
||||
};
|
||||
|
||||
/**
|
||||
* @class Sprite
|
||||
* @brief A class for managing sprites in the overworld and underworld.
|
||||
*/
|
||||
class Sprite : public GameEntity {
|
||||
public:
|
||||
Sprite() = default;
|
||||
Sprite(const std::vector<uint8_t>& src, uint8_t overworld_map_id, uint8_t id,
|
||||
uint8_t x, uint8_t y, int map_x, int map_y)
|
||||
: map_id_(static_cast<int>(overworld_map_id)),
|
||||
id_(id),
|
||||
nx_(x),
|
||||
ny_(y),
|
||||
map_x_(map_x),
|
||||
map_y_(map_y),
|
||||
current_gfx_(src) {
|
||||
entity_type_ = zelda3::GameEntity::EntityType::kSprite;
|
||||
entity_id_ = id;
|
||||
x_ = map_x_;
|
||||
y_ = map_y_;
|
||||
overworld_ = true;
|
||||
name_ = kSpriteDefaultNames[id];
|
||||
preview_gfx_.resize(64 * 64, 0xFF);
|
||||
}
|
||||
|
||||
Sprite(uint8_t id, uint8_t x, uint8_t y, uint8_t subtype, uint8_t layer)
|
||||
: id_(id), nx_(x), ny_(y), subtype_(subtype), layer_(layer) {
|
||||
x_ = x;
|
||||
y_ = y;
|
||||
name_ = kSpriteDefaultNames[id];
|
||||
if (((subtype & 0x07) == 0x07) && id > 0 && id <= 0x1A) {
|
||||
name_ = kOverlordNames[id - 1];
|
||||
overlord_ = 1;
|
||||
}
|
||||
}
|
||||
|
||||
void InitSprite(const std::vector<uint8_t>& src, uint8_t overworld_map_id,
|
||||
uint8_t id, uint8_t x, uint8_t y, int map_x, int map_y) {
|
||||
current_gfx_ = src;
|
||||
overworld_ = true;
|
||||
map_id_ = static_cast<int>(overworld_map_id);
|
||||
id_ = id;
|
||||
entity_type_ = zelda3::GameEntity::EntityType::kSprite;
|
||||
entity_id_ = id;
|
||||
x_ = map_x_;
|
||||
y_ = map_y_;
|
||||
nx_ = x;
|
||||
ny_ = y;
|
||||
name_ = kSpriteDefaultNames[id];
|
||||
map_x_ = map_x;
|
||||
map_y_ = map_y;
|
||||
preview_gfx_.resize(64 * 64, 0xFF);
|
||||
}
|
||||
|
||||
void Draw();
|
||||
void DrawSpriteTile(int x, int y, int srcx, int srcy, int pal,
|
||||
bool mirror_x = false, bool mirror_y = false,
|
||||
int sizex = 2, int sizey = 2);
|
||||
|
||||
void UpdateMapProperties(uint16_t map_id) override;
|
||||
void UpdateCoordinates(int map_x, int map_y);
|
||||
|
||||
auto preview_graphics() const { return &preview_gfx_; }
|
||||
auto id() const { return id_; }
|
||||
auto set_id(uint8_t id) { id_ = id; }
|
||||
auto x() const { return x_; }
|
||||
auto y() const { return y_; }
|
||||
auto nx() const { return nx_; }
|
||||
auto ny() const { return ny_; }
|
||||
auto map_id() const { return map_id_; }
|
||||
auto map_x() const { return map_x_; }
|
||||
auto map_y() const { return map_y_; }
|
||||
auto game_state() const { return game_state_; }
|
||||
|
||||
auto layer() const { return layer_; }
|
||||
auto subtype() const { return subtype_; }
|
||||
|
||||
auto width() const { return width_; }
|
||||
auto height() const { return height_; }
|
||||
auto name() { return name_; }
|
||||
auto deleted() const { return deleted_; }
|
||||
auto set_deleted(bool deleted) { deleted_ = deleted; }
|
||||
auto set_key_drop(int key) { key_drop_ = key; }
|
||||
|
||||
private:
|
||||
uint8_t map_id_;
|
||||
uint8_t game_state_;
|
||||
uint8_t id_;
|
||||
uint8_t nx_;
|
||||
uint8_t ny_;
|
||||
uint8_t overlord_ = 0;
|
||||
uint8_t lower_x_ = 32;
|
||||
uint8_t lower_y_ = 32;
|
||||
uint8_t higher_x_ = 0;
|
||||
uint8_t higher_y_ = 0;
|
||||
|
||||
int width_ = 16;
|
||||
int height_ = 16;
|
||||
int map_x_ = 0;
|
||||
int map_y_ = 0;
|
||||
int layer_ = 0;
|
||||
int subtype_ = 0;
|
||||
int key_drop_ = 0;
|
||||
|
||||
bool deleted_ = false;
|
||||
bool overworld_;
|
||||
|
||||
std::string name_;
|
||||
std::vector<uint8_t> preview_gfx_;
|
||||
std::vector<uint8_t> current_gfx_;
|
||||
|
||||
SDL_Rect bounding_box_;
|
||||
};
|
||||
|
||||
} // namespace zelda3
|
||||
} // namespace yaze
|
||||
|
||||
#endif
|
||||
#ifndef YAZE_APP_ZELDA3_SPRITE_H
|
||||
#define YAZE_APP_ZELDA3_SPRITE_H
|
||||
|
||||
#include <SDL.h>
|
||||
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include "zelda3/common.h"
|
||||
#include "zelda3/sprite/overlord.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
|
||||
static const std::string kSpriteDefaultNames[]{
|
||||
"00 Raven",
|
||||
"01 Vulture",
|
||||
"02 Flying Stalfos Head",
|
||||
"03 No Pointer (Empty",
|
||||
"04 Pull Switch (good",
|
||||
"05 Pull Switch (unused",
|
||||
"06 Pull Switch (bad",
|
||||
"07 Pull Switch (unused",
|
||||
"08 Octorock (one way",
|
||||
"09 Moldorm (Boss",
|
||||
"0A Octorock (four way",
|
||||
"0B Chicken",
|
||||
"0C Octorock (?",
|
||||
"0D Buzzblock",
|
||||
"0E Snapdragon",
|
||||
"0F Octoballoon",
|
||||
"10 Octoballon Hatchlings",
|
||||
"11 Hinox",
|
||||
"12 Moblin",
|
||||
"13 Mini Helmasaure",
|
||||
"14 Gargoyle's Domain Gate",
|
||||
"15 Antifairy",
|
||||
"16 Sahasrahla / Aginah",
|
||||
"17 Bush Hoarder",
|
||||
"18 Mini Moldorm",
|
||||
"19 Poe",
|
||||
"1A Dwarves",
|
||||
"1B Arrow in wall",
|
||||
"1C Statue",
|
||||
"1D Weathervane",
|
||||
"1E Crystal Switch",
|
||||
"1F Bug-Catching Kid",
|
||||
"20 Sluggula",
|
||||
"21 Push Switch",
|
||||
"22 Ropa",
|
||||
"23 Red Bari",
|
||||
"24 Blue Bari",
|
||||
"25 Talking Tree",
|
||||
"26 Hardhat Beetle",
|
||||
"27 Deadrock",
|
||||
"28 Storytellers",
|
||||
"29 Blind Hideout attendant",
|
||||
"2A Sweeping Lady",
|
||||
"2B Storytellers",
|
||||
"2C Lumberjacks",
|
||||
"2D Telepathic Stones",
|
||||
"2E Multipurpose Sprite",
|
||||
"2F Race Npc",
|
||||
"30 Person?",
|
||||
"31 Fortune Teller",
|
||||
"32 Angry Brothers",
|
||||
"33 Pull for items",
|
||||
"34 Scared Girl",
|
||||
"35 Innkeeper",
|
||||
"36 Witch",
|
||||
"37 Waterfall",
|
||||
"38 Arrow Target",
|
||||
"39 Average Middle",
|
||||
"3A Half Magic Bat",
|
||||
"3B Dash Item",
|
||||
"3C Village Kid",
|
||||
"3D Signs? Chicken lady also showed up / Scared ladies outside houses.",
|
||||
"3E Rock Hoarder",
|
||||
"3F Tutorial Soldier",
|
||||
"40 Lightning Lock",
|
||||
"41 Blue Sword Soldier / Used by guards to detect player",
|
||||
"42 Green Sword Soldier",
|
||||
"43 Red Spear Soldier",
|
||||
"44 Assault Sword Soldier",
|
||||
"45 Green Spear Soldier",
|
||||
"46 Blue Archer",
|
||||
"47 Green Archer",
|
||||
"48 Red Javelin Soldier",
|
||||
"49 Red Javelin Soldier 2",
|
||||
"4A Red Bomb Soldiers",
|
||||
"4B Green Soldier Recruits",
|
||||
"4C Geldman",
|
||||
"4D Rabbit",
|
||||
"4E Popo",
|
||||
"4F Popo 2",
|
||||
"50 Cannon Balls",
|
||||
"51 Armos",
|
||||
"52 Giant Zora",
|
||||
"53 Armos Knights (Boss",
|
||||
"54 Lanmolas (Boss",
|
||||
"55 Fireball Zora",
|
||||
"56 Walking Zora",
|
||||
"57 Desert Palace Barriers",
|
||||
"58 Crab",
|
||||
"59 Bird",
|
||||
"5A Squirrel",
|
||||
"5B Spark (Left to Right",
|
||||
"5C Spark (Right to Left",
|
||||
"5D Roller (vertical moving",
|
||||
"5E Roller (vertical moving",
|
||||
"5F Roller",
|
||||
"60 Roller (horizontal moving",
|
||||
"61 Beamos",
|
||||
"62 Master Sword",
|
||||
"63 Devalant (Non",
|
||||
"64 Devalant (Shooter",
|
||||
"65 Shooting Gallery Proprietor",
|
||||
"66 Moving Cannon Ball Shooters (Right",
|
||||
"67 Moving Cannon Ball Shooters (Left",
|
||||
"68 Moving Cannon Ball Shooters (Down",
|
||||
"69 Moving Cannon Ball Shooters (Up",
|
||||
"6A Ball N' Chain Trooper",
|
||||
"6B Cannon Soldier",
|
||||
"6C Mirror Portal",
|
||||
"6D Rat",
|
||||
"6E Rope",
|
||||
"6F Keese",
|
||||
"70 Helmasaur King Fireball",
|
||||
"71 Leever",
|
||||
"72 Activator for the ponds (where you throw in items",
|
||||
"73 Uncle / Priest",
|
||||
"74 Running Man",
|
||||
"75 Bottle Salesman",
|
||||
"76 Princess Zelda",
|
||||
"77 Antifairy (Alternate",
|
||||
"78 Village Elder",
|
||||
"79 Bee",
|
||||
"7A Agahnim",
|
||||
"7B Agahnim Energy Ball",
|
||||
"7C Hyu",
|
||||
"7D Big Spike Trap",
|
||||
"7E Guruguru Bar (Clockwise",
|
||||
"7F Guruguru Bar (Counter Clockwise",
|
||||
"80 Winder",
|
||||
"81 Water Tektite",
|
||||
"82 Antifairy Circle",
|
||||
"83 Green Eyegore",
|
||||
"84 Red Eyegore",
|
||||
"85 Yellow Stalfos",
|
||||
"86 Kodongos",
|
||||
"87 Flames",
|
||||
"88 Mothula (Boss",
|
||||
"89 Mothula's Beam",
|
||||
"8A Spike Trap",
|
||||
"8B Gibdo",
|
||||
"8C Arrghus (Boss",
|
||||
"8D Arrghus spawn",
|
||||
"8E Terrorpin",
|
||||
"8F Slime",
|
||||
"90 Wallmaster",
|
||||
"91 Stalfos Knight",
|
||||
"92 Helmasaur King",
|
||||
"93 Bumper",
|
||||
"94 Swimmers",
|
||||
"95 Eye Laser (Right",
|
||||
"96 Eye Laser (Left",
|
||||
"97 Eye Laser (Down",
|
||||
"98 Eye Laser (Up",
|
||||
"99 Pengator",
|
||||
"9A Kyameron",
|
||||
"9B Wizzrobe",
|
||||
"9C Tadpoles",
|
||||
"9D Tadpoles",
|
||||
"9E Ostrich (Haunted Grove",
|
||||
"9F Flute",
|
||||
"A0 Birds (Haunted Grove",
|
||||
"A1 Freezor",
|
||||
"A2 Kholdstare (Boss",
|
||||
"A3 Kholdstare's Shell",
|
||||
"A4 Falling Ice",
|
||||
"A5 Zazak Fireball",
|
||||
"A6 Red Zazak",
|
||||
"A7 Stalfos",
|
||||
"A8 Bomber Flying Creatures from Darkworld",
|
||||
"A9 Bomber Flying Creatures from Darkworld",
|
||||
"AA Pikit",
|
||||
"AB Maiden",
|
||||
"AC Apple",
|
||||
"AD Lost Old Man",
|
||||
"AE Down Pipe",
|
||||
"AF Up Pipe",
|
||||
"B0 Right Pip",
|
||||
"B1 Left Pipe",
|
||||
"B2 Good bee again?",
|
||||
"B3 Hylian Inscription",
|
||||
"B4 Thief?s chest (not the one that follows you",
|
||||
"B5 Bomb Salesman",
|
||||
"B6 Kiki",
|
||||
"B7 Maiden following you in Blind Dungeon",
|
||||
"B8 Monologue Testing Sprite",
|
||||
"B9 Feuding Friends on Death Mountain",
|
||||
"BA Whirlpool",
|
||||
"BB Salesman / chestgame guy / 300 rupee giver guy / Chest game thief",
|
||||
"BC Drunk in the inn",
|
||||
"BD Vitreous (Large Eyeball",
|
||||
"BE Vitreous (Small Eyeball",
|
||||
"BF Vitreous' Lightning",
|
||||
"C0 Monster in Lake of Ill Omen / Quake Medallion",
|
||||
"C1 Agahnim teleporting Zelda to dark world",
|
||||
"C2 Boulders",
|
||||
"C3 Gibo",
|
||||
"C4 Thief",
|
||||
"C5 Medusa",
|
||||
"C6 Four Way Fireball Spitters (spit when you use your sword",
|
||||
"C7 Hokku",
|
||||
"C8 Big Fairy who heals you",
|
||||
"C9 Tektite",
|
||||
"CA Chain Chomp",
|
||||
"CB Trinexx",
|
||||
"CC Another part of trinexx",
|
||||
"CD Yet another part of trinexx",
|
||||
"CE Blind The Thief (Boss)",
|
||||
"CF Swamola",
|
||||
"D0 Lynel",
|
||||
"D1 Bunny Beam",
|
||||
"D2 Flopping fish",
|
||||
"D3 Stal",
|
||||
"D4 Landmine",
|
||||
"D5 Digging Game Proprietor",
|
||||
"D6 Ganon",
|
||||
"D7 Copy of Ganon",
|
||||
"D8 Heart",
|
||||
"D9 Green Rupee",
|
||||
"DA Blue Rupee",
|
||||
"DB Red Rupee",
|
||||
"DC Bomb Refill (1)",
|
||||
"DD Bomb Refill (4)",
|
||||
"DE Bomb Refill (8)",
|
||||
"DF Small Magic Refill",
|
||||
"E0 Full Magic Refill",
|
||||
"E1 Arrow Refill (5)",
|
||||
"E2 Arrow Refill (10)",
|
||||
"E3 Fairy",
|
||||
"E4 Key",
|
||||
"E5 Big Key",
|
||||
"E6 Shield",
|
||||
"E7 Mushroom",
|
||||
"E8 Fake Master Sword",
|
||||
"E9 Magic Shop dude / His items",
|
||||
"EA Heart Container",
|
||||
"EB Heart Piece",
|
||||
"EC Bushes",
|
||||
"ED Cane Of Somaria Platform",
|
||||
"EE Mantle",
|
||||
"EF Cane of Somaria Platform (Unused)",
|
||||
"F0 Cane of Somaria Platform (Unused)",
|
||||
"F1 Cane of Somaria Platform (Unused)",
|
||||
"F2 Medallion Tablet",
|
||||
"F3",
|
||||
"F4 Falling Rocks",
|
||||
"F5",
|
||||
"F6",
|
||||
"F7",
|
||||
"F8",
|
||||
"F9",
|
||||
"FA",
|
||||
"FB",
|
||||
"FC",
|
||||
"FD",
|
||||
"FE",
|
||||
"FF",
|
||||
};
|
||||
|
||||
/**
|
||||
* @class Sprite
|
||||
* @brief A class for managing sprites in the overworld and underworld.
|
||||
*/
|
||||
class Sprite : public GameEntity {
|
||||
public:
|
||||
Sprite() = default;
|
||||
Sprite(const std::vector<uint8_t>& src, uint8_t overworld_map_id, uint8_t id,
|
||||
uint8_t x, uint8_t y, int map_x, int map_y)
|
||||
: map_id_(static_cast<int>(overworld_map_id)),
|
||||
id_(id),
|
||||
nx_(x),
|
||||
ny_(y),
|
||||
map_x_(map_x),
|
||||
map_y_(map_y),
|
||||
current_gfx_(src) {
|
||||
entity_type_ = zelda3::GameEntity::EntityType::kSprite;
|
||||
entity_id_ = id;
|
||||
x_ = map_x_;
|
||||
y_ = map_y_;
|
||||
overworld_ = true;
|
||||
name_ = kSpriteDefaultNames[id];
|
||||
preview_gfx_.resize(64 * 64, 0xFF);
|
||||
}
|
||||
|
||||
Sprite(uint8_t id, uint8_t x, uint8_t y, uint8_t subtype, uint8_t layer)
|
||||
: id_(id), nx_(x), ny_(y), subtype_(subtype), layer_(layer) {
|
||||
x_ = x;
|
||||
y_ = y;
|
||||
name_ = kSpriteDefaultNames[id];
|
||||
if (((subtype & 0x07) == 0x07) && id > 0 && id <= 0x1A) {
|
||||
name_ = kOverlordNames[id - 1];
|
||||
overlord_ = 1;
|
||||
}
|
||||
}
|
||||
|
||||
void InitSprite(const std::vector<uint8_t>& src, uint8_t overworld_map_id,
|
||||
uint8_t id, uint8_t x, uint8_t y, int map_x, int map_y) {
|
||||
current_gfx_ = src;
|
||||
overworld_ = true;
|
||||
map_id_ = static_cast<int>(overworld_map_id);
|
||||
id_ = id;
|
||||
entity_type_ = zelda3::GameEntity::EntityType::kSprite;
|
||||
entity_id_ = id;
|
||||
x_ = map_x_;
|
||||
y_ = map_y_;
|
||||
nx_ = x;
|
||||
ny_ = y;
|
||||
name_ = kSpriteDefaultNames[id];
|
||||
map_x_ = map_x;
|
||||
map_y_ = map_y;
|
||||
preview_gfx_.resize(64 * 64, 0xFF);
|
||||
}
|
||||
|
||||
void Draw();
|
||||
void DrawSpriteTile(int x, int y, int srcx, int srcy, int pal,
|
||||
bool mirror_x = false, bool mirror_y = false,
|
||||
int sizex = 2, int sizey = 2);
|
||||
|
||||
void UpdateMapProperties(uint16_t map_id) override;
|
||||
void UpdateCoordinates(int map_x, int map_y);
|
||||
|
||||
auto preview_graphics() const { return &preview_gfx_; }
|
||||
auto id() const { return id_; }
|
||||
auto set_id(uint8_t id) { id_ = id; }
|
||||
auto x() const { return x_; }
|
||||
auto y() const { return y_; }
|
||||
auto nx() const { return nx_; }
|
||||
auto ny() const { return ny_; }
|
||||
auto map_id() const { return map_id_; }
|
||||
auto map_x() const { return map_x_; }
|
||||
auto map_y() const { return map_y_; }
|
||||
auto game_state() const { return game_state_; }
|
||||
|
||||
auto layer() const { return layer_; }
|
||||
auto subtype() const { return subtype_; }
|
||||
|
||||
auto width() const { return width_; }
|
||||
auto height() const { return height_; }
|
||||
auto name() { return name_; }
|
||||
auto deleted() const { return deleted_; }
|
||||
auto set_deleted(bool deleted) { deleted_ = deleted; }
|
||||
auto set_key_drop(int key) { key_drop_ = key; }
|
||||
|
||||
private:
|
||||
uint8_t map_id_;
|
||||
uint8_t game_state_;
|
||||
uint8_t id_;
|
||||
uint8_t nx_;
|
||||
uint8_t ny_;
|
||||
uint8_t overlord_ = 0;
|
||||
uint8_t lower_x_ = 32;
|
||||
uint8_t lower_y_ = 32;
|
||||
uint8_t higher_x_ = 0;
|
||||
uint8_t higher_y_ = 0;
|
||||
|
||||
int width_ = 16;
|
||||
int height_ = 16;
|
||||
int map_x_ = 0;
|
||||
int map_y_ = 0;
|
||||
int layer_ = 0;
|
||||
int subtype_ = 0;
|
||||
int key_drop_ = 0;
|
||||
|
||||
bool deleted_ = false;
|
||||
bool overworld_;
|
||||
|
||||
std::string name_;
|
||||
std::vector<uint8_t> preview_gfx_;
|
||||
std::vector<uint8_t> current_gfx_;
|
||||
|
||||
SDL_Rect bounding_box_;
|
||||
};
|
||||
|
||||
} // namespace zelda3
|
||||
} // namespace yaze
|
||||
|
||||
#endif
|
||||
@@ -1,9 +1,9 @@
|
||||
#include "app/zelda3/zelda3_labels.h"
|
||||
#include "zelda3/zelda3_labels.h"
|
||||
|
||||
#include "app/zelda3/common.h"
|
||||
#include "app/zelda3/dungeon/room.h"
|
||||
#include "app/zelda3/sprite/sprite.h"
|
||||
#include "app/zelda3/sprite/overlord.h"
|
||||
#include "zelda3/common.h"
|
||||
#include "zelda3/dungeon/room.h"
|
||||
#include "zelda3/sprite/sprite.h"
|
||||
#include "zelda3/sprite/overlord.h"
|
||||
|
||||
namespace yaze {
|
||||
namespace zelda3 {
|
||||
@@ -1,21 +1,21 @@
|
||||
set(
|
||||
YAZE_APP_ZELDA3_SRC
|
||||
app/zelda3/dungeon/dungeon_editor_system.cc
|
||||
app/zelda3/dungeon/dungeon_object_editor.cc
|
||||
app/zelda3/dungeon/object_drawer.cc
|
||||
app/zelda3/dungeon/object_parser.cc
|
||||
app/zelda3/dungeon/room.cc
|
||||
app/zelda3/dungeon/room_layout.cc
|
||||
app/zelda3/dungeon/room_object.cc
|
||||
app/zelda3/music/tracker.cc
|
||||
app/zelda3/overworld/overworld.cc
|
||||
app/zelda3/overworld/overworld_map.cc
|
||||
app/zelda3/screen/dungeon_map.cc
|
||||
app/zelda3/screen/inventory.cc
|
||||
app/zelda3/screen/title_screen.cc
|
||||
app/zelda3/sprite/sprite.cc
|
||||
app/zelda3/sprite/sprite_builder.cc
|
||||
app/zelda3/zelda3_labels.cc
|
||||
zelda3/dungeon/dungeon_editor_system.cc
|
||||
zelda3/dungeon/dungeon_object_editor.cc
|
||||
zelda3/dungeon/object_drawer.cc
|
||||
zelda3/dungeon/object_parser.cc
|
||||
zelda3/dungeon/room.cc
|
||||
zelda3/dungeon/room_layout.cc
|
||||
zelda3/dungeon/room_object.cc
|
||||
zelda3/music/tracker.cc
|
||||
zelda3/overworld/overworld.cc
|
||||
zelda3/overworld/overworld_map.cc
|
||||
zelda3/screen/dungeon_map.cc
|
||||
zelda3/screen/inventory.cc
|
||||
zelda3/screen/title_screen.cc
|
||||
zelda3/sprite/sprite.cc
|
||||
zelda3/sprite/sprite_builder.cc
|
||||
zelda3/zelda3_labels.cc
|
||||
)
|
||||
|
||||
# ==============================================================================
|
||||
Reference in New Issue
Block a user