2

I've been trying to make a bomb using commands.

When the player uses the spawn egg I want it to summon like 10-20 invisible armor stands, then use /spreadplayers to spread them above ground and underground at a 10 block radius from the player. Afterwards, TNT is summoned at the armor stands and that makes the explosion. After that the armor stands are killed.

The problem is, I don't know if the /spreadplayers command even works with armor stands.

4

Yes, it turns out that you can use /spreadplayers with entities. This:

/spreadplayers 30 30 10 30 false @e[type=!Player]

Will spread any non-player entities. Using @e[type=ArmorStand] in that command instead will limit it to just your armour stands.

0
/spreadplayers ~1 ~1 10 30 false @e[type=ArmorStand]
0

/spreadplayers ~1 ~1 10 11 @e[type=Armor_Stand] This answer updated for user112256 but now in 1.12.x, ArmorStand is now armor_stand.

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.