mIRC Home    About    Download    Register    News    Help

Print Thread
#185769 13/09/07 06:15 PM
Joined: Aug 2007
Posts: 10
Z
Pikka bird
OP Offline
Pikka bird
Z
Joined: Aug 2007
Posts: 10
I'm trying to fix an issue with drones on my network
im trying to figure out how to do a /ctcp <nick> time and enter the results into a variable.

Joined: Sep 2007
Posts: 10
Z
Pikka bird
Offline
Pikka bird
Z
Joined: Sep 2007
Posts: 10
That's just an ON CTCPREPLY event. Something like:

Code:
on *:CTCPREPLY:TIME*: {
  set %ctcptime $1-
}


Where %ctcptime would be what the client replied.

Just use /help ON CTCPREPLY for more info.
I hope that helps.

----

I just tested it and it works, although the reply (%ctcptime) is set to: TIME Thu Sep 13 14:56:12 2007
So I guess if you were picky you could use:

Code:
on *:CTCPREPLY:TIME*: {
  set %ctcptime $gettok($1-,2-,32)
}


Which would return Thu Sep 13 14:59:21 2007

Last edited by zaqwsxcde; 13/09/07 07:01 PM.
Joined: Jun 2006
Posts: 508
D
Fjord artisan
Offline
Fjord artisan
D
Joined: Jun 2006
Posts: 508
I would tend to store it as a ctime value...
Code:
on *:ctcpreply:TIME *:{
  set -e %ctcptime. $+ $nick $ctime($2-)
}



Link Copied to Clipboard