Hi, i'm trying to create a timer that turn on when you do or receive damage, count from 20 to 0 seconds and then turn off. If you do or receive other damage during that 20 seconds period the timer restarts. The purpose of this is to let you enter in some sort of "fight mode" in which you cannot tp, open menus etc. If 20 seconds pass without damage events you exit the fight mode.
i tried by adding a "loop 20 times" thing but didn't work as expected.
code_language.skript:
on damage:
victim is a player:
send "&c You are in a fight" to victim
i tried by adding a "loop 20 times" thing but didn't work as expected.
Last edited: