Help with a vanilla command, please?

  • Please make sure you are posting in the correct place. Server ads go here and modpack bugs go here

Flexico

Well-Known Member
Dec 15, 2012
328
39
53
Could someone please tell me why this doesn't work?
Code:
/summon minecraft:item ~ ~1 ~ {item:{id:"minecraft:diamond",tag:{display:{name:"\"Artificial Diamond\""}}}}
 

lenscas

Over-Achiever
Jul 31, 2013
2,015
1,799
248
what does the error say?
my guess is that the {} stuff is json and thus the keys (item, id, tag, name) should be in quotes. Also, "\"Artificial Diamond\"" looks wrong and probably should just by "Artificial Diamond" unless you want the name to be

"Artificial Diamond"

instead of

Artificial Diamond
 

Flexico

Well-Known Member
Dec 15, 2012
328
39
53
Ok, I tried:
Code:
/summon minecraft:item ~ ~1 ~ {"Item":{"id":"minecraft:diamond","tag":{"Display":{"Name":"Artificial Diamond"}}}}
and it still just gave me "Unable to summon entity."

I tried playing with word capitalization too; no go.
 
Last edited:

lenscas

Over-Achiever
Jul 31, 2013
2,015
1,799
248
actually.... can you even summon an item? I'm not sure you can.

Why not use /give instead?
 

Flexico

Well-Known Member
Dec 15, 2012
328
39
53
Well, this is just part of a command that will be part of a command block contraption. I had it working in 1.12, but have to change the syntax for 1.13. /summon worked before.

In case you're curious, it allows you to compress a coal block into a diamond by surrounding it with TNT and blowing it up. This is the command that summons the diamond right after the explosion.