GetItemCursedFlag
From NWN Lexicon
Contents |
[edit] GetItemCursedFlag(object)
Checks if an item is cursed
int GetItemCursedFlag( object oItem );
[edit] Parameters
oItem
Item to determine if is cursed
[edit] Description
Returns TRUE if the item is cursed and cannot be dropped.
[edit] Remarks
See SetItemCursedFlag() for more information about what exactly this flag will do for an item.
[edit] Version
1.62
[edit] Example
// We are going to destroy everything in the dying PC's // inventory, except, of course, the things that can't be dropped! void main() { // Get the dead PC object oPC = GetLastPlayerDied(); // Evil module! We destroy all items except: // * Plot items // * Undroppable (cursed flag) items object oItem = GetFirstItemInInventory(oPC); while(GetIsObjectValid(oItem)) { // Destroy it if not undroppable if(!GetPlotFlag(oItem) && !GetItemCursedFlag(oItem)) { DestroyObject(oItem); } oItem = GetNextItemInInventory(oPC); } }
[edit] See Also
functions: |
author: Lilac Soul, editor: Jasperre, additional contributor(s): Jasperre