19.07.2016, 12:52
What is the point of PInfo[playerid][hours]?
Just use (gettime() - PInfo[playerid][ConnectTime]) to calculate how much time passed since the player has last connected.
Save that value each time into your player's db/ini file (incrementing your current totalplaytime). Then do whatever calculations you want to display the hours, minutes and seconds. There's no point saving them in variables once you have a timestamp..
Just use (gettime() - PInfo[playerid][ConnectTime]) to calculate how much time passed since the player has last connected.
Save that value each time into your player's db/ini file (incrementing your current totalplaytime). Then do whatever calculations you want to display the hours, minutes and seconds. There's no point saving them in variables once you have a timestamp..