InvisibleTrue
From NWN Lexicon
Contents |
[edit] InvisibleTrue(object)
Returns TRUE if the object is hidden either magically or via stealth.
int InvisibleTrue( object oSelf = OBJECT_SELF );
[edit] Parameters
oSelf
The object whose invisibility status you want to know.
[edit] Description
Returns TRUE if the object is hidden either magically or via stealth.
[edit] Remarks
If any of the following effects are active on oSelf, then this function will return TRUE:
- EFFECT_TYPE_INVISIBILITY
- EFFECT_TYPE_IMPROVEDINVISIBILITY
- SPELL_DARKNESS AND SPELL_DARKVISION
- ACTION_MODE_STEALTH
- EFFECT_TYPE_SANCTUARY
- EFFECT_TYPE_ETHEREAL
Otherwise this function returns FALSE.
[edit] Requirements
#include " nw_i0_generic "
[edit] Version
???
[edit] Example
// Check to see if the calling object is invisible or not. Then perform actions based on their invisible status. #include "nw_i0_generic" void main() { // Check that OBJECT_SELF is or isn't currently invisible. int nCheck = InvisibleTrue(OBJECT_SELF); if(nCheck == TRUE) { // Do stuff cause they ARE invisible in one way or another. } else { //Do other stuff cauese they ARE NOT invisible. } }
[edit] See Also
functions: |
author: Baragg, editors: Mistress, Kolyana