#include <characterdata.hpp>
Inheritance diagram for CharacterData:

Public Member Functions | |
| CharacterData (std::string const &name, int id=-1) | |
| CharacterData (MessageIn &msg) | |
| Constructor used for creating a character from a serialised message. | |
| int | getDatabaseID () const |
| Gets the database id of the character. | |
| void | setDatabaseID (int id) |
| Sets the database id of the character. | |
| int | getAccountID () const |
| Gets the account id of the account the character belongs to. | |
| void | setAccountID (int id) |
| Sets the account id of the account the character belongs to. | |
| std::string const & | getName () const |
| Gets the name of the character. | |
| void | setName (const std::string &name) |
| Sets the name of the character. | |
| int | getGender () const |
| Gets the gender of the character (male / female). | |
| void | setGender (int gender) |
| Sets the gender of the character (male / female). | |
| int | getHairStyle () const |
| Gets the hairstyle of the character. | |
| void | setHairStyle (int style) |
| Sets the hairstyle of the character. | |
| int | getHairColor () const |
| Gets the haircolor of the character. | |
| void | setHairColor (int color) |
| Sets the haircolor of the character. | |
| int | getLevel () const |
| Gets the level of the character. | |
| void | setLevel (int level) |
| Sets the level of the character. | |
| int | getMoney () const |
| Gets the amount of money the character has. | |
| void | setMoney (int amount) |
| Sets the amount of money the character has. | |
| unsigned short | getBaseAttribute (int attributeNumber) const |
| Gets the value of a base attribute of the character. | |
| void | setBaseAttribute (int attributeNumber, int value) |
| Sets the value of a base attribute of the character. | |
| int | getMapId () const |
| Gets the Id of the map that the character is on. | |
| void | setMapId (int mapId) |
| Sets the Id of the map that the character is on. | |
| Point const & | getPosition () const |
| Gets the position of the character on the map. | |
| void | setPosition (const Point &p) |
| Sets the position of the character on the map. | |
| int | getNumberOfInventoryItems () const |
| Returns the number of inventory items. | |
| InventoryItem const & | getInventoryItem (unsigned short slot) const |
| Returns a reference to the item in inventory at slot. | |
| void | clearInventory () |
| Clears the inventory, in preperation for an update. | |
| void | addItemToInventory (const InventoryItem &item) |
| Adds an inventory item to the inventory. | |
Private Member Functions | |
| CharacterData (CharacterData const &) | |
| CharacterData & | operator= (CharacterData const &) |
Private Attributes | |
| int | mDatabaseID |
| Character database ID. | |
| int | mAccountID |
| Account ID of the account the character belongs to. | |
| std::string | mName |
| Name of the character. | |
| unsigned char | mGender |
| Gender of the being. | |
| unsigned char | mHairStyle |
| Hair Style of the being. | |
| unsigned char | mHairColor |
| Hair Color of the being. | |
| unsigned char | mLevel |
| Level of the being. | |
| unsigned int | mMoney |
| Wealth of the being. | |
| unsigned short | mBaseAttributes [NB_BASE_ATTRIBUTES] |
| character. | |
| unsigned short | mMapId |
| Map the being is on. | |
| Point | mPos |
| Position the being is at. | |
| std::vector< InventoryItem > | mInventory |
| All the possesions of the character. | |
|
||||||||||||
|
Definition at line 27 of file characterdata.cpp. |
|
|
Constructor used for creating a character from a serialised message.
Definition at line 37 of file characterdata.cpp. |
|
|
|
|
|
Adds an inventory item to the inventory.
Implements AbstractCharacterData. Definition at line 55 of file characterdata.cpp. |
|
|
Clears the inventory, in preperation for an update.
Implements AbstractCharacterData. Definition at line 152 of file characterdata.hpp. |
|
|
Gets the account id of the account the character belongs to.
Definition at line 62 of file characterdata.hpp. |
|
|
Gets the value of a base attribute of the character.
Implements AbstractCharacterData. Definition at line 118 of file characterdata.hpp. |
|
|
Gets the database id of the character.
Implements AbstractCharacterData. Definition at line 54 of file characterdata.hpp. |
|
|
Gets the gender of the character (male / female).
Implements AbstractCharacterData. Definition at line 78 of file characterdata.hpp. |
|
|
Gets the haircolor of the character.
Implements AbstractCharacterData. Definition at line 94 of file characterdata.hpp. |
|
|
Gets the hairstyle of the character.
Implements AbstractCharacterData. Definition at line 86 of file characterdata.hpp. |
|
|
Returns a reference to the item in inventory at slot.
Implements AbstractCharacterData. Definition at line 49 of file characterdata.cpp. |
|
|
Gets the level of the character.
Implements AbstractCharacterData. Definition at line 102 of file characterdata.hpp. |
|
|
Gets the Id of the map that the character is on.
Implements AbstractCharacterData. Definition at line 128 of file characterdata.hpp. |
|
|
Gets the amount of money the character has.
Implements AbstractCharacterData. Definition at line 110 of file characterdata.hpp. |
|
|
Gets the name of the character.
Implements AbstractCharacterData. Definition at line 70 of file characterdata.hpp. |
|
|
Returns the number of inventory items.
Implements AbstractCharacterData. Definition at line 144 of file characterdata.hpp. |
|
|
Gets the position of the character on the map.
Implements AbstractCharacterData. Definition at line 136 of file characterdata.hpp. |
|
|
|
|
|
Sets the account id of the account the character belongs to.
Definition at line 66 of file characterdata.hpp. |
|
||||||||||||
|
Sets the value of a base attribute of the character.
Implements AbstractCharacterData. Definition at line 123 of file characterdata.hpp. |
|
|
Sets the database id of the character.
Implements AbstractCharacterData. Definition at line 58 of file characterdata.hpp. |
|
|
Sets the gender of the character (male / female).
Implements AbstractCharacterData. Definition at line 82 of file characterdata.hpp. |
|
|
Sets the haircolor of the character.
Implements AbstractCharacterData. Definition at line 98 of file characterdata.hpp. |
|
|
Sets the hairstyle of the character.
Implements AbstractCharacterData. Definition at line 90 of file characterdata.hpp. |
|
|
Sets the level of the character.
Implements AbstractCharacterData. Definition at line 106 of file characterdata.hpp. |
|
|
Sets the Id of the map that the character is on.
Implements AbstractCharacterData. Definition at line 132 of file characterdata.hpp. |
|
|
Sets the amount of money the character has.
Implements AbstractCharacterData. Definition at line 114 of file characterdata.hpp. |
|
|
Sets the name of the character.
Implements AbstractCharacterData. Definition at line 74 of file characterdata.hpp. |
|
|
Sets the position of the character on the map.
Implements AbstractCharacterData. Definition at line 140 of file characterdata.hpp. |
|
|
Account ID of the account the character belongs to. (-1) if not set yet. Definition at line 164 of file characterdata.hpp. |
|
|
character.
Definition at line 172 of file characterdata.hpp. |
|
|
Character database ID. (-1) if not set yet. Definition at line 162 of file characterdata.hpp. |
|
|
Gender of the being.
Definition at line 167 of file characterdata.hpp. |
|
|
Hair Color of the being.
Definition at line 169 of file characterdata.hpp. |
|
|
Hair Style of the being.
Definition at line 168 of file characterdata.hpp. |
|
|
All the possesions of the character.
Definition at line 176 of file characterdata.hpp. |
|
|
Level of the being.
Definition at line 170 of file characterdata.hpp. |
|
|
Map the being is on.
Definition at line 174 of file characterdata.hpp. |
|
|
Wealth of the being.
Definition at line 171 of file characterdata.hpp. |
|
|
Name of the character.
Definition at line 166 of file characterdata.hpp. |
|
|
Position the being is at.
Definition at line 175 of file characterdata.hpp. |
1.3.9.1