I am trying to make a automatic shop in my world and I used these commands /clear and /give but the command /clear doesn't work . I wrote /clear @p iron_nugget 20 in a command block i press the button and it doesn't remove anything
I am trying to make a automatic shop in my world and I used these commands /clear and /give but the command /clear doesn't work . I wrote /clear @p iron_nugget 20 in a command block i press the button and it doesn't remove anything
The syntax for the
clear
command is:The third parameter of the
clear
command isdata
, used to specify a type of item for items with multiple variations (e.g. wooden planks, colored wool, etc.) So,data
must be omitted when clearingiron_nugget
because only one type of iron nugget exists. Therefore, in order for the command to work, you must use a0
before themaxCount
parameter: