-6

Im the admin on a server and want to make a command block that turns it to day, but also have it that if anyone else right clicks on it, it kills them?

1
  • Are the other players also admins?
    – BunnyMerz
    Sep 27, 2019 at 18:20

2 Answers 2

1

Add a repeat command set to always active with the command:

execute as @p[distance=0..8,name=!Tyler Hawkins] at @s run kill @s

And change "Tyler Hawkins" to your in game nickname

This will kill anyone that gets close to that command block, except you.

-1

Hide the day night command block somewhere, then make a different command block that has the command /kill @p

2
  • It does work in Java edition. Sep 27, 2019 at 21:05
  • If you do /kill @p, you will kill the closest player, regardless of distance. That means it will kill everyone, one by one.
    – BunnyMerz
    Sep 27, 2019 at 22:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .