You set the variable %apricot to a string of text "12 $str($chr(160),7) %::idletime"
and then you want it to be a number??
You do not have to convert a string to a number for mIRC, but you have to make sure the string represents a number. A color code followed by a number followed by 7 strange characters (that are blank on some fonts) followed by the contents of some strangely named variable is NOT a number...
If %::idletime the the number of ms or something and that is a number, then use that:
if ( %::idletime == 0 ) {
msg Raffnixx %apricot gl
}
elseif ( %::idletime < 0 ) {
msg Raffnixx %apricot k
}
elseif ( %::idletime > 0 ) {
msg Raffnixx %apricot g
}
If there is a number somewhere in the text, and you want to check against that number, you need to extract it from that string, for example using $gettok.