LagMonitor

Post here your questions about the Flash / Flex / Air API for SFS2X

Moderators: Lapo, Bax

Post Reply
Oleg_79
Posts: 161
Joined: 25 Feb 2011, 10:31
Location: Ukraine, Donetsk

LagMonitor

Post by Oleg_79 »

Please add to the documentation, the class LagMonitor.

Thanks in advance...
User avatar
Lapo
Site Admin
Posts: 23438
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: LagMonitor

Post by Lapo »

Hi,
there is no need for the documentation of that class, in fact you don't need to use it or instantiate it.
All you need to do is enabling the monitor, via SmartFox.enableLagMonitor(...) and subscribe to the SFSEvent.PING_PONG event.
That event will notify the average lag. Check the docs for all the details

Cheers
Lapo
--
gotoAndPlay()
...addicted to flash games
Oleg_79
Posts: 161
Joined: 25 Feb 2011, 10:31
Location: Ukraine, Donetsk

Re: LagMonitor

Post by Oleg_79 »

Thank you. Then comes another question.
What if the new added in the final version of SmartFoxServer2x? Because it was in previous versions SmartFoxServer2x.
ActionScript 3 API
[NEW] Added new LagMonitor object to check average round-trip (client-server-client) lag times.
User avatar
Lapo
Site Admin
Posts: 23438
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: LagMonitor

Post by Lapo »

It is now finalized and provides the ability to decide the frequency of the ping-pong request and the number of values stored to calculate the avarage time. Defaults are: interval -->4seconds, values-size --> 10

You find these info in the docs as well.

cheers
Lapo
--
gotoAndPlay()
...addicted to flash games
Post Reply