RemoveItem
From GECK
A function included in the GECK for Fallout 3.
Contents
Description
Removes and destroys Count items of object ObjectID from the calling container's inventory. It has two required parameters (the object to remove and the quantity) and one optional parameter (whether to display a message on screen).
Syntax
ActorID|ContainerID.RemoveItem ObjectID:ref Count:int HideMessageFlag:int
Examples
buddyref.RemoveItem Stimpack 11
Buddy loses 11 stimpacks
player.RemoveItem SuperStimpak 10
The player loses 10 super stimpacks and message displays like normal
player.RemoveItem SuperStimpak 10 1
10 super stimpacks are removed from the player's inventory and no message would be displayed
Notes
- You can use a FormList as the item parameter - in this case, the function removes the count for each item in the list.
- The items are destroyed - despite the name, they are not simply "removed" from the container and placed nearby.
- If the removed item was equipped, will NOT run the OnUnequip block.
- If lStewieAl's Tweaks is installed then the command can be used in the console without specifying a quantity. This does not apply to scripts made in the GECK however.