IsWeapon
Revision as of 10:45, 19 August 2006 by imported>DragoonWraith (OBSE)
A command for Oblivion Script Extender
Syntax:
[ItemID.]IsWeapon
Returns true if the calling object is classed as a weapon.
Example
set Self to GetSelf set Weapon to GetInventoryObject N if ( Weapon.IsWeapon != 0 ) && ( Self.GetEquipped Weapon != 0 ) ;Weapon is a weapon and is equipped else ;weapon is not a weapon set Weapon to 0 set N to ( N + 1 ) endif
This script will find the player's equipped weapon (which could have been done far more easily using GetEquippedObject, but that's besides the point).