-2

I might be the only one who hates this new 1.13 update because Mojang messed with the commands waaay too much. Anyways, I want to set down a command block with a command I've written inside of it using the /setblock command. However, Mojang has either removed or completely changed how this worked like it did in 1.12. It used to worked like this: "/setblock command_block 0 replace {Command:"INSERT COMMAND HERE"}". However, this no longer works. How do you do this in 1.13. Thanks!

0

NBT now goes in the <block> argument directly after the block ID, like so:

setblock <x> <y> <z> command_block{Command:"say foo"}

If you want to add blockstates, you can also do so like:

setblock ~ ~ ~ command_block[facing=west]{Command:"say foo"}

I might be the only one who hates this new 1.13 update because Mojang messed with the commands waaay too much

Don't immediately react to new changes with hate before even learning them.

For example, this change means that the <block> argument is consistent across multiple commands. You can use the same syntax to specify NBT and blockstates in places like execute if block <block> and fill <x> <y> <z> <x> <y> <z> <block> replace <block>, whereas it was previously not possible to specify NBT there in 1.12.

  • Thank you this is exactly what I was looking for! :) – Aaron Kauffman Dec 29 '18 at 23:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.