Disabling connection to different zones by the same user.

Post here your questions about Actionscript and Java server side extensions development.

Moderators: Lapo, Bax

Post Reply
yuvallahav
Posts: 247
Joined: 07 Oct 2008, 13:03
Location: Rome, Italy
Contact:

Disabling connection to different zones by the same user.

Post by yuvallahav »

I've just noticed for the first time after about a year of working with the smartfoxserver pro that users can log in to different zones using the same user name, something that was not possible on the basic server... can this be avoided???

Thanks.

Yuval Lahav.
Sarevok
Posts: 75
Joined: 12 Apr 2011, 22:12

Post by Sarevok »

How do you handle user log in? Do you check their username/password match the one in the database for example? If you do, then you can have different databases (with username/pass information) for each zone. That way zones will be totally independent.
BigFIsh
Posts: 1698
Joined: 25 Feb 2008, 19:26
Location: New Zealand

Post by BigFIsh »

Could it be due to both zones using the same database?
Smartfox's forum is my daily newspaper.
yuvallahav
Posts: 247
Joined: 07 Oct 2008, 13:03
Location: Rome, Italy
Contact:

Post by yuvallahav »

Well, all zone use the same users database (the site's database), but different score and history databases, but doesn't the login process to the smartfox does a check to see there is no one with the same user name connected to the server like it used to do in the basic server?
In the basic server which we used for all our games (again, each as a zone) before we switched to pro, a user would receive an error message on login when trying to login with a name already logged on to the server (not zone, but the whole server), while with the pro version, a user can connect and login to different zones on the server using the same name, it does not generate the error message the basic server does.
And Sarevok, I'm trying to do the exact opposite, I'm trying to prevent users logging into more then one game (zone) at a time with the same user name, it does not give us any technical problems, we just don't want users playing more then one game at a time with a specific user name.
User avatar
Lapo
Site Admin
Posts: 23438
Joined: 21 Mar 2005, 09:50
Location: Italy

Post by Lapo »

I've just noticed for the first time after about a year of working with the smartfoxserver pro that users can log in to different zones using the same user name, something that was not possible on the basic server... can this be avoided???
The Zone architecture is the same in SFS PRO and Basic in this regards.
Zones are separate applications running in the Server, so user Lapo can exist in both Zone A and Zone B.

There is no way to stop this from configuration, however you could set a simple flag on your DB to make sure that a certain User does not login in more than one Zone at the same time.
Lapo
--
gotoAndPlay()
...addicted to flash games
yuvallahav
Posts: 247
Joined: 07 Oct 2008, 13:03
Location: Rome, Italy
Contact:

Post by yuvallahav »

Yep, thought so... anyway, I'm working on some changes to the DB and our extensions like you have recommended yesterday to Riccardo, I hope this will do the trick.

Thanks again.

Yuval.
Post Reply