Difference between revisions of "RemoveAllTypedItems"
imported>Yukichigai (Cleanup. Also, I believe the first note is not accurate any longer.) |
imported>HunterZ (remove horribly confusing "not", and add some new vegas type codes) |
||
Line 1: | Line 1: | ||
{{Function | {{Function | ||
|origin = VEGAS1 | |origin = VEGAS1 | ||
|summary = Removes all typed items (except those | |summary = Removes all typed items (except those listed in the exemption [[FormList]]) from the calling reference's inventory. | ||
If a target container is specified, the typed items are moved to the target container with all equipment items retaining their current health; otherwise the items are destroyed as they would be via [[RemoveItem]]. | If a target container is specified, the typed items are moved to the target container with all equipment items retaining their current health; otherwise the items are destroyed as they would be via [[RemoveItem]]. | ||
If the ''retain ownership'' flag is set to a non-zero value, the items' original ownership is retained; otherwise the ownership is cleared. | If the ''retain ownership'' flag is set to a non-zero value, the items' original ownership is retained; otherwise the ownership is cleared. This is especially notable in the case of retaining ownership on items owned by someone else when transferring them to the player, as this may be counted as stealing. | ||
If the ''suppress messages'' flag is set to 1, the standard "Item Added" pop-up will not be displayed when this command is used to transfer items to the player. | If the ''suppress messages'' flag is set to 1, the standard "Item Added" pop-up will not be displayed when this command is used to transfer items to the player. | ||
Line 23: | Line 23: | ||
*49: Note | *49: Note | ||
*50: ConstructibleObject | *50: ConstructibleObject | ||
*108: CHIP (casino chip) | |||
*115: CCRD (caravan card) | |||
*116: CMNY (faction currency) | |||
Note that not all items are in the obvious category. For example, Ingestibles and other Aid items are under ''AlchemyItem'' and include magazines, while skill books such as The Wasteland Survival Guide are under the ''Book'' category, despite appearing in the Aid category when viewed in the Pip-boy. | Note that not all items are in the obvious category. For example, Ingestibles and other Aid items are under ''AlchemyItem'' and include magazines, while skill books such as The Wasteland Survival Guide are under the ''Book'' category, despite appearing in the Aid category when viewed in the Pip-boy. | ||
The ''Ingredient'' and ''ConstructibleObject'' types are legacy content from Oblivion and generally will not be used, as the creation of new items of these types cannot be done within the GECK and requires the use of third-party tools. | The ''Ingredient'' and ''ConstructibleObject'' types are legacy content from Oblivion and generally will not be used, as the creation of new items of these types cannot be done within the GECK and requires the use of third-party tools. | ||
Some of the new item types added in Fallout: New Vegas are not associated with ''any'' of the Pip-boy item categories, and can only be seen in-game when viewing the list of all items in a container. | |||
==Syntax== | ==Syntax== | ||
Line 57: | Line 62: | ||
==Notes== | ==Notes== | ||
* Failing to specify a type code or specifying 0 for type code ''may'' result in the function removing all items from the specified actor's inventory, but may also result in the function doing nothing. | * Failing to specify a type code or specifying 0 for type code ''may'' result in the function removing all items from the specified actor's inventory, but may also result in the function doing nothing. | ||
* Unlike [[RemoveAllItems]], RemoveAllTypedItems supports the suppression of item received messages when it is used to transfer items from | * Unlike [[RemoveAllItems]], RemoveAllTypedItems supports the suppression of item received messages when it is used to transfer items from a container or NPC to the player. | ||
* For Base IDs in the exemption FormList, all items with that Base ID will be exempted. | |||
==See Also== | ==See Also== |
Revision as of 17:16, 12 March 2012
A function included in the GECK Version 1.1.0.262 for Fallout: New Vegas.
Description
Removes all typed items (except those listed in the exemption FormList) from the calling reference's inventory.
If a target container is specified, the typed items are moved to the target container with all equipment items retaining their current health; otherwise the items are destroyed as they would be via RemoveItem.
If the retain ownership flag is set to a non-zero value, the items' original ownership is retained; otherwise the ownership is cleared. This is especially notable in the case of retaining ownership on items owned by someone else when transferring them to the player, as this may be counted as stealing.
If the suppress messages flag is set to 1, the standard "Item Added" pop-up will not be displayed when this command is used to transfer items to the player.
List of type codes
Note: Type codes exist for all record types found in the GECK, including those which are not items that can be taken into inventory, e.g. Static Collections. The following list only includes type codes for record types which can be used as inventory.
- 24: Armor
- 25: Book
- 26: Clothing
- 29: Ingredient
- 31: Misc
- 40: Weapon
- 41: Ammo
- 46: Key
- 47: AlchemyItem
- 49: Note
- 50: ConstructibleObject
- 108: CHIP (casino chip)
- 115: CCRD (caravan card)
- 116: CMNY (faction currency)
Note that not all items are in the obvious category. For example, Ingestibles and other Aid items are under AlchemyItem and include magazines, while skill books such as The Wasteland Survival Guide are under the Book category, despite appearing in the Aid category when viewed in the Pip-boy.
The Ingredient and ConstructibleObject types are legacy content from Oblivion and generally will not be used, as the creation of new items of these types cannot be done within the GECK and requires the use of third-party tools.
Some of the new item types added in Fallout: New Vegas are not associated with any of the Pip-boy item categories, and can only be seen in-game when viewing the list of all items in a container.
Syntax
Syntax
container.RemoveAllTypedItems TargetContainerID:ref RetainOwnershipFlag:int Suppress Messages:int TypeCode:int FormListID:ref
Example
player.RemoveAllTypedItems vGOMPlayerEquipmentContainer 1 0 40 NVImprovedHoldoutWeapons
Notes
- Failing to specify a type code or specifying 0 for type code may result in the function removing all items from the specified actor's inventory, but may also result in the function doing nothing.
- Unlike RemoveAllItems, RemoveAllTypedItems supports the suppression of item received messages when it is used to transfer items from a container or NPC to the player.
- For Base IDs in the exemption FormList, all items with that Base ID will be exempted.