How can I place a block randomly around my world?
I downloaded a lucky block mod and I want to place them randomly in my world. Is there a command to do this? I'd prefer the entire world to be affected but if it's just around 200 blocks then that's fine.
Solution 1:
There isn't one command but you could do it with a few:
- Summon large amounts of entities. Armour stands are probably the best as they can't move.
- Use the
spreadplayers
command to distribute them around the world. - Use the
execute
command tosetblock
your lucky block at each armour stands' position. - Use the
kill
command to remove all the armour stands.
Links on each commands' syntax are below.
Spreadplayers
Execute
Setblock
Kill