Difference between revisions of "UnequipItem"

From the Fallout3 GECK Wiki
Jump to navigation Jump to search
imported>Cipscis
m (Added note based on observations. I'd welcome someone to word the note better, as it feels very clumsy to me)
imported>Cipscis
(→‎Notes: Added work-around for noted bug. Still clumsily worded I'm afraid)
Line 10: Line 10:


=='''Notes'''==
=='''Notes'''==
*If UnequipItem is called on the player while they're viewing their inventory, whether or not the visual "equipped" indicator is updated immediately depends on the HideEquipMessage flag.  If it's set to 0, the graphic will update immediately, but if it's set to 1 the graphic won't update until another graphic updates.
*If UnequipItem is called on the player while they're viewing their inventory, whether or not the visual "equipped" indicator is updated immediately depends on the HideEquipMessage flag.  If it's set to 0, the graphic will update immediately, but if it's set to 1 the graphic won't update until another graphic updates. Running the following code will prevent this bug:
UnequipItem ObjectID 0 1
AddItem ObjectID 1 1
RemoveItem ObjectID 1 1


[[Category:Functions]]
[[Category:Functions]]
[[Category:Actor Functions]]
[[Category:Actor Functions]]
[[Category:Object Functions]]
[[Category:Object Functions]]

Revision as of 04:46, 22 December 2008

Description

UnEquipItem forces an actor to unequip an item.

Syntax:

[ActorID.]UnEquipItem ObjectID NoEquipFlag HideEquipMessage

Parameters

  • If NoEquipFlag = 1, actor (including the player) will be unable to equip the item. Once the item is equipped with the EquipItem function, the item can be equipped and unequipped as normal.
  • If HideEquipMessage = 1, the item unequipped message will be hidden from the player.

Notes

  • If UnequipItem is called on the player while they're viewing their inventory, whether or not the visual "equipped" indicator is updated immediately depends on the HideEquipMessage flag. If it's set to 0, the graphic will update immediately, but if it's set to 1 the graphic won't update until another graphic updates. Running the following code will prevent this bug:
UnequipItem ObjectID 0 1
AddItem ObjectID 1 1
RemoveItem ObjectID 1 1