2
How do I kill a mob that is at another mob
How do I kill a mob that is at another mob? I'm making a blackhole with only commands, the version is 1.21. I'd Really like if you do not prank me like "/kill @e" on Repeat!
Create an account or sign in to comment.
4
/execute at [BLACKHOLE] as @e[type=!minecraft:player,distance=..3] run kill @s
replace [BLACKHOLE] with the mob you want to execute it at, with @e[type=!minecraft:player,distance=..3] this checks for any mob expect for the player within 3 blocks of the blackhole then it kills it.
replace [BLACKHOLE] with the mob you want to execute it at, with @e[type=!minecraft:player,distance=..3] this checks for any mob expect for the player within 3 blocks of the blackhole then it kills it.
The problem was that the run kill @s kills the blackhole! Instead it needs to be /execute at [BLACKHOLE] as @e[type=!minecraft:player,distance=..3] run kill @n[type=!minecraft:armor_stand,distance=..3]
Sorry that did not work, but thank you for trying! I'll experiment with that!
I'll try that out!