GetLawChaosValue

From NWN Lexicon

Contents

[edit] GetLawChaosValue(object)

Used to find an object's law/chaos value.

int GetLawChaosValue(
    object oCreature
);

[edit] Parameters

oCreature

Object to determine law / chaos value for.


[edit] Description

Returns an integer between 0 and 100 (inclusive) to represent oCreature's Law/Chaos alignment (100=law, 0=chaos)
Return value if oCreature is not a valid creature: -1



[edit] Known Bugs

Previously noted bugs have been fixed in a patch some time ago.


[edit] Version

1.30

[edit] Example

// Sends a message to the first player indicating their law value 
void main()
{
    int iChaosLaw = GetLawChaosValue(GetFirstPC());
    SendMessageToPC(GetFirstPC(),"Your Law/Chaos Value == " + IntToString(iChaosLaw));
}

[edit] See Also

functions: 

GetGoodEvilValue



 author: GoLeM, editor: Lilac Soul, additional contributor(s): Lilac Soul
 

Personal tools
Categories