actions:action_types:modify_item
This is an old revision of the document!
Table of Contents
minecraft:modify_item
The minecraft:modify_item
action type modifies an item stack.
The action is unsuccessful if no item stack is supplied to the action context, or if the supplied item stack is empty.
In all other cases it's successful, regardless of the changes made to the item stack.
Fields
Name | Description | Type | Default Value |
---|---|---|---|
item_modifier | The item modifier to apply. Note that it uses the action loot context type. | An item modifier | |
context | The context to use for applying the item modifier. | An action context parameter set |
Example
{ "type": "minecraft:modify_item", "item_modifier": { "function": "minecraft:set_count", "count": 1 }, "context": { "entity": "this", "position": "this" } }
actions/action_types/modify_item.1714503430.txt.gz · Last modified: 2024/04/30 18:57 by errorcraft