Keep Inventory

Power Type

Makes certain items persist in the entity's inventory.

Type ID: origins:keep_inventory

Fields

Field Type Default Description
item_condition Item Condition Type optional If specified, only make the items that fulfill the specified item condition type persist in the entity's inventory.
slots Array of Integers optional If specified, only make the items that are in the listed inventory slots persist in the entity's inventory. See Positioned Item Stack Slots for possible values.

Examples

{
    "type": "origins:keep_inventory",
    "slots": [
        0,
        1,
        2,
        3,
        4,
        5,
        6,
        7,
        8
    ]
}

This example will make items in the hotbar slots persist.