GetHasEffect(int, object)
Determines whether a creature has an effect.
int GetHasEffect( int nEffectType, object oTarget = OBJECT_SELF );
Parameters
nEffectType
The type of effect, from the constant list EFFECT_TYPE_*, we are interested in.
oTarget
The object to investigate. (Default: OBJECT_SELF)
Description
Returns TRUE if oTarget has the effect nEffectType active, otherwise FALSE.
Requirements
#include "x0_i0_match"
Version
1.28
Example
#include "NW_I0_GENERIC" void main() { int isPoisoned = GetHasEffect(EFFECT_TYPE_POISON, GetFirstPC()); int isParalyzed = GetHasEffect(EFFECT_TYPE_PARALYZE, GetFirstPC()); }
See Also
categories: | Effects Functions |
constants: | EFFECT_TYPE_* Constants |
author: Tom Cassiotis, editors: Charles Feduke, Mistress