yaze 0.3.2
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
yaze::editor::DungeonToolset Class Reference

Handles the dungeon editor toolset UI. More...

#include <dungeon_toolset.h>

Public Types

enum  BackgroundType {
  kNoBackground , kBackground1 , kBackground2 , kBackground3 ,
  kBackgroundAny
}
 
enum  PlacementType {
  kNoType , kObject , kSprite , kItem ,
  kEntrance , kDoor , kChest , kBlock
}
 

Public Member Functions

 DungeonToolset ()=default
 
void Draw ()
 
BackgroundType background_type () const
 
PlacementType placement_type () const
 
void set_background_type (BackgroundType type)
 
void set_placement_type (PlacementType type)
 
void SetUndoCallback (std::function< void()> callback)
 
void SetRedoCallback (std::function< void()> callback)
 
void SetPaletteToggleCallback (std::function< void()> callback)
 

Private Attributes

BackgroundType background_type_ = kBackgroundAny
 
PlacementType placement_type_ = kNoType
 
std::function< void()> undo_callback_
 
std::function< void()> redo_callback_
 
std::function< void()> palette_toggle_callback_
 

Detailed Description

Handles the dungeon editor toolset UI.

This component manages the toolbar with placement modes, background layer selection, and other editing tools.

Definition at line 18 of file dungeon_toolset.h.

Member Enumeration Documentation

◆ BackgroundType

Enumerator
kNoBackground 
kBackground1 
kBackground2 
kBackground3 
kBackgroundAny 

Definition at line 20 of file dungeon_toolset.h.

◆ PlacementType

Enumerator
kNoType 
kObject 
kSprite 
kItem 
kEntrance 
kDoor 
kChest 
kBlock 

Definition at line 28 of file dungeon_toolset.h.

Constructor & Destructor Documentation

◆ DungeonToolset()

yaze::editor::DungeonToolset::DungeonToolset ( )
default

Member Function Documentation

◆ Draw()

◆ background_type()

BackgroundType yaze::editor::DungeonToolset::background_type ( ) const
inline

Definition at line 44 of file dungeon_toolset.h.

References background_type_.

Referenced by yaze::test::TEST(), and yaze::test::TEST().

◆ placement_type()

PlacementType yaze::editor::DungeonToolset::placement_type ( ) const
inline

Definition at line 45 of file dungeon_toolset.h.

References placement_type_.

Referenced by yaze::test::TEST().

◆ set_background_type()

void yaze::editor::DungeonToolset::set_background_type ( BackgroundType  type)
inline

Definition at line 48 of file dungeon_toolset.h.

References background_type_.

Referenced by yaze::test::TEST().

◆ set_placement_type()

void yaze::editor::DungeonToolset::set_placement_type ( PlacementType  type)
inline

Definition at line 49 of file dungeon_toolset.h.

References placement_type_.

Referenced by yaze::test::TEST().

◆ SetUndoCallback()

void yaze::editor::DungeonToolset::SetUndoCallback ( std::function< void()>  callback)
inline

Definition at line 52 of file dungeon_toolset.h.

References undo_callback_.

Referenced by yaze::test::TEST().

◆ SetRedoCallback()

void yaze::editor::DungeonToolset::SetRedoCallback ( std::function< void()>  callback)
inline

Definition at line 53 of file dungeon_toolset.h.

References redo_callback_.

Referenced by yaze::test::TEST().

◆ SetPaletteToggleCallback()

void yaze::editor::DungeonToolset::SetPaletteToggleCallback ( std::function< void()>  callback)
inline

Definition at line 54 of file dungeon_toolset.h.

References palette_toggle_callback_.

Referenced by yaze::test::TEST().

Member Data Documentation

◆ background_type_

BackgroundType yaze::editor::DungeonToolset::background_type_ = kBackgroundAny
private

Definition at line 57 of file dungeon_toolset.h.

Referenced by background_type(), Draw(), and set_background_type().

◆ placement_type_

PlacementType yaze::editor::DungeonToolset::placement_type_ = kNoType
private

Definition at line 58 of file dungeon_toolset.h.

Referenced by Draw(), placement_type(), and set_placement_type().

◆ undo_callback_

std::function<void()> yaze::editor::DungeonToolset::undo_callback_
private

Definition at line 61 of file dungeon_toolset.h.

Referenced by Draw(), and SetUndoCallback().

◆ redo_callback_

std::function<void()> yaze::editor::DungeonToolset::redo_callback_
private

Definition at line 62 of file dungeon_toolset.h.

Referenced by Draw(), and SetRedoCallback().

◆ palette_toggle_callback_

std::function<void()> yaze::editor::DungeonToolset::palette_toggle_callback_
private

Definition at line 63 of file dungeon_toolset.h.

Referenced by Draw(), and SetPaletteToggleCallback().


The documentation for this class was generated from the following files: