4

Question

proventhesheep 8/27/24 7:45 am history
325
9/1/2024 2:22 pm
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
Posted by
proventhesheep
Level 31 : Artisan Mountaineer
36

  Have something to say?

JoinSign in

9

ShelLuser
09/01/2024 2:13 pm
Level 61 : High Grandmaster System
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!
3
proventhesheep
09/01/2024 2:22 pm
Level 31 : Artisan Mountaineer
thanks so much
3
proventhesheep
08/27/2024 12:39 pm
Level 31 : Artisan Mountaineer
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
2
TheMinecraftMan31415
08/27/2024 8:47 am
Level 39 : Artisan Modder
you can use like an execute command or just make the entity cram limit 1
4
sniffercraft34
08/27/2024 10:00 am
He/Him • Level 78 : Legendary Mythical Sniffer
that's not insta kill
2
sniffercraft34
08/27/2024 8:31 am
He/Him • Level 78 : Legendary Mythical Sniffer
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
2
proventhesheep
08/27/2024 8:52 am
Level 31 : Artisan Mountaineer
that doesn't work
3
sniffercraft34
08/27/2024 9:59 am
He/Him • Level 78 : Legendary Mythical Sniffer
oh.
sorry
idk then
2
Papa Enny
08/27/2024 7:56 am
Level 62 : High Grandmaster Answer Dwarf
I think about thorns, but it requires hits
Did you think about execute command or hidden witherskeleton?
2

Welcome