Peoplemon  0.1.0
Peoplemon 3 game source documentation
Public Member Functions | Static Public Member Functions | List of all members
editor::page::Towns Class Reference

Subpage for creating, editing, deleting, and placing towns in maps. More...

#include <Towns.hpp>

Public Member Functions

 Towns (bl::engine::Engine &engine, MapArea &map)
 Creates the towns subpage and GUI elements. More...
 
bl::gui::Element::Ptr getContent ()
 Returns the GUI element to pack. More...
 
void setGUI (bl::gui::GUI *gui)
 Set the primary GUI object. More...
 
std::uint8_t selected () const
 Returns the currently selected town index. More...
 
void refresh ()
 Refreshes the list of towns in the page. More...
 

Static Public Member Functions

static sf::Color getColor (std::uint8_t index)
 Returns the color to use for the given town. More...
 

Detailed Description

Subpage for creating, editing, deleting, and placing towns in maps.

Definition at line 21 of file Towns.hpp.

Constructor & Destructor Documentation

◆ Towns()

editor::page::Towns::Towns ( bl::engine::Engine &  engine,
MapArea map 
)

Creates the towns subpage and GUI elements.

Parameters
engineThe game engine instance
mapThe edit map component

Definition at line 19 of file Towns.cpp.

Member Function Documentation

◆ getColor()

sf::Color editor::page::Towns::getColor ( std::uint8_t  index)
static

Returns the color to use for the given town.

Definition at line 123 of file Towns.cpp.

◆ getContent()

Element::Ptr editor::page::Towns::getContent ( )

Returns the GUI element to pack.

Definition at line 117 of file Towns.cpp.

◆ refresh()

void editor::page::Towns::refresh ( )

Refreshes the list of towns in the page.

Definition at line 125 of file Towns.cpp.

◆ selected()

std::uint8_t editor::page::Towns::selected ( ) const

Returns the currently selected town index.

Definition at line 119 of file Towns.cpp.

◆ setGUI()

void editor::page::Towns::setGUI ( bl::gui::GUI *  gui)

Set the primary GUI object.

Parameters
guiThe primary GUI object

Definition at line 121 of file Towns.cpp.


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