mIRC Home    About    Download    Register    News    Help

Print Thread
lag reply #116550 06/04/05 06:22 AM
Joined: Oct 2003
Posts: 80
R
RockHound Offline OP
Babel fish
OP Offline
Babel fish
R
Joined: Oct 2003
Posts: 80
Im trying to get a reply for lag but the return i get is not the lag.

Code:
.raw -q ping $server

on ^*:PONG:{
haltdef
echo -a  $1-
}


my question is how do i get the retun to show the correct lag?

Re: lag reply #116551 06/04/05 09:26 AM
Joined: Sep 2003
Posts: 4,230
D
DaveC Offline
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
Code:
alias serverlag {
  .raw -q ping $ticks
}
;
on ^*:PONG:{
  haltdef
  echo -a Serverlag is $calc(($ticks - $2) / 1000 / 2) seconds
}


send $ticks not $server
$2 well be gthe same $ticks value you sent
so i then take the current $ticks subtract the $2 ticks to get round trip time
divide by 2 (i think im ment to do this since its not round trip lag just server lag maybe im not ment to i dont know)
divide by 1000 to get ticks to seconds

Re: lag reply #116552 06/04/05 07:28 PM
Joined: Oct 2003
Posts: 80
R
RockHound Offline OP
Babel fish
OP Offline
Babel fish
R
Joined: Oct 2003
Posts: 80
Thanks for responding. I used you script and well the server lag is less then the lag to my isp. Not to sound rude or anything but is there an error in the script? lag to isp is 54ms lag tio server is 0.064 seconds.

Re: lag reply #116553 06/04/05 07:36 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline
Hoopy frood
Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
script is correct

Re: lag reply #116554 06/04/05 07:37 PM
Joined: Oct 2003
Posts: 80
R
RockHound Offline OP
Babel fish
OP Offline
Babel fish
R
Joined: Oct 2003
Posts: 80
ok thanks