Can someone please make a script which will test the lag between any user and the hub.
When one user type +lag or +ping it will get a message with his lag time like "You have a 0.5 sec. lag".
Already exists a nice script by Mutor - LagCheck 1.0 LUA 5.0/5.1
Quote
LagCheck 1.0 LUA 5.0/5.1
By Mutor 01/31/07
Sends a request to user and times the response time
-Check yourself or another hub user
-Provides context menu
see thread http://board.ptokax.ath.cx/index.php?topic=6818.0 (http://board.ptokax.ath.cx/index.php?topic=6818.0)
Hope this is what u need........
rEALx
i want something more simple ...
That one can't be used by anyone .
I don't have such thing as :unregistered users on my hub :P. Everyone have access to it.
And that script test the lag between 2 users ..i think ..
I want that this script to test the lag between the user which type the command (+lag) and the hub.
Thank you .
Try this 1
SetTimer(1000)
lagcmd = "+lag"
function Main()
counter = 10
end
function ChatArrival(curUser, data)
data = string.sub(data, 1, string.len(data)-1)
local s,e,cmd,args = string.find(data, "%b<>%s+(%S+)%s*(.*)")
if cmd == lagcmd then
if counter == 10 then
counter = 0
name = ""
DoLagTest(curUser)
else
SendToNick(curUser.sName, "<?LagTest?> Test busy, please try again in a few seconds.")
end
else
return 0
end
return 1
end
function DoLagTest(curUser)
SendToAll("<?LagTest?> Test started")
name = curUser.sName
StartTimer()
end
function OnTimer()
if counter == 10 then
StopTimer()
SendToAll("<?LagTest?> Test finished")
else
counter = counter + 1
SendToAll("<?LagTest?> "..counter)
end
end
I think with this script i can realize only if i have lag ...but i can't find it's value .
When i type +lag ..all i get is:
<?LagTest?> Test started
<?LagTest?> 1
<?LagTest?> 2
<?LagTest?> 3
<?LagTest?> 4
<?LagTest?> 5
....................
<?LagTest?> 10
<?LagTest?> Test finished
If your client shows timestamps, you should have exactly 1 message per 1 second.
If the time between messages fluctuates, there's lag
That mean i can't find the exactly value of the lag ?
Can you please make one script to do that ?
Tx again .