Mania++
 All Classes Functions Variables Pages
Public Member Functions | Public Attributes | Private Member Functions | List of all members
Map Struct Reference

Contains all information about a map in easy-to-use format. More...

#include <Map.h>

Public Member Functions

 Map ()
 Constructs a Map object without input.
 
 Map (std::map< std::string, GbxResponseParameter > serverStruct)
 Formats a server response into a usable form. More...
 
void MapDetailed (std::map< std::string, GbxResponseParameter > serverStruct)
 Formats a server response into a usable form. More...
 
void CopyDetailedMap (Map map)
 Copies information from map object. More...
 
void SetId (int id)
 Set database identifier value. More...
 
void UpdateAdditional (std::string key, boost::any value)
 Updates (or inserts) key with value. More...
 

Public Attributes

int Id = 0
 Map identifier (on database).
 
std::string UId
 Unique map identifier.
 
std::string Name
 Map name.
 
std::string FileName
 File name.
 
std::string Environment
 Game environment.
 
std::string Author
 Login of the author.
 
int GoldTime
 Time of the gold medal.
 
int CopperPrice
 Copper price.
 
std::string MapType
 Type of the map.
 
std::string MapStyle
 Map style (self-entered).
 
std::string Mood
 Map mood (setting).
 
int BronzeTime
 Time of the bronze medal.
 
int SilverTime
 Time of the silver medal.
 
int AuthorTime
 Time set by the author.
 
bool LapRace
 Map is multi-lap.
 
int NbLaps
 Number of laps.
 
int NbCheckpoints
 Number of checkpoints.
 
std::map< std::string, boost::any > Additionals
 Additional parameters.
 

Private Member Functions

void setBasicInfo (std::map< std::string, GbxResponseParameter > serverStruct)
 Sets the basic map information from the struct. More...
 
void setDetailedInfo (std::map< std::string, GbxResponseParameter > serverStruct)
 Sets the detailed map information from the struct. More...
 

Detailed Description

Contains all information about a map in easy-to-use format.

Constructor & Destructor Documentation

Map::Map ( std::map< std::string, GbxResponseParameter serverStruct)
inline

Formats a server response into a usable form.

Parameters
serverStructThe struct with map information received from the server.

Member Function Documentation

void Map::CopyDetailedMap ( Map  map)
inline

Copies information from map object.

Parameters
mapMap object to be copied into this.
void Map::MapDetailed ( std::map< std::string, GbxResponseParameter serverStruct)
inline

Formats a server response into a usable form.

Parameters
serverStructThe struct with detailed map information received from the server.
void Map::setBasicInfo ( std::map< std::string, GbxResponseParameter serverStruct)
inlineprivate

Sets the basic map information from the struct.

Parameters
serverStructThe struct with map information received from the server.
void Map::setDetailedInfo ( std::map< std::string, GbxResponseParameter serverStruct)
inlineprivate

Sets the detailed map information from the struct.

Parameters
serverStructThe struct with detailed map information received from the server.
void Map::SetId ( int  id)
inline

Set database identifier value.

Parameters
idDatabase ID.
void Map::UpdateAdditional ( std::string  key,
boost::any  value 
)
inline

Updates (or inserts) key with value.

Parameters
keyAdditionals key.
valueAdditionals value.

The documentation for this struct was generated from the following file: