1

I am building a murder mystery type map, and I was wondering if there was a way to make a 25-second kill-cooldown. I am giving the murderer team strength 127. I need this to be where when one person (murderer) kills someone from the other team (innocent), their effect goes away, and after 25 seconds, comes back.

3
  • 1
    Possible duplicate of How to delay or slowly loop commands?
    – pppery
    Commented Oct 19, 2020 at 0:23
  • 3
    I don't think it's a duplicate, Cronut also needs to know how to reset the schedule after a kill.
    – Name_Hr3
    Commented Oct 19, 2020 at 1:20
  • 1
    Let me guess, is it an Among Us map?
    – John
    Commented Oct 19, 2020 at 17:00

1 Answer 1

1

How Can I Do This

Have a command block system check when someone dies. For more info check this answer. (It’s for the bedrock edition but should still work, instead of testfor use /execute if). Obviously change the selector form an @e zombie one to an @a. When someone dies you can then run a command that is to take away the strength. You can then use a comparator and repeaters to make a delay and then give the selected player strength again. A repeater set to 4 ticks gives a 0.4 delay, so use 62 4-tick repeaters and 1 2-tick repeater for 25 seconds.

Limitations

If someone leaves the kill cooldown will reset.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.