4
Question
is there a command for java that makes you die when you are in front of a armor stand and is there a way to do that and make the armor stand move as i have wanted to do this for years
9
Late reaction, but oh well... this is most definitely possible. You see, armor stands are basically entities. Block entities, sure, but entities nonetheless. Meaning that you can make them /execute commands. As well as teleport them to another location.
Let's start with the basics...
/summon minecraft:armor_stand ~ ~ ~ {Tags:["stand"],CustomName:'"D00mStand"',CustomNameVisible:1}
Don't mind the extra theatrics, I just enjoy that. However... the tag is important because this will make it easier to run our commands. The trick here is to set up a check to see if something is in front, aka facing, this armor stand.
/execute at @e[tag=stand] anchored eyes positioned ^ ^ ^2 if entity @a[distance=..2]
So, we run the command at the armor stand. We anchored the eyes, and then check for something positioned 2 blocks in front of it (the ^ ^ ^2?). But only if any player is within 2 blocks distance. So this will only happen when any kind player is within 2 blocks of the stand, in front of it. Next stop: adding a "run" part which gives it something to 'do'. Like... killing the player ;)
/execute at @e[tag=stand] anchored eyes positioned ^ ^ ^2 if entity @a[distance=..2] run kill @@s
Don't include the extra 'at': I had to use that to prevent the forum from expanding names. You only need one, followed by 's'. This will kill any player that's 2 blocks in front of the armor stand.
As for making the armor stand move... it's an entity, just /tp it! For example something like this?
/tp @e[tag=stand] ^ ^2 ^5 facing ~ ~ ~
This would teleport the stand 5 blocks in front of you, 2 blocks above you (safer if you're looking at the ground) and to make matters worse... it'll even be facing in your direction ;)
Or use an execute command for more control....
/execute as @e[tag=stand] at @e[tag=stand] run tp @s ^ ^1 ^2
^ That would make the armor stand "hop" 2 blocks ahead. Yikes... now imagine that you set up that kill command using a repeating command block... you'd have a "walking" killer armor stand on your hands! 😬
Hope this can help!
Let's start with the basics...
/summon minecraft:armor_stand ~ ~ ~ {Tags:["stand"],CustomName:'"D00mStand"',CustomNameVisible:1}
Don't mind the extra theatrics, I just enjoy that. However... the tag is important because this will make it easier to run our commands. The trick here is to set up a check to see if something is in front, aka facing, this armor stand.
/execute at @e[tag=stand] anchored eyes positioned ^ ^ ^2 if entity @a[distance=..2]
So, we run the command at the armor stand. We anchored the eyes, and then check for something positioned 2 blocks in front of it (the ^ ^ ^2?). But only if any player is within 2 blocks distance. So this will only happen when any kind player is within 2 blocks of the stand, in front of it. Next stop: adding a "run" part which gives it something to 'do'. Like... killing the player ;)
/execute at @e[tag=stand] anchored eyes positioned ^ ^ ^2 if entity @a[distance=..2] run kill @@s
Don't include the extra 'at': I had to use that to prevent the forum from expanding names. You only need one, followed by 's'. This will kill any player that's 2 blocks in front of the armor stand.
As for making the armor stand move... it's an entity, just /tp it! For example something like this?
/tp @e[tag=stand] ^ ^2 ^5 facing ~ ~ ~
This would teleport the stand 5 blocks in front of you, 2 blocks above you (safer if you're looking at the ground) and to make matters worse... it'll even be facing in your direction ;)
Or use an execute command for more control....
/execute as @e[tag=stand] at @e[tag=stand] run tp @s ^ ^1 ^2
^ That would make the armor stand "hop" 2 blocks ahead. Yikes... now imagine that you set up that kill command using a repeating command block... you'd have a "walking" killer armor stand on your hands! 😬
Hope this can help!
thanks so much
i found out how to do it i just make a command block that will kill you if you are over red wool then i just put the wool around the armor stand then done
you can use like an execute command or just make the entity cram limit 1
that's not insta kill
First one:
you could use in a repeating command:
/execute if entity @p[x=9,y=9,z=9] run kill @p
replace the coordinates with the armor stand's position and one block in front of it
you could use in a repeating command:
/execute if entity @p[x=9,y=9,z=9] run kill @p
replace the coordinates with the armor stand's position and one block in front of it
that doesn't work
oh.
sorry
idk then
sorry
idk then
I think about thorns, but it requires hits
Did you think about execute command or hidden witherskeleton?
Did you think about execute command or hidden witherskeleton?
