29.01.2016, 06:22
You need to look at some REGISTER SYSTEMS TUTORIALS,
Here's how it works:
Player connects, if you have a file by player's name, you show the login dialog, else you show register dialog.
If a player logs in you load all the data from the file.
If a player registers you save a file with player's name.
Player disconnects, you save all players data into the file by name (ex: health, money and etc...) so you load them when he joins later.
Here's how it works:
Player connects, if you have a file by player's name, you show the login dialog, else you show register dialog.
If a player logs in you load all the data from the file.
If a player registers you save a file with player's name.
Player disconnects, you save all players data into the file by name (ex: health, money and etc...) so you load them when he joins later.