Planeshift
Classes | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes

psCharacter Class Reference

#include <pscharacter.h>

List of all members.

Classes

struct  st_location

Public Types

enum  TradingStatus {
  NOT_TRADING, SELLING, BUYING, WITHDRAWING,
  STORING
}

Public Member Functions

unsigned int AddExperiencePoints (unsigned int W)
unsigned int AddExperiencePointsNotify (unsigned int W)
bool AddExploredArea (PID explored)
 Add a new explored area.
void AddLootItem (psItem *item)
 Adds the supplied psItem to the list of lootable items from this character.
void AddLootMoney (int money)
void AddSpell (psSpell *spell)
void AdjustHitPoints (float adjust)
void AdjustMana (float adjust)
void AdjustMoney (psMoney m, bool bank)
void AdjustStamina (float adjust, bool pys)
bool AppendCharacterSelectData (psAuthApprovedMessage &auth)
void AssignGMEvent (int id, bool playerIsGM)
MultiplierAttackModifier ()
psMoneyBankMoney ()
double CalcFunction (MathEnvironment *env, const char *functionName, const double *params)
unsigned int CalculateAddExperience (PSSKILL skill, unsigned int awardedPoints, float modifier=1)
void CalculateEquipmentModifiers ()
void CalculateMaxStamina ()
 Recalculate the maximm stamina for the character.
bool CanSummonFamiliar ()
bool CanTrain (PSSKILL skill)
 Figure out if this skill can be trained.
bool CheckFaction (Faction *faction, int value)
 Check player for given faction.
bool CheckResponsePrerequisite (NpcResponse *resp)
void ClearLoot ()
 Clears the pending loot items array and money.
void ClearStatsDirtyFlags (unsigned int dirtyFlags)
 Cleare the dirty flags for vitals.
void CombatDrain (int)
void CompleteGMEvent (bool playerIsGM)
void CompleteHelpEvent (int which)
 Sets a bit field complete for a specified flag from the enum in tutorialmanager.h.
MultiplierDefenseModifier ()
virtual void DeleteSelf ()
void DropItem (psItem *&item, csVector3 pos=0, const csVector3 &rot=csVector3(0), bool guarded=true, bool transient=true, bool inplace=false)
 Drops an item into the world (one meter from this character's position).
void EndSong (csTicks bonusTime)
 Resets the song's execution data.
AccountID GetAccount () const
AccountID GetAccountId ()
 Get the account ID that this character is attached to.
gemActorGetActor ()
const char * GetAnimalAffinity ()
size_t GetAssignedGMEvents (psGMEventListMessage &gmevents, int clientnum)
psAttackQueueGetAttackQueue ()
 Get the attack queue.
const char * GetBeltGroup ()
const char * GetBracerGroup ()
psBuddyManagerGetBuddyMgr ()
Buffable< int > & GetBuffableVariable (const csString &name, const csString &value="0")
 Returns the reference to a buffable variable.
Buffable< int > & GetCanSummonFamiliar ()
const char * GetCharFullName () const
const char * GetCharLastName () const
unsigned int GetCharLevel (bool physical)
 Returns a level of character based on his 6 base stats.
const char * GetCharName () const
unsigned int GetCharType () const
const char * GetCharTypeName ()
const char * GetCloakGroup ()
float GetCounterBlockValueForWeaponInSlot (INVENTORY_SLOT_NUMBER slot)
const char * GetCreationInfo ()
 This is used to get the stored informations from the char creation.
unsigned int GetDeaths () const
const char * GetDescription ()
 This is used to get the stored player description.
float GetDodgeValue ()
unsigned int GetExperiencePoints ()
bool GetFactionEventsDescription (csString &factionDescription)
 Gets dynamic life events generated from the factions of the character.
FactionSetGetFactions ()
PID GetFamiliarID (size_t id)
psGuildInfoGetGuild ()
 Return the active guild, if any for this character.
psGuildLevelGetGuildLevel ()
 Return the guild level for this character, if any.
psGuildMemberGetGuildMembership ()
 Return the guild membership for this character, if any.
const char * GetHelmGroup ()
float GetHP ()
VitalBuffableGetHPRate ()
int GetImperviousToAttack ()
bool GetIsMarried () const
int GetKillExperience ()
 The exp to be handed out when this actor dies.
unsigned int GetKills () const
csString GetLastLoginTime () const
 Retrive the last login time in the format YYYY-MM-DD HH:MM:SS.
int GetLastResponse ()
 The last_response given by an npc to this player.
const char * GetLifeDescription ()
 This is used to get the stored informations from the custom life events made by players.
st_location GetLocation () const
 Get the character location.
void GetLocationInWorld (InstanceID &instance, psSectorInfo *&sectorinfo, float &loc_x, float &loc_y, float &loc_z, float &loc_yrot)
int GetLootCategory () const
size_t GetLootItems (psLootMessage &msg, EID entity, int cnum)
int GetLootMoney ()
 Gets and zeroes the loot money.
float GetMana ()
VitalBuffableGetManaRate ()
PID GetMasterNPCID () const
int GetMaxAllowedRealm (PSSKILL skill)
 Get the maximum realm the caster can cast with given skill.
VitalBuffableGetMaxHP ()
VitalBuffableGetMaxMana ()
VitalBuffableGetMaxMStamina ()
VitalBuffableGetMaxPStamina ()
psCharacterGetMerchant ()
psMerchantInfoGetMerchantInfo ()
VitalBuffableGetMStaminaRate ()
int GetNotifications ()
 gets the notification bitfield directly: to be used only by the save functon
size_t GetNumFamiliars ()
const char * GetOldLastName () const
unsigned int GetOnlineTimeThisSession ()
 Number of seconds online this session in seconds.
const char * GetOOCDescription ()
 This is used to get the stored player OOC description.
OverridableRaceGetOverridableRace ()
 Gets a reference to the overridable race allowing to override it or check the base race.
PID GetOwnerID ()
double GetPetElapsedTime () const
 Retrive the elapsed time for pets.
PID GetPID () const
unsigned int GetProgressionPoints ()
double GetProperty (MathEnvironment *env, const char *ptr)
 This is used by the math scripting engine to get various values.
VitalBuffableGetPStaminaRate ()
psCharacterQuestManagerGetQuestMgr ()
psRaceInfoGetRaceInfo ()
 Gets the pointer to the global current raceinfo applied to this character.
float GetScale ()
 Gets the scale including any buffs.
float GetScaleValue ()
 Gets the user scale value.
void GetSkillBaseValues (MathEnvironment *env)
psSkillCacheGetSkillCache ()
 Returns a pointer to the skill cache for this character.
SkillRankGetSkillRank (PSSKILL skill)
void GetSkillValues (MathEnvironment *env)
 Function to get the base and current skill values.
bool GetSlotAttackable (INVENTORY_SLOT_NUMBER slot)
 Returns true if the character is able to attack with the current slot.
bool GetSlotAutoAttackable (INVENTORY_SLOT_NUMBER slot)
int GetSlotEventId (INVENTORY_SLOT_NUMBER slot)
bool GetSlotSingleAttackable (INVENTORY_SLOT_NUMBER slot)
csTicks GetSongStartTime () const
 Gets the starting time of the song that the player is currently playing.
st_location GetSpawnLocation ()
 Get the character spawn location.
psSpellGetSpellByIdx (int index)
psSpellGetSpellByName (const csString &spellName)
csArray< psSpell * > & GetSpellList ()
const char * GetSpouseName () const
 Gets Spouse Name of a character.
float GetStamina (bool pys)
float GetStatModifier (PSITEMSTATS_STAT attrib)
unsigned int GetStatsDirtyFlags () const
 Return the dirty flags for vitals.
unsigned int GetSuicides () const
float GetTargetedBlockValueForWeaponInSlot (INVENTORY_SLOT_NUMBER slot)
 Retrieves the calculated Attack Value for the given weapon-slot.
unsigned int GetTimeConnected ()
unsigned int GetTotalOnlineTime ()
 Number of seconds online ever including this session in seconds.
float GetTotalTargetedBlockValue ()
float GetTotalUntargetedBlockValue ()
TradingStatus GetTradingStatus ()
psCharacterGetTrainer ()
psTrainerInfoGetTrainerInfo ()
psTraitGetTraitForLocation (PSTRAIT_LOCATION location)
float GetUntargetedBlockValueForWeaponInSlot (INVENTORY_SLOT_NUMBER slot)
csHash< charVariable, csString >
::ConstGlobalIterator 
GetVariables () const
 Retrive const iterator for character variables.
csString GetVariableValue (const csString &name)
 Returns the value of a variable.
bool HasExploredArea (PID explored)
 Check if an area has already been explored.
bool HasVariableDefined (const csString &name)
 Checks if a variable was defined for this character.
bool Introduce (psCharacter *c)
 Introduces this character to the given character; answers false if already introduced.
psCharacterInventoryInventory ()
bool IsBanker () const
 Check if the character is a banker.
bool IsGettingAllianceNotifications ()
 Returns if the client should receive notifications about alliance members logging in.
bool IsGettingGuildNotifications ()
 Returns if the client should receive notifications about guild members logging in.
bool IsHired ()
bool IsMerchant ()
bool IsMount ()
 Used to determine if this NPC is a mount.
bool IsNPC ()
bool IsPet ()
 Used to determine if this NPC is a pet.
bool IsPlayer ()
 Used to determine if this character is a player.
bool IsStatue ()
bool IsStorage () const
 Check if the character is a storage.
bool IsTrainer ()
void KilledBy (psCharacter *attacker)
void Kills (psCharacter *target)
bool Knows (PID charid)
 Answers whether this character knows the given character or not.
bool Knows (psCharacter *c)
bool Load (iResultRow &row)
void LoadActiveSpells ()
void LoadIntroductions ()
void MakeEquipmentString (csString &equipmentString)
 Construct an XML format string of the player's equipment.
void MakeTextureString (csString &textureString)
 Construct an XML format string of the player's texture choices.
psMoney Money ()
bool NeedsHelpEvent (int which)
 Checks the bit field for a bit flag from the enum in TutorialManager.h.
int NPC_GetSpawnRuleID ()
void NPC_SetSpawnRuleID (int v)
void operator delete (void *)
 The delete operator is overriden to call PoolAllocator template functions.
void * operator new (size_t)
 The new operator is overriden to call PoolAllocator template functions.
void PracticeArmorSkills (unsigned int practice, INVENTORY_SLOT_NUMBER attackLocation)
 Practice skills for armor and weapons.
void PracticeWeaponSkills (unsigned int practice)
void PracticeWeaponSkills (psItem *weapon, unsigned int practice)
virtual void ProcessCacheTimeout ()
 required for iCachedObject but not used here
 psCharacter ()
bool QuickLoad (iResultRow &row, bool noInventory)
 Load the bare minimum to know what this character is looks like.
bool ReadyToExchange ()
void RecalculateStats ()
virtual void * RecoverObject ()
void RemoveGMEvent (int id, bool playerIsGM=false)
psItemRemoveLootItem (int id)
 Removes an item from the loot loaded on the character due to it's defeat.
csArray< psItem * > RemoveLootItems (csArray< csString > categories=csArray< csString >())
 Removes either all or only those items with specified categories from the loot of a defeated character.
void ResetStats ()
void ResetSwings (csTicks timeofattack)
void SaveLocationInWorld ()
void SaveMoney (bool bank)
bool SendStatDRMessage (uint32_t clientnum, EID eid, int flags, csRef< PlayerGroup > group=NULL)
void SetAccount (AccountID id)
void SetActor (gemActor *actor)
void SetAllianceNotifications (bool enabled)
 Sets if the client should receive notifications about alliance members logging in.
void SetAllStatsDirty ()
 Set all vital stats dirty.
void SetAnimialAffinity (const char *v)
void SetBeltGroup (const char *Group)
void SetBracerGroup (const char *Group)
void SetCharType (unsigned int v)
void SetCloakGroup (const char *Group)
void SetCreationInfo (const char *newValue)
 This is used to store the informations from the char creation.
void SetDescription (const char *newValue)
 This is used to store the player description.
void SetExperiencePoints (unsigned int W)
void SetFamiliarID (PID v)
void SetFullName (const char *newFirstName, const char *newLastName)
void SetGuild (psGuildInfo *g)
 Set the active guild for the character.
void SetGuildNotifications (bool enabled)
 Sets if the client should receive notifications about guild members logging in.
void SetHelmGroup (const char *Group)
void SetHired (bool hired)
void SetHitPoints (float v)
void SetImperviousToAttack (int newValue)
void SetIsMarried (bool married)
void SetKillExperience (int newValue)
void SetLastLoginTime ()
 Set the last login time for the character.
void SetLastName (const char *newLastName)
void SetLastResponse (int response)
void SetLifeDescription (const char *newValue)
 This is used to store the informations sent by players for their custom life events.
void SetLocationInWorld (InstanceID instance, psSectorInfo *sectorinfo, float loc_x, float loc_y, float loc_z, float loc_yrot)
void SetLootCategory (int id)
void SetMana (float v)
void SetMoney (psMoney m)
void SetMoney (psItem *&moneyObject)
 Add a money object to the current wallet.
void SetMoney (psItemStats *MoneyObject, int amount)
 Add a certain amount of a money object to the current wallet based on the baseitem data.
void SetName (const char *newName)
void SetNotifications (int notifications)
 sets the notification bitfield directly: to be used only by the loader functon
void SetOldLastName (const char *oldLastName)
void SetOOCDescription (const char *newValue)
 This is used to store the player OOC description.
void SetOwnerID (PID v)
void SetPetElapsedTime (double elapsedTime)
 Set the elapsed time for pets.
void SetPID (PID characterID)
void SetProgressionPoints (unsigned int X, bool save)
void SetRaceInfo (psRaceInfo *rinfo)
 Sets the provided race info as the base default one.
void SetSkillRank (PSSKILL which, unsigned int rank)
 Directly sets rank of given skill.
void SetSpouseName (const char *name)
 Set the name of the spouse.
void SetStamina (float v, bool pys)
void SetStaminaRegenerationNone (bool physical=true, bool mental=true)
void SetStaminaRegenerationSitting ()
void SetStaminaRegenerationStill (bool physical=true, bool mental=true)
void SetStaminaRegenerationWalk (bool physical=true, bool mental=true)
void SetStaminaRegenerationWork (int skill)
void SetTradingStatus (TradingStatus trading, psCharacter *merchant)
bool SetTradingStopped (bool stopped)
void SetTrainer (psCharacter *trainer)
void SetTraitForLocation (PSTRAIT_LOCATION location, psTrait *trait)
void SetVariable (const csString &name, const csString &value)
 Sets a new variable for this character.
void SetVariable (const csString &name)
 Sets a new variable for this character.
SkillSetSkills ()
void StartSong ()
 Takes care of setting correctly all the data needed to keep track of the song.
bool Store (const char *location, const char *slot, psItem *what)
void TagEquipmentObject (INVENTORY_SLOT_NUMBER slot, int eventId)
const char * ToString ()
void Train (PSSKILL skill, int yIncrease)
 Trains a skill.
bool Unintroduce (psCharacter *c)
 Unintroduces this character to the given character; answers false if not introduced.
void UnSetVariable (const csString &name)
 Remove a variable from this character.
bool UpdateFaction (Faction *faction, int delta)
 Update this faction for this player with delta value.
void UpdateRespawn (csVector3 pos, float yrot, psSectorInfo *sector, InstanceID instance)
 Update a npc's default spawn position with given data.
bool UpdateStatDRData (csTicks now)
void UseProgressionPoints (unsigned int X)
virtual ~psCharacter ()

Protected Member Functions

bool LoadAdvantages (PID use_id)
bool LoadBuddies (Result &myBuddy, Result &buddyOf)
bool LoadExploration (Result &exploration)
bool LoadFactions (PID pid)
 Helper function which loads the factions from the database.
bool LoadFamiliar (Result &pet, Result &owner)
bool LoadGMEvents ()
bool LoadMarriageInfo (Result &result)
bool LoadRelationshipInfo (PID pid)
bool LoadSkills (PID use_id)
bool LoadSpells (PID use_id)
bool LoadTraits (PID use_id)
bool LoadVariables (PID pid)
 Helper function which loads the character variables from the database.
void UpdateFactions ()
 Helper function which saves the factions to the database.
void UpdateVariables ()
 Helper function which saves the character variables to the database.

Protected Attributes

AccountID accountid
 Account ID that this characater is attached to.
csSet< PID > acquaintances
gemActoractor
 The current game entity object this characater is attached to.
csString animalAffinity
GMEventsAssignment assignedEvents
Multiplier attackModifier
 Attack value is multiplied by this.
csRef< psAttackQueueattackQueue
psMoney bankMoney
 Money stored in the players bank account.
psBuddyManager buddyManager
Buffable< intcanSummonFamiliar
unsigned int characterType
csHash< charVariable, csString > charVariables
 Used to store character variables for this character.
csString creationinfo
 Creation manager informations.
unsigned int deaths
Multiplier defenseModifier
 Defense value is multiplied by this.
csString description
 Player description.
csArray< PID > exploredAreas
 A bitfield which contains the notifications the player will get if a guild or alliance member login/logoff.
FactionSetfactions
csArray< PID > familiarsId
csString fullName
psGuildInfoguildinfo
unsigned int helpEventFlags
 Bitfield for which help events a character has already encountered.
int imperviousToAttack
psCharacterInventory inventory
 Character's inventory handler.
bool isMarried
bool isStatue
 Says if this npc is a statue.
int joinNotifications
int killExp
 Kill Exp.
unsigned int kills
csString lastLoginTime
 String value copied from the database containing the last login time.
csString lastname
int lastResponse
 Last response of an NPC to this character (not saved)
double lastSavedPetElapsedTime
 Store time for when the petElapsedTime was last saved to db.
csString lifedescription
 Custom life events informations.
bool loaded
st_location location
int lootCategoryId
 Id of Loot category to use if this char has extra loot.
int lootMoney
 Amount of money ready to be looted.
csArray< psItem * > lootPending
 Array of items waiting to be looted.
psCharactermerchant
 The merchant this charcter trade with.
csRef< psMerchantInfomerchantInfo
 Character's merchant info.
StatSet modifiers
psMoney money
 Current cash set on player.
csString name
int npcMasterId
int npcSpawnRuleId
 NPC specific data. Should this go here?
csString oldlastname
csString oocdescription
 Player OOC description.
float overrideMaxHp
float overrideMaxMana
 These values are loaded from base_hp_max,base_mana_max in the db and < should prevent normal HP calculations from taking place.
PID ownerId
double petElapsedTime
PID pid
 Current PID for this characater ( or is it the above entity? )
csString progressionScriptText
 flat string loaded from the DB.
psCharacterQuestManager questManager
OverridableRace race
 Holds the race of this character and it's overriden values.
psSkillCache skillCache
SkillSet skills
st_location spawnLoc
csArray< psSpell * > spellList
csString spouseName
csTicks startTimeThisSession
unsigned int suicides
unsigned int timeconnected
 Total number of seconds online. Updated at logoff.
TradingStatus tradingStatus
 See the enum for the various status.
bool tradingStopped
psCharactertrainer
 The current character that is being trained?
csRef< psTrainerInfotrainerInfo
 Character's trainer information.
psTraittraits [PSTRAIT_LOCATION_COUNT]
psServerVitalsvitals

Static Protected Attributes

static const char * characterTypeName []

Detailed Description

Definition at line 647 of file pscharacter.h.


Member Enumeration Documentation

Enumerator:
NOT_TRADING 
SELLING 
BUYING 
WITHDRAWING 
STORING 

Definition at line 650 of file pscharacter.h.


Constructor & Destructor Documentation

psCharacter::psCharacter ( )
virtual psCharacter::~psCharacter ( ) [virtual]

Member Function Documentation

unsigned int psCharacter::AddExperiencePoints ( unsigned int  W)
unsigned int psCharacter::AddExperiencePointsNotify ( unsigned int  W)
bool psCharacter::AddExploredArea ( PID  explored)

Add a new explored area.

Parameters:
exploredThe PID of the area npc.
void psCharacter::AddLootItem ( psItem item)

Adds the supplied psItem to the list of lootable items from this character.

Parameters:
itemA pointer to the item being lootable from this character.
void psCharacter::AddLootMoney ( int  money) [inline]

Definition at line 1043 of file pscharacter.h.

void psCharacter::AddSpell ( psSpell spell)
void psCharacter::AdjustHitPoints ( float  adjust)
void psCharacter::AdjustMana ( float  adjust)
void psCharacter::AdjustMoney ( psMoney  m,
bool  bank 
)
void psCharacter::AdjustStamina ( float  adjust,
bool  pys 
)
bool psCharacter::AppendCharacterSelectData ( psAuthApprovedMessage auth)
void psCharacter::AssignGMEvent ( int  id,
bool  playerIsGM 
)
Multiplier& psCharacter::AttackModifier ( ) [inline]

Definition at line 1409 of file pscharacter.h.

psMoney& psCharacter::BankMoney ( ) [inline]

Definition at line 688 of file pscharacter.h.

double psCharacter::CalcFunction ( MathEnvironment env,
const char *  functionName,
const double *  params 
) [virtual]

Implements iScriptableVar.

unsigned int psCharacter::CalculateAddExperience ( PSSKILL  skill,
unsigned int  awardedPoints,
float  modifier = 1 
)
void psCharacter::CalculateEquipmentModifiers ( )
void psCharacter::CalculateMaxStamina ( )

Recalculate the maximm stamina for the character.

bool psCharacter::CanSummonFamiliar ( ) [inline]

Definition at line 1349 of file pscharacter.h.

bool psCharacter::CanTrain ( PSSKILL  skill)

Figure out if this skill can be trained.

Checks the current knowledge of the skill. If it is already maxed out then can train no more.

Parameters:
skillThe skill we want to train.
Returns:
True if the skill still requires Y credits before it is fully trained.
bool psCharacter::CheckFaction ( Faction faction,
int  value 
)

Check player for given faction.

bool psCharacter::CheckResponsePrerequisite ( NpcResponse resp)
void psCharacter::ClearLoot ( )

Clears the pending loot items array and money.

void psCharacter::ClearStatsDirtyFlags ( unsigned int  dirtyFlags)

Cleare the dirty flags for vitals.

void psCharacter::CombatDrain ( int  )
void psCharacter::CompleteGMEvent ( bool  playerIsGM)
void psCharacter::CompleteHelpEvent ( int  which) [inline]

Sets a bit field complete for a specified flag from the enum in tutorialmanager.h.

Definition at line 728 of file pscharacter.h.

Multiplier& psCharacter::DefenseModifier ( ) [inline]

Definition at line 1413 of file pscharacter.h.

virtual void psCharacter::DeleteSelf ( ) [inline, virtual]

< Delete must come from inside object to handle operator::delete overrides.

Implements iCachedObject.

Definition at line 807 of file pscharacter.h.

void psCharacter::DropItem ( psItem *&  item,
csVector3  pos = 0,
const csVector3 &  rot = csVector3(0),
bool  guarded = true,
bool  transient = true,
bool  inplace = false 
)

Drops an item into the world (one meter from this character's position).

Parameters:
itemto be dropped
posthe position
rotthe rotation
guardedTRUE if guarded
transientflag (decay?) (default=true)
inplaceTRUE if in place.
void psCharacter::EndSong ( csTicks  bonusTime)

Resets the song's execution data.

This must always be called when a song ends.

Parameters:
bonusTimewhen the next song starts, bonusTime will be summed to the actual execution time.
AccountID psCharacter::GetAccount ( ) const [inline]

Definition at line 841 of file pscharacter.h.

AccountID psCharacter::GetAccountId ( ) [inline]

Get the account ID that this character is attached to.

Returns:
The account ID that this character is attached to.

Definition at line 1657 of file pscharacter.h.

gemActor* psCharacter::GetActor ( ) [inline]

Definition at line 1514 of file pscharacter.h.

const char* psCharacter::GetAnimalAffinity ( ) [inline]

Definition at line 1357 of file pscharacter.h.

size_t psCharacter::GetAssignedGMEvents ( psGMEventListMessage gmevents,
int  clientnum 
)
psAttackQueue* psCharacter::GetAttackQueue ( ) [inline]

Get the attack queue.

Returns:
attack queue member

Definition at line 1683 of file pscharacter.h.

const char* psCharacter::GetBeltGroup ( ) [inline]

Definition at line 1228 of file pscharacter.h.

const char* psCharacter::GetBracerGroup ( ) [inline]

Definition at line 1224 of file pscharacter.h.

psBuddyManager& psCharacter::GetBuddyMgr ( ) [inline]

Definition at line 1639 of file pscharacter.h.

Buffable<int>& psCharacter::GetBuffableVariable ( const csString &  name,
const csString &  value = "0" 
)

Returns the reference to a buffable variable.

If not existant a temporary one is created with the passed value.

Parameters:
nameThe name of the variable to search for.
valueThe value.
Returns:
A buffable<int> with the value of the variable.
Buffable<int>& psCharacter::GetCanSummonFamiliar ( ) [inline]

Definition at line 1353 of file pscharacter.h.

const char* psCharacter::GetCharFullName ( ) const [inline]

Definition at line 868 of file pscharacter.h.

const char* psCharacter::GetCharLastName ( ) const [inline]

Definition at line 864 of file pscharacter.h.

unsigned int psCharacter::GetCharLevel ( bool  physical)

Returns a level of character based on his 6 base stats.

const char* psCharacter::GetCharName ( ) const [inline]

Definition at line 860 of file pscharacter.h.

unsigned int psCharacter::GetCharType ( ) const [inline]

Definition at line 889 of file pscharacter.h.

const char* psCharacter::GetCharTypeName ( ) [inline]

Definition at line 898 of file pscharacter.h.

const char* psCharacter::GetCloakGroup ( ) [inline]

Definition at line 1232 of file pscharacter.h.

float psCharacter::GetCounterBlockValueForWeaponInSlot ( INVENTORY_SLOT_NUMBER  slot)
const char* psCharacter::GetCreationInfo ( )

This is used to get the stored informations from the char creation.

Returns:
Returns a pointer to the stored informations from the char creation.
unsigned int psCharacter::GetDeaths ( ) const [inline]

Definition at line 1151 of file pscharacter.h.

const char* psCharacter::GetDescription ( )

This is used to get the stored player description.

Returns:
Returns a pointer to the stored player description.
float psCharacter::GetDodgeValue ( )
unsigned int psCharacter::GetExperiencePoints ( )
bool psCharacter::GetFactionEventsDescription ( csString &  factionDescription)

Gets dynamic life events generated from the factions of the character.

Parameters:
factionDescription,:where to store the dynamically generated data.
Returns:
Returns true if there were some dynamic life events founds else false.
FactionSet* psCharacter::GetFactions ( ) [inline]

Definition at line 1001 of file pscharacter.h.

PID psCharacter::GetFamiliarID ( size_t  id) [inline]

Definition at line 1340 of file pscharacter.h.

psGuildInfo* psCharacter::GetGuild ( ) [inline]

Return the active guild, if any for this character.

Definition at line 739 of file pscharacter.h.

psGuildLevel* psCharacter::GetGuildLevel ( )

Return the guild level for this character, if any.

psGuildMember* psCharacter::GetGuildMembership ( )

Return the guild membership for this character, if any.

const char* psCharacter::GetHelmGroup ( ) [inline]

Definition at line 1220 of file pscharacter.h.

float psCharacter::GetHP ( )
VitalBuffable& psCharacter::GetHPRate ( )
int psCharacter::GetImperviousToAttack ( ) [inline]

Definition at line 1619 of file pscharacter.h.

bool psCharacter::GetIsMarried ( ) const [inline]

Definition at line 941 of file pscharacter.h.

int psCharacter::GetKillExperience ( ) [inline]

The exp to be handed out when this actor dies.

Definition at line 1606 of file pscharacter.h.

unsigned int psCharacter::GetKills ( ) const [inline]

Definition at line 1147 of file pscharacter.h.

csString psCharacter::GetLastLoginTime ( ) const

Retrive the last login time in the format YYYY-MM-DD HH:MM:SS.

int psCharacter::GetLastResponse ( ) [inline]

The last_response given by an npc to this player.

Definition at line 1056 of file pscharacter.h.

const char* psCharacter::GetLifeDescription ( )

This is used to get the stored informations from the custom life events made by players.

Returns:
Returns a pointer to the stored informations from the custom life events made by players.
st_location psCharacter::GetLocation ( ) const [inline]

Get the character location.

Returns:
The struct that has the information about where the character is

Definition at line 1675 of file pscharacter.h.

void psCharacter::GetLocationInWorld ( InstanceID instance,
psSectorInfo *&  sectorinfo,
float loc_x,
float loc_y,
float loc_z,
float loc_yrot 
)
int psCharacter::GetLootCategory ( ) const [inline]

Definition at line 1010 of file pscharacter.h.

size_t psCharacter::GetLootItems ( psLootMessage msg,
EID  entity,
int  cnum 
)
int psCharacter::GetLootMoney ( )

Gets and zeroes the loot money.

float psCharacter::GetMana ( )
VitalBuffable& psCharacter::GetManaRate ( )
PID psCharacter::GetMasterNPCID ( ) const [inline]

Definition at line 832 of file pscharacter.h.

int psCharacter::GetMaxAllowedRealm ( PSSKILL  skill)

Get the maximum realm the caster can cast with given skill.

VitalBuffable& psCharacter::GetMaxHP ( )
VitalBuffable& psCharacter::GetMaxMana ( )
VitalBuffable& psCharacter::GetMaxMStamina ( )
VitalBuffable& psCharacter::GetMaxPStamina ( )
psCharacter* psCharacter::GetMerchant ( ) [inline]

Definition at line 1500 of file pscharacter.h.

psMerchantInfo* psCharacter::GetMerchantInfo ( ) [inline]

Definition at line 1443 of file pscharacter.h.

VitalBuffable& psCharacter::GetMStaminaRate ( )
int psCharacter::GetNotifications ( ) [inline]

gets the notification bitfield directly: to be used only by the save functon

Definition at line 772 of file pscharacter.h.

size_t psCharacter::GetNumFamiliars ( ) [inline]

Definition at line 1345 of file pscharacter.h.

const char* psCharacter::GetOldLastName ( ) const [inline]

Definition at line 872 of file pscharacter.h.

unsigned int psCharacter::GetOnlineTimeThisSession ( ) [inline]

Number of seconds online this session in seconds.

Definition at line 1525 of file pscharacter.h.

const char* psCharacter::GetOOCDescription ( )

This is used to get the stored player OOC description.

Returns:
Returns a pointer to the stored player OOC description.
OverridableRace& psCharacter::GetOverridableRace ( )

Gets a reference to the overridable race allowing to override it or check the base race.

Returns:
A
See also:
OverridableRace reference in this psCharacter
PID psCharacter::GetOwnerID ( ) [inline]

Definition at line 1365 of file pscharacter.h.

double psCharacter::GetPetElapsedTime ( ) const

Retrive the elapsed time for pets.

PID psCharacter::GetPID ( ) const [inline]

Definition at line 827 of file pscharacter.h.

unsigned int psCharacter::GetProgressionPoints ( )
double psCharacter::GetProperty ( MathEnvironment env,
const char *  ptr 
) [virtual]

This is used by the math scripting engine to get various values.

Implements iScriptableVar.

VitalBuffable& psCharacter::GetPStaminaRate ( )
psCharacterQuestManager& psCharacter::GetQuestMgr ( ) [inline]

Definition at line 1643 of file pscharacter.h.

psRaceInfo* psCharacter::GetRaceInfo ( )

Gets the pointer to the global current raceinfo applied to this character.

Returns:
A
See also:
psRaceInfo pointer
float psCharacter::GetScale ( )

Gets the scale including any buffs.

Scale consist of a baseScale value from RaceInfo mutliplied with any buffs.

Returns:
A float which contains the final scale of the model.
float psCharacter::GetScaleValue ( )

Gets the user scale value.

Use

See also:
GetScale to get final model scale value. This function return the scale from character_values and any buffs.
Returns:
A float which contains the user scale value.
void psCharacter::GetSkillBaseValues ( MathEnvironment env)
psSkillCache* psCharacter::GetSkillCache ( ) [inline]

Returns a pointer to the skill cache for this character.

Definition at line 790 of file pscharacter.h.

SkillRank& psCharacter::GetSkillRank ( PSSKILL  skill) [inline]

Definition at line 1132 of file pscharacter.h.

void psCharacter::GetSkillValues ( MathEnvironment env)

Function to get the base and current skill values.

bool psCharacter::GetSlotAttackable ( INVENTORY_SLOT_NUMBER  slot)

Returns true if the character is able to attack with the current slot.

This could be true even if the slot is empty (as in fists). It could also be false due to effects or other properties.

bool psCharacter::GetSlotAutoAttackable ( INVENTORY_SLOT_NUMBER  slot)
int psCharacter::GetSlotEventId ( INVENTORY_SLOT_NUMBER  slot)
bool psCharacter::GetSlotSingleAttackable ( INVENTORY_SLOT_NUMBER  slot)
csTicks psCharacter::GetSongStartTime ( ) const [inline]

Gets the starting time of the song that the player is currently playing.

Definition at line 1291 of file pscharacter.h.

st_location psCharacter::GetSpawnLocation ( ) [inline]

Get the character spawn location.

Returns:
The struct that has the information about where the character spawns.

Definition at line 1666 of file pscharacter.h.

psSpell* psCharacter::GetSpellByIdx ( int  index)
psSpell* psCharacter::GetSpellByName ( const csString &  spellName)
csArray<psSpell*>& psCharacter::GetSpellList ( ) [inline]

Definition at line 1494 of file pscharacter.h.

const char* psCharacter::GetSpouseName ( ) const [inline]

Gets Spouse Name of a character.

Returns:
SpouseName or "" if not married.

Definition at line 933 of file pscharacter.h.

float psCharacter::GetStamina ( bool  pys)
float psCharacter::GetStatModifier ( PSITEMSTATS_STAT  attrib)
unsigned int psCharacter::GetStatsDirtyFlags ( ) const

Return the dirty flags for vitals.

unsigned int psCharacter::GetSuicides ( ) const [inline]

Definition at line 1155 of file pscharacter.h.

float psCharacter::GetTargetedBlockValueForWeaponInSlot ( INVENTORY_SLOT_NUMBER  slot)

Retrieves the calculated Attack Value for the given weapon-slot.

unsigned int psCharacter::GetTimeConnected ( ) [inline]

Definition at line 1537 of file pscharacter.h.

unsigned int psCharacter::GetTotalOnlineTime ( ) [inline]

Number of seconds online ever including this session in seconds.

Definition at line 1531 of file pscharacter.h.

float psCharacter::GetTotalTargetedBlockValue ( )
float psCharacter::GetTotalUntargetedBlockValue ( )
TradingStatus psCharacter::GetTradingStatus ( ) [inline]

Definition at line 1504 of file pscharacter.h.

psCharacter* psCharacter::GetTrainer ( ) [inline]

Definition at line 1455 of file pscharacter.h.

psTrainerInfo* psCharacter::GetTrainerInfo ( ) [inline]

Definition at line 1451 of file pscharacter.h.

psTrait* psCharacter::GetTraitForLocation ( PSTRAIT_LOCATION  location)
float psCharacter::GetUntargetedBlockValueForWeaponInSlot ( INVENTORY_SLOT_NUMBER  slot)
csHash<charVariable, csString>::ConstGlobalIterator psCharacter::GetVariables ( ) const

Retrive const iterator for character variables.

csString psCharacter::GetVariableValue ( const csString &  name)

Returns the value of a variable.

Parameters:
nameThe name of the variable to search for.
Returns:
A csString with the value of the variable.
bool psCharacter::HasExploredArea ( PID  explored)

Check if an area has already been explored.

Parameters:
exploredThe PID of the area npc.
bool psCharacter::HasVariableDefined ( const csString &  name)

Checks if a variable was defined for this character.

Parameters:
nameThe name of the variable to search for.
Returns:
TRUE if the variable was found.
bool psCharacter::Introduce ( psCharacter c)

Introduces this character to the given character; answers false if already introduced.

psCharacterInventory& psCharacter::Inventory ( ) [inline]

Definition at line 678 of file pscharacter.h.

bool psCharacter::IsBanker ( ) const [inline]

Check if the character is a banker.

Definition at line 1299 of file pscharacter.h.

bool psCharacter::IsGettingAllianceNotifications ( ) [inline]

Returns if the client should receive notifications about alliance members logging in.

Definition at line 754 of file pscharacter.h.

bool psCharacter::IsGettingGuildNotifications ( ) [inline]

Returns if the client should receive notifications about guild members logging in.

Definition at line 749 of file pscharacter.h.

bool psCharacter::IsHired ( ) [inline]

Definition at line 1373 of file pscharacter.h.

bool psCharacter::IsMerchant ( ) [inline]

Definition at line 1439 of file pscharacter.h.

bool psCharacter::IsMount ( ) [inline]

Used to determine if this NPC is a mount.

Definition at line 1336 of file pscharacter.h.

bool psCharacter::IsNPC ( ) [inline]

Definition at line 1315 of file pscharacter.h.

bool psCharacter::IsPet ( ) [inline]

Used to determine if this NPC is a pet.

Definition at line 1331 of file pscharacter.h.

bool psCharacter::IsPlayer ( ) [inline]

Used to determine if this character is a player.

Returns:
TRUE if the character is a player.

Definition at line 1325 of file pscharacter.h.

bool psCharacter::IsStatue ( ) [inline]

Definition at line 673 of file pscharacter.h.

bool psCharacter::IsStorage ( ) const [inline]

Check if the character is a storage.

Returns:
TRUE if the character mantains a storage

Definition at line 1309 of file pscharacter.h.

bool psCharacter::IsTrainer ( ) [inline]

Definition at line 1447 of file pscharacter.h.

void psCharacter::KilledBy ( psCharacter attacker) [inline]

Definition at line 1137 of file pscharacter.h.

void psCharacter::Kills ( psCharacter target) [inline]

Definition at line 1142 of file pscharacter.h.

bool psCharacter::Knows ( psCharacter c) [inline]

Definition at line 880 of file pscharacter.h.

bool psCharacter::Knows ( PID  charid)

Answers whether this character knows the given character or not.

bool psCharacter::Load ( iResultRow &  row)
void psCharacter::LoadActiveSpells ( )
bool psCharacter::LoadAdvantages ( PID  use_id) [protected]
bool psCharacter::LoadBuddies ( Result myBuddy,
Result buddyOf 
) [protected]
bool psCharacter::LoadExploration ( Result exploration) [protected]
bool psCharacter::LoadFactions ( PID  pid) [protected]

Helper function which loads the factions from the database.

bool psCharacter::LoadFamiliar ( Result pet,
Result owner 
) [protected]
bool psCharacter::LoadGMEvents ( ) [protected]
void psCharacter::LoadIntroductions ( )
bool psCharacter::LoadMarriageInfo ( Result result) [protected]
bool psCharacter::LoadRelationshipInfo ( PID  pid) [protected]
bool psCharacter::LoadSkills ( PID  use_id) [protected]
bool psCharacter::LoadSpells ( PID  use_id) [protected]
bool psCharacter::LoadTraits ( PID  use_id) [protected]
bool psCharacter::LoadVariables ( PID  pid) [protected]

Helper function which loads the character variables from the database.

Returns:
TRUE always. bool was used for consistancy.
void psCharacter::MakeEquipmentString ( csString &  equipmentString)

Construct an XML format string of the player's equipment.

void psCharacter::MakeTextureString ( csString &  textureString)

Construct an XML format string of the player's texture choices.

psMoney psCharacter::Money ( ) [inline]

Definition at line 683 of file pscharacter.h.

bool psCharacter::NeedsHelpEvent ( int  which) [inline]

Checks the bit field for a bit flag from the enum in TutorialManager.h.

Definition at line 722 of file pscharacter.h.

int psCharacter::NPC_GetSpawnRuleID ( ) [inline]

Definition at line 1630 of file pscharacter.h.

void psCharacter::NPC_SetSpawnRuleID ( int  v) [inline]

Definition at line 1634 of file pscharacter.h.

void psCharacter::operator delete ( void *  )

The delete operator is overriden to call PoolAllocator template functions.

void* psCharacter::operator new ( size_t  )

The new operator is overriden to call PoolAllocator template functions.

void psCharacter::PracticeArmorSkills ( unsigned int  practice,
INVENTORY_SLOT_NUMBER  attackLocation 
)

Practice skills for armor and weapons.

void psCharacter::PracticeWeaponSkills ( unsigned int  practice)
void psCharacter::PracticeWeaponSkills ( psItem weapon,
unsigned int  practice 
)
virtual void psCharacter::ProcessCacheTimeout ( ) [inline, virtual]

required for iCachedObject but not used here

Implements iCachedObject.

Definition at line 802 of file pscharacter.h.

bool psCharacter::QuickLoad ( iResultRow &  row,
bool  noInventory 
)

Load the bare minimum to know what this character is looks like.

bool psCharacter::ReadyToExchange ( )
void psCharacter::RecalculateStats ( )
virtual void* psCharacter::RecoverObject ( ) [inline, virtual]

< Turn iCachedObject ptr into psCharacter

Implements iCachedObject.

Definition at line 803 of file pscharacter.h.

void psCharacter::RemoveGMEvent ( int  id,
bool  playerIsGM = false 
)
psItem* psCharacter::RemoveLootItem ( int  id)

Removes an item from the loot loaded on the character due to it's defeat.

It searches for an item with the base stats item having the passed id and returns it if it was found, removing it from the list of the lootable items.

Parameters:
idThe base item stats id of the item.
Returns:
The psItem whch void DiscardQuest(QuestAssignment *q, bool force = false);corresponds to the base stats item searched for.
csArray<psItem*> psCharacter::RemoveLootItems ( csArray< csString >  categories = csArray< csString >())

Removes either all or only those items with specified categories from the loot of a defeated character.

Checks whether the items in lootPending fit the specified categories and removes them accordingly.

Parameters:
[categories]A csArray containing csStrings with category names. If parameter is not provided, all items will be removed.
Returns:
A csArray containing pointers to the removed psItem(s)
void psCharacter::ResetStats ( )
void psCharacter::ResetSwings ( csTicks  timeofattack)
void psCharacter::SaveLocationInWorld ( )
void psCharacter::SaveMoney ( bool  bank)
bool psCharacter::SendStatDRMessage ( uint32_t  clientnum,
EID  eid,
int  flags,
csRef< PlayerGroup group = NULL 
)
void psCharacter::SetAccount ( AccountID  id) [inline]

Definition at line 837 of file pscharacter.h.

void psCharacter::SetActor ( gemActor actor)
void psCharacter::SetAllianceNotifications ( bool  enabled) [inline]

Sets if the client should receive notifications about alliance members logging in.

Definition at line 765 of file pscharacter.h.

void psCharacter::SetAllStatsDirty ( )

Set all vital stats dirty.

void psCharacter::SetAnimialAffinity ( const char *  v) [inline]

Definition at line 1361 of file pscharacter.h.

void psCharacter::SetBeltGroup ( const char *  Group) [inline]

Definition at line 1245 of file pscharacter.h.

void psCharacter::SetBracerGroup ( const char *  Group) [inline]

Definition at line 1241 of file pscharacter.h.

void psCharacter::SetCharType ( unsigned int  v) [inline]

Definition at line 893 of file pscharacter.h.

void psCharacter::SetCloakGroup ( const char *  Group) [inline]

Definition at line 1249 of file pscharacter.h.

void psCharacter::SetCreationInfo ( const char *  newValue)

This is used to store the informations from the char creation.

Players shouldn't be able to edit this.

Parameters:
newValue,:A pointer to the new string to set as char creation data.
void psCharacter::SetDescription ( const char *  newValue)

This is used to store the player description.

Parameters:
newValue,:A pointer to the new string to set as player description.
void psCharacter::SetExperiencePoints ( unsigned int  W)
void psCharacter::SetFamiliarID ( PID  v)
void psCharacter::SetFullName ( const char *  newFirstName,
const char *  newLastName 
)
void psCharacter::SetGuild ( psGuildInfo g) [inline]

Set the active guild for the character.

Definition at line 734 of file pscharacter.h.

void psCharacter::SetGuildNotifications ( bool  enabled) [inline]

Sets if the client should receive notifications about guild members logging in.

Definition at line 759 of file pscharacter.h.

void psCharacter::SetHelmGroup ( const char *  Group) [inline]

Definition at line 1237 of file pscharacter.h.

void psCharacter::SetHired ( bool  hired) [inline]

Definition at line 1377 of file pscharacter.h.

void psCharacter::SetHitPoints ( float  v)
void psCharacter::SetImperviousToAttack ( int  newValue) [inline]

Definition at line 1615 of file pscharacter.h.

void psCharacter::SetIsMarried ( bool  married) [inline]

Definition at line 937 of file pscharacter.h.

void psCharacter::SetKillExperience ( int  newValue) [inline]

Definition at line 1610 of file pscharacter.h.

void psCharacter::SetLastLoginTime ( )

Set the last login time for the character.

void psCharacter::SetLastName ( const char *  newLastName) [inline]

Definition at line 850 of file pscharacter.h.

void psCharacter::SetLastResponse ( int  response) [inline]

Definition at line 1060 of file pscharacter.h.

void psCharacter::SetLifeDescription ( const char *  newValue)

This is used to store the informations sent by players for their custom life events.

Parameters:
newValue,:A pointer to the new string to set as custom life events.
void psCharacter::SetLocationInWorld ( InstanceID  instance,
psSectorInfo sectorinfo,
float  loc_x,
float  loc_y,
float  loc_z,
float  loc_yrot 
)
void psCharacter::SetLootCategory ( int  id) [inline]

Definition at line 1006 of file pscharacter.h.

void psCharacter::SetMana ( float  v)
void psCharacter::SetMoney ( psItemStats MoneyObject,
int  amount 
)

Add a certain amount of a money object to the current wallet based on the baseitem data.

This is used to give rewards in gmeventmanager for now.

Parameters:
MoneyObjectThe money base object which was rewarded.
amountThe amount of the base object which was rewarded.
void psCharacter::SetMoney ( psItem *&  moneyObject)

Add a money object to the current wallet.

This is used when money is picked up and will destory the object passed in.

Parameters:
moneyObjectThe money object that was just picked up.
void psCharacter::SetMoney ( psMoney  m)
void psCharacter::SetName ( const char *  newName) [inline]

Definition at line 846 of file pscharacter.h.

void psCharacter::SetNotifications ( int  notifications) [inline]

sets the notification bitfield directly: to be used only by the loader functon

Definition at line 777 of file pscharacter.h.

void psCharacter::SetOldLastName ( const char *  oldLastName) [inline]

Definition at line 855 of file pscharacter.h.

void psCharacter::SetOOCDescription ( const char *  newValue)

This is used to store the player OOC description.

Parameters:
newValue,:A pointer to the new string to set as player OOC description.
void psCharacter::SetOwnerID ( PID  v) [inline]

Definition at line 1369 of file pscharacter.h.

void psCharacter::SetPetElapsedTime ( double  elapsedTime)

Set the elapsed time for pets.

void psCharacter::SetPID ( PID  characterID) [inline]

Definition at line 823 of file pscharacter.h.

void psCharacter::SetProgressionPoints ( unsigned int  X,
bool  save 
)
void psCharacter::SetRaceInfo ( psRaceInfo rinfo)

Sets the provided race info as the base default one.

Don't use this to change temporarily the raceinfo but only definitely (or upon load)

Parameters:
rinfoA pointer to a
See also:
psRaceInfo
void psCharacter::SetSkillRank ( PSSKILL  which,
unsigned int  rank 
)

Directly sets rank of given skill.

It completely bypasses the skill logic, it is used for testing only.

void psCharacter::SetSpouseName ( const char *  name)

Set the name of the spouse.

void psCharacter::SetStamina ( float  v,
bool  pys 
)
void psCharacter::SetStaminaRegenerationNone ( bool  physical = true,
bool  mental = true 
)
void psCharacter::SetStaminaRegenerationSitting ( )
void psCharacter::SetStaminaRegenerationStill ( bool  physical = true,
bool  mental = true 
)
void psCharacter::SetStaminaRegenerationWalk ( bool  physical = true,
bool  mental = true 
)
void psCharacter::SetStaminaRegenerationWork ( int  skill)
void psCharacter::SetTradingStatus ( TradingStatus  trading,
psCharacter merchant 
) [inline]

Definition at line 1508 of file pscharacter.h.

bool psCharacter::SetTradingStopped ( bool  stopped)
void psCharacter::SetTrainer ( psCharacter trainer) [inline]

Definition at line 1459 of file pscharacter.h.

void psCharacter::SetTraitForLocation ( PSTRAIT_LOCATION  location,
psTrait trait 
)
void psCharacter::SetVariable ( const csString &  name,
const csString &  value 
)

Sets a new variable for this character.

Parameters:
nameThe name of the new variable.
valueThe value of the new variable.
void psCharacter::SetVariable ( const csString &  name)

Sets a new variable for this character.

The value will be set to a default empty string.

Parameters:
nameThe name of the new variable.
SkillSet& psCharacter::Skills ( ) [inline]

Definition at line 782 of file pscharacter.h.

void psCharacter::StartSong ( )

Takes care of setting correctly all the data needed to keep track of the song.

bool psCharacter::Store ( const char *  location,
const char *  slot,
psItem what 
)
void psCharacter::TagEquipmentObject ( INVENTORY_SLOT_NUMBER  slot,
int  eventId 
)
const char* psCharacter::ToString ( ) [inline, virtual]

Implements iScriptableVar.

Definition at line 1600 of file pscharacter.h.

void psCharacter::Train ( PSSKILL  skill,
int  yIncrease 
)

Trains a skill.

It will only train up to the cost of the next rank. So the yIncrease is capped by the cost and anything over will be lost.

Parameters:
skillThe skill we want to train.
yIncreaseThe amount we want to train this skill by.
bool psCharacter::Unintroduce ( psCharacter c)

Unintroduces this character to the given character; answers false if not introduced.

void psCharacter::UnSetVariable ( const csString &  name)

Remove a variable from this character.

Parameters:
nameThe name of the variable to remove.
bool psCharacter::UpdateFaction ( Faction faction,
int  delta 
)

Update this faction for this player with delta value.

void psCharacter::UpdateFactions ( ) [protected]

Helper function which saves the factions to the database.

void psCharacter::UpdateRespawn ( csVector3  pos,
float  yrot,
psSectorInfo sector,
InstanceID  instance 
)

Update a npc's default spawn position with given data.

bool psCharacter::UpdateStatDRData ( csTicks  now)
void psCharacter::UpdateVariables ( ) [protected]

Helper function which saves the character variables to the database.

void psCharacter::UseProgressionPoints ( unsigned int  X)

Member Data Documentation

AccountID psCharacter::accountid [protected]

Account ID that this characater is attached to.

Definition at line 1736 of file pscharacter.h.

csSet<PID> psCharacter::acquaintances [protected]

Definition at line 1719 of file pscharacter.h.

The current game entity object this characater is attached to.

Definition at line 1734 of file pscharacter.h.

csString psCharacter::animalAffinity [protected]

Definition at line 1783 of file pscharacter.h.

Definition at line 1804 of file pscharacter.h.

Attack value is multiplied by this.

Definition at line 1748 of file pscharacter.h.

Definition at line 1826 of file pscharacter.h.

Money stored in the players bank account.

Definition at line 1797 of file pscharacter.h.

Definition at line 1725 of file pscharacter.h.

Definition at line 1786 of file pscharacter.h.

Definition at line 1814 of file pscharacter.h.

const char* psCharacter::characterTypeName[] [static, protected]

Definition at line 1813 of file pscharacter.h.

csHash<charVariable, csString> psCharacter::charVariables [protected]

Used to store character variables for this character.

Definition at line 1801 of file pscharacter.h.

csString psCharacter::creationinfo [protected]

Creation manager informations.

Definition at line 1743 of file pscharacter.h.

Definition at line 1721 of file pscharacter.h.

Defense value is multiplied by this.

Definition at line 1749 of file pscharacter.h.

csString psCharacter::description [protected]

Player description.

Definition at line 1741 of file pscharacter.h.

A bitfield which contains the notifications the player will get if a guild or alliance member login/logoff.

Definition at line 1807 of file pscharacter.h.

Definition at line 1763 of file pscharacter.h.

Definition at line 1785 of file pscharacter.h.

csString psCharacter::fullName [protected]

Definition at line 1755 of file pscharacter.h.

Definition at line 1716 of file pscharacter.h.

Bitfield for which help events a character has already encountered.

Definition at line 1770 of file pscharacter.h.

Definition at line 1767 of file pscharacter.h.

Character's inventory handler.

Definition at line 1715 of file pscharacter.h.

bool psCharacter::isMarried [protected]

Definition at line 1759 of file pscharacter.h.

bool psCharacter::isStatue [protected]

Says if this npc is a statue.

Definition at line 1823 of file pscharacter.h.

Definition at line 1808 of file pscharacter.h.

Kill Exp.

Definition at line 1746 of file pscharacter.h.

Definition at line 1722 of file pscharacter.h.

csString psCharacter::lastLoginTime [protected]

String value copied from the database containing the last login time.

Definition at line 1792 of file pscharacter.h.

csString psCharacter::lastname [protected]

Definition at line 1754 of file pscharacter.h.

Last response of an NPC to this character (not saved)

Definition at line 1819 of file pscharacter.h.

Store time for when the petElapsedTime was last saved to db.

Definition at line 1794 of file pscharacter.h.

csString psCharacter::lifedescription [protected]

Custom life events informations.

Definition at line 1744 of file pscharacter.h.

bool psCharacter::loaded [protected]

Definition at line 1724 of file pscharacter.h.

Definition at line 1772 of file pscharacter.h.

Id of Loot category to use if this char has extra loot.

Definition at line 1781 of file pscharacter.h.

Amount of money ready to be looted.

Definition at line 1821 of file pscharacter.h.

Array of items waiting to be looted.

Definition at line 1817 of file pscharacter.h.

The merchant this charcter trade with.

Definition at line 1729 of file pscharacter.h.

Character's merchant info.

Definition at line 1728 of file pscharacter.h.

Definition at line 1717 of file pscharacter.h.

Current cash set on player.

Definition at line 1796 of file pscharacter.h.

csString psCharacter::name [protected]

Definition at line 1753 of file pscharacter.h.

Definition at line 1720 of file pscharacter.h.

NPC specific data. Should this go here?

Definition at line 1778 of file pscharacter.h.

csString psCharacter::oldlastname [protected]

Definition at line 1756 of file pscharacter.h.

csString psCharacter::oocdescription [protected]

Player OOC description.

Definition at line 1742 of file pscharacter.h.

Definition at line 1810 of file pscharacter.h.

These values are loaded from base_hp_max,base_mana_max in the db and < should prevent normal HP calculations from taking place.

Definition at line 1810 of file pscharacter.h.

PID psCharacter::ownerId [protected]

Definition at line 1784 of file pscharacter.h.

double psCharacter::petElapsedTime [protected]

Definition at line 1793 of file pscharacter.h.

PID psCharacter::pid [protected]

Current PID for this characater ( or is it the above entity? )

Definition at line 1735 of file pscharacter.h.

csString psCharacter::progressionScriptText [protected]

flat string loaded from the DB.

Definition at line 1765 of file pscharacter.h.

Definition at line 1726 of file pscharacter.h.

Holds the race of this character and it's overriden values.

Definition at line 1761 of file pscharacter.h.

Definition at line 1803 of file pscharacter.h.

Definition at line 1718 of file pscharacter.h.

Definition at line 1751 of file pscharacter.h.

Definition at line 1799 of file pscharacter.h.

csString psCharacter::spouseName [protected]

Definition at line 1758 of file pscharacter.h.

csTicks psCharacter::startTimeThisSession [protected]

Definition at line 1790 of file pscharacter.h.

Definition at line 1723 of file pscharacter.h.

Total number of seconds online. Updated at logoff.

Definition at line 1789 of file pscharacter.h.

See the enum for the various status.

Definition at line 1732 of file pscharacter.h.

bool psCharacter::tradingStopped [protected]

Definition at line 1731 of file pscharacter.h.

The current character that is being trained?

Definition at line 1739 of file pscharacter.h.

Character's trainer information.

Definition at line 1738 of file pscharacter.h.

psTrait* psCharacter::traits[PSTRAIT_LOCATION_COUNT] [protected]

Definition at line 1775 of file pscharacter.h.

Definition at line 1773 of file pscharacter.h.


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