If you want it to work with your own input, you can use the ON INPUT event handler to look for you typing 'ciao', as you can find in the F1 help or at
https://en.wikichip.org/wiki/mircOr is much simpler for you to create a custom alias named 'ciao', and then you can invoke it by typing /ciao in channel. Something like:
alias ciao {
msg $chan $chr(22) ciao! $chr(22)
}
Or for this case, instead of looking at everything you type to see if it is '!countdown', you can create an alias like this that reacts to /countdown 5, and is my attempt to modify the existing script as little as possible
alias countdown {
if ($window($active).type !isin channel query) { echo -ag must be typed in a channel or query window! | return }
if ($1 isnum 1-5) {
var %x 1
var %y $int($1)
while (%x <= $int($1)) {
.timer 1 %y msg $unsafe( $active %x )
if (%x == $int($1)) { .timer 1 $calc(%x + 1) $unsafe( msg $active GO!!!! ) }
inc %x
dec %y
}
}
else { echo -ag error must use 1-5 like: /countdown 4 }
}
Reminder that the above doesn't work in the 6.35 you were first using because of how timers are handled there, as I described in the earlier post. Also, the above alias uses the newer $unsafe identifier that defends against strings created by not-you, which in this case is a channel name containing ,$word or ,%word which is extremely unlikely but can be a big problem if it does happen.
Assuming it's not needed, you can either remove the $unsafe( ) wrapper or you can add an alias that is ignored by newer mIRC that already has this built-in, but in 6.35 it would give most of the functionality of the $unsafe identifier:
alias unsafe { return $!decode( $encode($1,m) ,m) }
But is a good habit to be in where you use $unsafe for strings that you did not create, as described in the above wikichip link for 'msl injection'