SA-MP Forums Archive
Virtual worlds - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Virtual worlds (/showthread.php?tid=83587)



Virtual worlds - arnutisz - 26.06.2009

How to make virtual world for every player? I mean when player registers, he get virtual world 1, and when he logs in, his virtual world still be 1. And there should be only one player in same virtual world (when next player registers, his virtual world 2, next 3.....).

Sorry for my bad English


Re: Virtual worlds - abhinavdabral - 26.06.2009

you can tweak this idea later for registered user but basically if i was said to do that, i will use this line under OnPlayerConnect(playerid)
Код:
SetPlayerVirtualWorld(playerid,playerid);
This is so simple, now modify it according to your need....

I will be happy to know if my infromation was helpful

Thank You
-Abhinav


Re: Virtual worlds - arnutisz - 26.06.2009

Hmm, thanks for helping. How to get last registered player, and how to count registered players?
Counting registered players I need new variable, and when player registers set it to +1? I think so. But how to get last registered player?


Re: Virtual worlds - abhinavdabral - 26.06.2009

dude.. keep away the registration thingy...
The main thing is that, you need each player in his own personal world,
And the maximum limit for server is 200 players
So just simply give them the world according to their ID..
there are 255 Virtual world i guess.....and you wont get more than 200 players, also each player will automatically have a unique ID so you wont face any problems......You dont need to play with registration thing, just add that code and have fun.

Thank You
-Abhinav


Re: Virtual worlds - arnutisz - 26.06.2009

Oh, thanks for explaining more, because I didn't understand what you mean in previous post (i thought there was mistake ).


Re: Virtual worlds - abhinavdabral - 27.06.2009

Tell me if it will work for you...I hope it will


Thank You
-Abhinav


Re: Virtual worlds - arnutisz - 27.06.2009

Yea, it worked fine, thanks for you.