;Andy's Client Type Signon Pager ;Note: this is an upgraded ICameFrom plus visitor counter ON SIGNON { ICameFrom GLOBAL Instpal GLOBAL MOUSEPOS + 0 == Instpal = Mac GLOBAL PC GLOBAL { 1 Mac = } { 1 PC = } DATETIME 0 < IFELSE { { " PC" ctype = } CLIENTTYPE "WINDOWS32" == IF { " Mac" ctype = } CLIENTTYPE "MACPPC" == IF { " TPV" ctype = } CLIENTTYPE "TPV" == IF } { { "n InstantPalace" ctype = } { { " PC (old version)" ctype = } 1 PC == IF { " Mac (old version)" ctype = } 1 Mac == IF } Instpal IFELSE } IPTVERSION IFELSE ME GETSPOTSTATE 1 + ME SETSPOTSTATE ME GETSPOTSTATE ITOA counter = { { "nowhere" ICameFrom = } ICameFrom VARTYPE SWAP POP 4 <> IF CLIENTTYPE } { { "nowhere" ICameFrom = } 0 ICameFrom == IF } IPTVERSION IFELSE "`page I'm a" { { "n unregistered" & } ISGUEST IF } Instpal NOT IF ctype & " user from " & ICameFrom & ", #" & counter & "." & SAY SERVERNAME ICameFrom = } ON OUTCHAT { ;say "restore N" to set counter to N { "$1" GREPSUB ATOI num = { "Number exceeds the limit." LOCALMSG "" CHATSTR = EXIT } num 32767 > IF { "Restored to number " ME GETSPOTSTATE ITOA & LOCALMSG } 60 ALARMEXEC num ME SETSPOTSTATE "" CHATSTR = } CHATSTR "^restore (.*)$" GREPSTR ISWIZARD AND IF }