Any ideas how to add timer ? - 23/05/21 08:18 AM
Hi any suggestions how to add timer ?
So i want to add 60 sec. timer to guess the number for person ($target) who has to guess or he will get timeout.
Thanks for any help.
Code
ON $*:TEXT:/^!number\s/:#:{ if ((%floodEVERYONE) || ($($+(%,floodEVERYONE.,$nick),2))) { return } set -u60 %floodEVERYONE On IF ($regex($3,^+$)) { var -g %target $remove($2, @) inc %scriptcount | set %number [ $+ [ $chan ] ] $rand(1,10) msg $chan %target , You Have Been Chosen By $nick To Guess A Random Number Between: 1 And 10, To Guess What It Is Type: !guess <number> (You have 60 s. ). } ELSE MSG $chan $nick $+ , Use: !number [username] to challenge a user to guess a number from 1-10 }
So i want to add 60 sec. timer to guess the number for person ($target) who has to guess or he will get timeout.
Thanks for any help.