Arqade Asked by grande1900 on February 12, 2021
I’m trying to get every achievement related to the Inventory Pets mod but I need to kill a player holding a specific item from that mod, Is there any way I could spawn a zombie holding this item? I’ve already tried
/summon zombie ~ ~1 ~ {HandItems:[{id:inventorypets:cobblestone_pet}
but that returns
Data tag parsing failed: Expected '}' but got ':' at: {HandItems:[{id:inventorypets:<--[HERE]
Is there any way I could make this work?
You need to put quotes around your string:
/summon zombie ~ ~1 ~ {HandItems:[{id:"inventorypets:cobblestone_pet"}]}
Since your value had a colon :
, which is a non-alphanumeric character and not an underscore (_
), it is not assumed to be a string. To make the entire thing a string, quotes must be added. Otherwise, Minecraft stops reading the string at the second colon, being invalid because it expects a comma ,
to start the next key-value pair.
It thinks the colon is something entirely different, so you have to tell it that that is part of your string by adding the quote marks.
Answered by Penguin on February 12, 2021
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP