on *:JOIN:#test:{ if ($read($ctfile,ntw,$nick *)) { var %rn $readn, %count $gettok($read($ctfile,nt,%rn),2,32) write $+(-l,%rn) $ctfile $nick $calc(%count + 1) } else { write -i $ctfile $nick 1 } } alias -l ctfile { return channeltracker.txt }