Mana
Loading...
Searching...
No Matches
Classes | Namespaces | Macros | Functions
attributes.cpp File Reference
#include "resources/attributes.h"
#include "log.h"
#include "playerinfo.h"
#include "gui/statuswindow.h"
#include "resources/itemdb.h"
#include "utils/gettext.h"
#include "utils/stringutils.h"
#include <list>
#include <map>

Go to the source code of this file.

Classes

struct  Attributes::Attribute
 

Namespaces

namespace  Attributes
 

Macros

#define DEFAULT_ATTRIBUTESDB_FILE   "attributes.xml"
 
#define DEFAULT_POINTS   30
 
#define DEFAULT_MIN_PTS   1
 
#define DEFAULT_MAX_PTS   9
 

Functions

unsigned int Attributes::getCreationPoints ()
 Give the attribute points given to a character at its creation.
 
unsigned int Attributes::getAttributeMinimum ()
 Give the minimum attribute point possible at character's creation.
 
unsigned int Attributes::getAttributeMaximum ()
 Give the maximum attribute point possible at character's creation.
 
std::vector< std::string > & Attributes::getLabels ()
 Returns the list of base attribute labels.
 
int Attributes::getPlayerInfoIdFromAttrId (int attrId)
 Give back the corresponding playerinfo Id from the attribute id defined in the xml file.
 
void Attributes::init ()
 
void Attributes::readAttributeNode (XML::Node node, const std::string &filename)
 Read attribute node.
 
void Attributes::readPointsNode (XML::Node node, const std::string &filename)
 Read points node.
 
void Attributes::checkStatus ()
 Check if all the data loaded by readPointsNode and readAttributeNode is ok.
 
void Attributes::unload ()
 
void Attributes::informItemDB ()
 
void Attributes::informStatusWindow ()
 

Macro Definition Documentation

◆ DEFAULT_ATTRIBUTESDB_FILE

#define DEFAULT_ATTRIBUTESDB_FILE   "attributes.xml"

Definition at line 36 of file attributes.cpp.

◆ DEFAULT_MAX_PTS

#define DEFAULT_MAX_PTS   9

Definition at line 39 of file attributes.cpp.

◆ DEFAULT_MIN_PTS

#define DEFAULT_MIN_PTS   1

Definition at line 38 of file attributes.cpp.

◆ DEFAULT_POINTS

#define DEFAULT_POINTS   30

Definition at line 37 of file attributes.cpp.