Page 1 of 1

How to assign players location

Posted: Mon Jan 13, 2014 6:09 am
by KaL
I was looking into the game default location but i was unable to assign players location. I want to assign player location from the start that they signup for the game. So this way i will have multiple location, which represent countries, that will distribute the population evenly. Can you tell me where to go or how to?

Re: How to assign players location

Posted: Mon Jan 13, 2014 7:40 am
by a_bertrand
The player location is stored using a user variable. Also there is a config "defaultLocation" which can be accessed via admin panel and can define the default location players start with. If you want to have different locations for each players then you will need to create a new module for that and use for example the function SetPlayerLocation defined in modules/locations/lib.php

Re: How to assign players location

Posted: Mon Jan 13, 2014 1:14 pm
by KyleMassacre
I would create a new module and use during register and after register I believe the after register will override what's the default locationbut I could be wrongand in the during register you can add a select box for a smart selection where user can choose where they want to be