How to remove a user if they close the browser suddenly

Need help with SmartFoxServer? You didn't find an answer in our documentation? Please, post your questions here!

Moderators: Lapo, Bax

Post Reply
sankarganesh86
Posts: 108
Joined: 06 Jan 2010, 09:50
Location: chennai
Contact:

How to remove a user if they close the browser suddenly

Post by sankarganesh86 »

hi,
if both the user playing a game using SFS
if a user suddenly close the browser, it take minimum 25 seconds to reflect
to other end user , if we use (AS3 API)
SFSEvent.onUserLeaveRoom event

i changed the <MaxSocketIdleTime>1</MaxSocketIdleTime>
maximum socket idle time to 1 in config.xml but still i facing this issue.
BigFIsh
Posts: 1698
Joined: 25 Feb 2008, 19:26
Location: New Zealand

Post by BigFIsh »

See http://forums.smartfoxserver.com/viewto ... 3520#33520

MaxSocketIdleTime can't be used this way. It is for login phase, where a socket connection is established but the user not yet logged in.

Other than DeadChannelsPolicy being set to 'strict', I don't think there is much you can do about this because it is dependent on the client.
Smartfox's forum is my daily newspaper.
sankarganesh86
Posts: 108
Joined: 06 Jan 2010, 09:50
Location: chennai
Contact:

Post by sankarganesh86 »

hi big fish ,
Please tell some ideas about
dead channel policy
how to implement that in SFS or Client side ....

please give some reference link for that ...
BigFIsh
Posts: 1698
Joined: 25 Feb 2008, 19:26
Location: New Zealand

Post by BigFIsh »

It's defined in your config.xml file. See http://www.smartfoxserver.com/docs/docP ... htm#server for more info.

It's probably already set to 'strict'. There's not much you can do about this behaviour, because it's client dependent.
Smartfox's forum is my daily newspaper.
Post Reply