24 : session_id_(session_id), game_data_(game_data) {
26 auto&& fallback) -> std::unique_ptr<Editor> {
27 if (editor_registry) {
28 if (
auto created = editor_registry->
CreateEditor(type, rom)) {
37 [&]() {
return std::make_unique<AssemblyEditor>(rom); });
40 [&]() {
return std::make_unique<DungeonEditorV2>(rom); });
43 [&]() {
return std::make_unique<GraphicsEditor>(rom); });
46 [&]() {
return std::make_unique<MusicEditor>(rom); });
49 [&]() {
return std::make_unique<OverworldEditor>(rom); });
52 [&]() {
return std::make_unique<PaletteEditor>(rom); });
55 [&]() {
return std::make_unique<ScreenEditor>(rom); });
58 [&]() {
return std::make_unique<SpriteEditor>(rom); });
61 [&]() {
return std::make_unique<MessageEditor>(rom); });
64 [&]() {
return std::make_unique<MemoryEditor>(rom); });
67 [&]() {
return std::make_unique<SettingsPanel>(); });
91 for (
auto& [type, editor] :
editors_) {
92 editor->SetDependencies(dependencies);
99 return it->second.get();
106 editor->OpenFolder(folder_path);
112 editor->ChangeActiveFile(path);
118 return editor->asar_wrapper();
125 return editor->LoadedRoomCount();
132 return editor->TotalRoomCount();
140 return editor->CollectWriteRanges();
147 return &editor->overworld();
191 editors(&rom, &game_data, user_settings, session_id, editor_registry) {
The Rom class is used to load, save, and modify Rom data. This is a generic SNES ROM container and do...
Modern C++ wrapper for Asar 65816 assembler integration.
Text editor for modifying assembly code.
DungeonEditorV2 - Simplified dungeon editor using component delegation.
void SetGameData(zelda3::GameData *game_data) override
Manages editor types, categories, and lifecycle.
std::unique_ptr< Editor > CreateEditor(EditorType type, Rom *rom) const
MemoryEditor * GetMemoryEditor() const
std::unordered_map< EditorType, std::unique_ptr< Editor > > editors_
DungeonEditorV2 * GetDungeonEditor() const
void OpenAssemblyFolder(const std::string &folder_path) const
MusicEditor * GetMusicEditor() const
ScreenEditor * GetScreenEditor() const
core::AsarWrapper * GetAsarWrapper() const
void ChangeActiveAssemblyFile(std::string_view path) const
void ApplyDependencies(const EditorDependencies &dependencies)
EditorSet(Rom *rom=nullptr, zelda3::GameData *game_data=nullptr, UserSettings *user_settings=nullptr, size_t session_id=0, EditorRegistry *editor_registry=nullptr)
SpriteEditor * GetSpriteEditor() const
Editor * GetEditor(EditorType type) const
GraphicsEditor * GetGraphicsEditor() const
int LoadedDungeonRoomCount() const
PaletteEditor * GetPaletteEditor() const
void set_user_settings(UserSettings *settings)
zelda3::Overworld * GetOverworldData() const
MessageEditor * GetMessageEditor() const
int TotalDungeonRoomCount() const
SettingsPanel * GetSettingsPanel() const
std::vector< Editor * > active_editors_
OverworldEditor * GetOverworldEditor() const
AssemblyEditor * GetAssemblyEditor() const
std::vector< std::pair< uint32_t, uint32_t > > CollectDungeonWriteRanges() const
Interface for editor classes.
Allows the user to edit graphics sheets from the game or view prototype graphics.
void SetGameData(zelda3::GameData *game_data) override
A class for editing music data in a Rom.
Main UI class for editing overworld maps in A Link to the Past.
void SetGameData(zelda3::GameData *game_data) override
Allows the user to view and edit in game palettes.
The ScreenEditor class allows the user to edit a variety of screens in the game or create a custom me...
Manages the settings UI displayed in the right sidebar.
void SetUserSettings(UserSettings *settings)
Allows the user to edit sprites.
Manages user preferences and settings persistence.
Represents the full Overworld data, light and dark world.
Editors are the view controllers for the application.
Unified dependency container for all editor types.
core::FeatureFlags::Flags feature_flags
std::string GetDisplayName() const