GetGold(object)
Gets the amount of gold that a creature possesses.
int GetGold( object oTarget = OBJECT_SELF );
Parameters
oTarget
The creature to inspect for gold. (Default: OBJECT_SELF)
Description
Returns the amount of gold possessed by oTarget.
Version
1.22
Example
// This can be used to only say a line in a conversation if the
// speaker has 100gp or more.
int StartingConditional()
{
int iResult;
iResult = (GetGold(GetPCSpeaker()) >= 100);
return iResult;
}
See Also
| functions: | GiveGoldToCreature | HasGold |
| categories: | Money Functions |
author: Tom Cassiotis, editor: Kristian Markon
Send comments on this topic.