Skip to main content

Execute_DestroyInventoryChild

Description

Removes and destroys all child objects in the inventory that satisfy the specified condition. The condition is evaluated with Self as the inventory owner and Target as each child object.

Parameters

ParameterDescription
BaseObjectThe inventory or an object/character that owns an inventory
S1Condition Id used to filter which child objects to remove and destroy

Examples

DescriptionBaseObjectCommand
Remove all spoiled objects from a refrigeratorTargetDestroyInventoryChild
Remove all expired items from Self's inventorySelfDestroyInventoryChild
Remove all objects matching a custom condition from inventoryTargetDestroyInventoryChild