![]() |
Gamedev Framework (gf) 1.2.0
A C++17 framework for 2D games
|
The properties for TMX entities. More...
#include <gf/Tmx.h>
Public Member Functions | |
void | addStringProperty (std::string name, std::string value) |
Add a string property. More... | |
void | addIntProperty (std::string name, int value) |
Add an integer property. More... | |
void | addFloatProperty (std::string name, double value) |
Add a float property. More... | |
void | addBoolProperty (std::string name, bool value) |
Add a boolean property. More... | |
void | addColorProperty (std::string name, Color4u value) |
Add a color property. More... | |
void | addFileProperty (std::string name, Path value) |
Add a file property. More... | |
void | addObjectProperty (std::string name, Id value) |
Add an object property. More... | |
void | addClassProperty (std::string name, TmxProperties value) |
Add a class property. More... | |
std::string | getStringProperty (const std::string &name, const std::string &def) const |
Get a string property. More... | |
int | getIntProperty (const std::string &name, int def) const |
Get an integer property. More... | |
double | getFloatProperty (const std::string &name, double def) const |
Get a float property. More... | |
bool | getBoolProperty (const std::string &name, bool def) const |
Get a boolean property. More... | |
Color4u | getColorProperty (const std::string &name, const Color4u &def) const |
Get a color property. More... | |
Path | getFileProperty (const std::string &name, const Path &def) const |
Get a file property. More... | |
Id | getObjectProperty (const std::string &name, Id def) const |
Get an object property. More... | |
TmxProperties | getClassProperty (const std::string &name, const TmxProperties &def) const |
Get a class property. More... | |
The properties for TMX entities.
void gf::TmxProperties::addBoolProperty | ( | std::string | name, |
bool | value | ||
) |
Add a boolean property.
name | The name of the property |
value | The value of the property |
void gf::TmxProperties::addClassProperty | ( | std::string | name, |
TmxProperties | value | ||
) |
Add a class property.
name | The name of the property |
value | The value of the property |
void gf::TmxProperties::addColorProperty | ( | std::string | name, |
Color4u | value | ||
) |
Add a color property.
name | The name of the property |
value | The value of the property |
void gf::TmxProperties::addFileProperty | ( | std::string | name, |
Path | value | ||
) |
Add a file property.
name | The name of the property |
value | The value of the property |
void gf::TmxProperties::addFloatProperty | ( | std::string | name, |
double | value | ||
) |
Add a float property.
name | The name of the property |
value | The value of the property |
void gf::TmxProperties::addIntProperty | ( | std::string | name, |
int | value | ||
) |
Add an integer property.
name | The name of the property |
value | The value of the property |
void gf::TmxProperties::addObjectProperty | ( | std::string | name, |
Id | value | ||
) |
Add an object property.
name | The name of the property |
value | The value of the property |
void gf::TmxProperties::addStringProperty | ( | std::string | name, |
std::string | value | ||
) |
Add a string property.
name | The name of the property |
value | The value of the property |
bool gf::TmxProperties::getBoolProperty | ( | const std::string & | name, |
bool | def | ||
) | const |
Get a boolean property.
name | The name of the property |
def | The default value if the property does not exist |
TmxProperties gf::TmxProperties::getClassProperty | ( | const std::string & | name, |
const TmxProperties & | def | ||
) | const |
Get a class property.
name | The name of the property |
def | The default value if the property does not exist |
Get a color property.
name | The name of the property |
def | The default value if the property does not exist |
Get a file property.
name | The name of the property |
def | The default value if the property does not exist |
double gf::TmxProperties::getFloatProperty | ( | const std::string & | name, |
double | def | ||
) | const |
Get a float property.
name | The name of the property |
def | The default value if the property does not exist |
int gf::TmxProperties::getIntProperty | ( | const std::string & | name, |
int | def | ||
) | const |
Get an integer property.
name | The name of the property |
def | The default value if the property does not exist |
Get an object property.
name | The name of the property |
def | The default value if the property does not exist |
std::string gf::TmxProperties::getStringProperty | ( | const std::string & | name, |
const std::string & | def | ||
) | const |
Get a string property.
name | The name of the property |
def | The default value if the property does not exist |