Pages: [1]
|
 |
|
Author
|
Topic: Spiritping (Read 2114 times)
|
Da-Huntha
Janitor
Administrator
Rank 2/4
Offline
Posts: 218
Moo Moo Machine
|
So, i was bored and made this script... Its an advanced ping script with the packet idea. you can sent an ammount of packages to a user and let the script Calculate the average ping time of this users (in seconds, later il make it in Mili Seconds) I surely will improve it later when i feel like doing so Here's the script: ©Lostmoment 2004, http://chat.lostmoment.com removing this copyright notice is against the Terms Of Agreement.
SpiritPING V1.1
menu nicklist { - SpiritPING Advanced Ping Script .Ping:/pingscript $1 .Send 3 packets (1 pack per 10 secs):/.notice $1 SpiritPING -> Sending 3 packets with 1 pack per 10 seconds to you to calculate your average ping. | /set %pinger.packet 0 | /set %pinger.packetsent 0 | /echo $active $timestamp 4PACKET -> Sending 3 packets (10sec/pack) to $1 | /pingscript $1 | /.timer 2 10 /pingscript $1 | /.timer 1 25 /pingsum $1 .Send own given amount of packets:/set %pinger.amount $?="How much packets to send?" | /set %pinger.interval $?="At what interval of seconds you want to send the packets? $crlf $+ NOTE: An amount lower than 10 can cause an PACKET loss $crlf $+ An high amount will give the user more time to reply and will accurate the results more" | /.notice $1 PingScript -> Sending %pinger.amount packets with 1 pack per %pinger.interval seconds to you to calculate your average ping. | /set %pinger.packet 0 | /set %pinger.packetsent 0 | /echo $active $timestamp 4PACKET -> Sending %pinger.amount packets ( $+ %pinger.interval $+ /pack) to $1 | /pingscript $1 | /.timer $calc(%pinger.amount - 1) %pinger.interval /pingscript $1 | /.timer 1 $calc(((%pinger.amount - 1) * %pinger.interval) + 5) /pingsum $1 - }
alias pingscript { /inc %pinger.packetsent 1 /echo $active $timestamp 4PING -> sent to $1 /set %pinger.time $ctime /.ctcp $1 PING }
on *:ctcpreply:PING*:{ /inc %pinger.packet 1 /set %pinger.pingtime $ctime /echo $active $timestamp 4PONG -> $nick PING time: $calc(%pinger.pingtime - %pinger.time) Seconds 4PACKET: %pinger.packet /inc %pinger.sumsec $calc(%pinger.pingtime - %pinger.time) }
alias pingsum { /set %pinger.totsec $calc(%pinger.sumsec / %pinger.packet) /echo $active $timestamp 4AVR -> $1 AVERAGE PING time: %pinger.totsec Seconds with %pinger.packetsent PACKETS sent and %pinger.packet PACKETS received (loss of $calc(%pinger.packetsent - %pinger.packet) PACKETS) /set %pinger.packet 0 /set %pinger.packetsent 0 /set %pinger.sumsec 0 }
|
|
|
|
« Last Edit: December 18, 2004, 09:33:48 pm by Da-Huntha »
|
Logged
|
This signature is tasty.
|
|
|
Catclone
I like turtles
Administrator
Rank 2/4
Offline
Posts: 173
|
 |
Spiritping
« Reply #1 on: January 28, 2005, 10:03:58 pm » |
|
The comment should have ; infront of them to avoid getting read O_o And how can a ping script be advanced? ¬_¬ XD
|
|
|
|
|
Logged
|
|
|
|
Da-Huntha
Janitor
Administrator
Rank 2/4
Offline
Posts: 218
Moo Moo Machine
|
 |
Spiritping
« Reply #2 on: January 29, 2005, 12:20:28 am » |
|
The script can send serveral PINGs and calculate the average time of it, also it will always return a time if the user spoofed their ping message, by replacing them.
Thus you can call it more advanced than the normal ping function
|
|
|
|
|
Logged
|
This signature is tasty.
|
|
|
Catclone
I like turtles
Administrator
Rank 2/4
Offline
Posts: 173
|
Wee for uselessity 
|
|
|
|
|
Logged
|
|
|
|
|
Pages: [1]
|
|
|
 |