Difference between revisions of "MagicItemHasEffectCode"

From the Oblivion ConstructionSet Wiki
Jump to navigation Jump to search
imported>WereWolf
(Fixed format & added OBSE link)
imported>WereWolf
Line 1: Line 1:
A command for [[:Category:Oblivion Script Extender|Oblivion Script Extender]]
A command for [[:Category:Oblivion Script Extender|Oblivion Script Extender]]
MagicItemHasEffectCode - returns whether the magic item has an effect item with the specified effect code. Uses a long value returned from GetNthEffectItemCode or GetMagicEffectCode.


'''Syntax:'''
'''Syntax:'''
Line 7: Line 5:


  (hasEffect:bool) MagicHasEffectC effectCode:long magicItem:ref
  (hasEffect:bool) MagicHasEffectC effectCode:long magicItem:ref
Returns whether the magic item has an effect item with the specified effect code.


==Notes==
==Notes==
* Using '''MagicItemHasEffectCode''' on a magic item that doesn't have any effects (for instance, after using [[RemoveAllEffectItems]] on the item) will cause Oblivion to crash.
* Uses a long value returned from [[GetNthEffectItemCode]] or [[GetMagicEffectCode]].
** However, using '''MagicItemHasEffectCode''' on a non-magic item will not cause a crash.
* Using [[MagicItemHasEffectCode]] on a magic item that doesn't have any effects (for instance, after using [[RemoveAllEffectItems]] on the item) will cause Oblivion to crash.
** However, using [[MagicItemHasEffectCode]] on a non-magic item will not cause a crash.


==See Also==
==See Also==

Revision as of 13:46, 14 September 2007

A command for Oblivion Script Extender

Syntax:

(hasEffect:bool) MagicItemHasEffectCode effectCode:long magicItem:ref
(hasEffect:bool) MagicHasEffectC effectCode:long magicItem:ref

Returns whether the magic item has an effect item with the specified effect code.

Notes

See Also