ScummVM API documentation
Xeen::Character Class Reference

Public Member Functions

 Character ()
 
 Character (const Character &src)
 
bool operator== (const Character &src) const
 
bool operator!= (const Character &src) const
 
void clear ()
 
Characteroperator= (const Character &src)
 
void synchronize (Common::Serializer &s)
 
Condition worstCondition () const
 
bool isDisabled () const
 
bool isDisabledOrDead () const
 
bool isDead () const
 
int getAge (bool ignoreTemp=false) const
 
int getMaxHP () const
 
int getMaxSP () const
 
uint getStat (Attribute attrib, bool baseOnly=false) const
 
int statBonus (uint statValue) const
 
bool charSavingThrow (DamageType attackType) const
 
bool noActions ()
 
void setAward (int awardId, bool value)
 
bool hasAward (int awardId) const
 
int getAwardCount (int awardId) const
 
int getArmorClass (bool baseOnly=false) const
 
int getThievery () const
 
uint getCurrentLevel () const
 
int itemScan (int itemId) const
 
void setValue (int id, uint value)
 
bool guildMember () const
 
uint experienceToNextLevel () const
 
uint nextExperienceLevel () const
 
uint getCurrentExperience () const
 
int getNumSkills () const
 
int getNumAwards () const
 
ItemCategory makeItem (int p1, int itemIndex, int p3)
 
void addHitPoints (int amount)
 
void subtractHitPoints (int amount)
 
bool hasSlayerSword () const
 
bool hasMissileWeapon () const
 
SpellsCategory getSpellsCategory () const
 
int getSpellsExpenseFactor () const
 
void clearConditions ()
 

Static Public Member Functions

static int statColor (int amount, int threshold)
 

Public Attributes

Common::String _name
 
Sex _sex
 
Race _race
 
int _xeenSide
 
CharacterClass _class
 
AttributePair _might
 
AttributePair _intellect
 
AttributePair _personality
 
AttributePair _endurance
 
AttributePair _speed
 
AttributePair _accuracy
 
AttributePair _luck
 
int _ACTemp
 
AttributePair _level
 
uint _birthDay
 
int _tempAge
 
int _skills [18]
 
int _awards [128]
 
bool _spells [39]
 
int _lloydMap
 
Common::Point _lloydPosition
 
bool _hasSpells
 
int8 _currentSpell
 
QuickAction _quickOption
 
WeaponItems _weapons
 
ArmorItems _armor
 
AccessoryItems _accessories
 
MiscItems _misc
 
InventoryItemsGroup _items
 
int _lloydSide
 
AttributePair _fireResistence
 
AttributePair _coldResistence
 
AttributePair _electricityResistence
 
AttributePair _poisonResistence
 
AttributePair _energyResistence
 
AttributePair _magicResistence
 
int _conditions [16]
 
int _townUnknown
 
int _savedMazeId
 
int _currentHp
 
int _currentSp
 
uint _birthYear
 
uint32 _experience
 
int _currentAdventuringSpell
 
int _currentCombatSpell
 
SpriteResource_faceSprites
 
int _rosterId
 

Static Public Attributes

static int _itemType
 

Constructor & Destructor Documentation

◆ Character() [1/2]

Xeen::Character::Character ( )

Constructor

◆ Character() [2/2]

Xeen::Character::Character ( const Character src)

Constructor

Member Function Documentation

◆ operator==()

bool Xeen::Character::operator== ( const Character src) const
inline

Equality operator

◆ operator!=()

bool Xeen::Character::operator!= ( const Character src) const
inline

Inequality operator

◆ clear()

void Xeen::Character::clear ( )

Clears the data for a character

◆ operator=()

Character& Xeen::Character::operator= ( const Character src)

Assignment operator

◆ synchronize()

void Xeen::Character::synchronize ( Common::Serializer s)

Synchronizes data for the character

◆ worstCondition()

Condition Xeen::Character::worstCondition ( ) const

Returns the worst condition the character is suffering from

◆ isDisabled()

bool Xeen::Character::isDisabled ( ) const

Returns whether the given character has a disabling condition, but still alive

◆ isDisabledOrDead()

bool Xeen::Character::isDisabledOrDead ( ) const

Returns whether the given character has a disabling condition, or is dead

◆ isDead()

bool Xeen::Character::isDead ( ) const

Returns whether the given character has a dead condition

◆ getAge()

int Xeen::Character::getAge ( bool  ignoreTemp = false) const

Get the character's age

◆ getMaxHP()

int Xeen::Character::getMaxHP ( ) const

Gets the maximum hit points for a character

◆ getMaxSP()

int Xeen::Character::getMaxSP ( ) const

Gets the maximum spell points for a character

◆ getStat()

uint Xeen::Character::getStat ( Attribute  attrib,
bool  baseOnly = false 
) const

Get the effective value of a given stat for the character

◆ statColor()

static int Xeen::Character::statColor ( int  amount,
int  threshold 
)
static

Return the color number to use for a given stat value in the character info or quick reference dialogs

◆ statBonus()

int Xeen::Character::statBonus ( uint  statValue) const

Returns the bonus the character gets for stats

◆ charSavingThrow()

bool Xeen::Character::charSavingThrow ( DamageType  attackType) const

Returns true if the character passes a saving throw for a given attack type

◆ noActions()

bool Xeen::Character::noActions ( )

Returns true if the character is unable to perform any action

◆ setAward()

void Xeen::Character::setAward ( int  awardId,
bool  value 
)

Sets an award status

◆ hasAward()

bool Xeen::Character::hasAward ( int  awardId) const

Returns true if a character has a given award

◆ getAwardCount()

int Xeen::Character::getAwardCount ( int  awardId) const

Returns the number of times a character has received a given award

◆ getArmorClass()

int Xeen::Character::getArmorClass ( bool  baseOnly = false) const

Returns the character's armor class

◆ getThievery()

int Xeen::Character::getThievery ( ) const

Returns the thievery skill level, adjusted by class and race

◆ itemScan()

int Xeen::Character::itemScan ( int  itemId) const

Scans the character's inventory for the given item

◆ setValue()

void Xeen::Character::setValue ( int  id,
uint  value 
)

Sets various attributes of a character

◆ guildMember()

bool Xeen::Character::guildMember ( ) const

Returns true if the character is a member of the current town's guild

◆ experienceToNextLevel()

uint Xeen::Character::experienceToNextLevel ( ) const

Returns the experience required to reach the next level

◆ nextExperienceLevel()

uint Xeen::Character::nextExperienceLevel ( ) const

Returns the next level the character will reach

◆ getCurrentExperience()

uint Xeen::Character::getCurrentExperience ( ) const

Returns the character's current experience

◆ getNumSkills()

int Xeen::Character::getNumSkills ( ) const

Returns the number of skills the character has

◆ getNumAwards()

int Xeen::Character::getNumAwards ( ) const

Returns the number of awards the character has

◆ makeItem()

ItemCategory Xeen::Character::makeItem ( int  p1,
int  itemIndex,
int  p3 
)

Creates an item and adds it to the inventory

◆ addHitPoints()

void Xeen::Character::addHitPoints ( int  amount)

Add hit points to a character

◆ subtractHitPoints()

void Xeen::Character::subtractHitPoints ( int  amount)

Remove hit points from the character

◆ hasSlayerSword()

bool Xeen::Character::hasSlayerSword ( ) const

Returns true if the character has the Xeen Slayer Sword

◆ hasMissileWeapon()

bool Xeen::Character::hasMissileWeapon ( ) const

Returns true if the character has a missile weapon, such as a bow

◆ getSpellsCategory()

SpellsCategory Xeen::Character::getSpellsCategory ( ) const

Returns the spells category for the character's class

◆ getSpellsExpenseFactor()

int Xeen::Character::getSpellsExpenseFactor ( ) const
inline

Returns an expense factor for purchasing spells by certain character classes

◆ clearConditions()

void Xeen::Character::clearConditions ( )

Clears the character of any currently set conditions


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