[Tutorial] Recorded over time TempTime
#1

Hi, I'm new here and I bring you my new Tutorial
Uploaded by Time Timer is a simple but gets wasted ... It's beautifully without them ...
Declare variables:
Code:
new TempTime[MAX_PLAYERS char];

public OnPlayerConnect( playerid )
{
TempTime{ playerid } = gettime(); //Set the current value of the variable unix tajm
return 1;
}
Code:
public OnPlayerDisconnect( playerid ,reason)
{
new TimeToTemp = gettime() - TempTime{ playerid } ;// Variable Time Temp will now contain the number of seconds that the player was online
/ / Variable we add to the player's timestamp file (DUdb, Dini, DOF2)
return 1;
}
Thank you to all the lovely evening: D
Reply


Messages In This Thread
Recorded over time TempTime - by EmpireSk - 30.07.2013, 20:34
Re: Recorded over time TempTime - by Macluawn - 30.07.2013, 20:50
Re: Recorded over time TempTime - by EmpireSk - 30.07.2013, 20:56
Re: Recorded over time TempTime - by Pottus - 30.07.2013, 21:00
Re: Recorded over time TempTime - by Macluawn - 30.07.2013, 21:01
Re: Recorded over time TempTime - by Vince - 30.07.2013, 21:30
Re: Recorded over time TempTime - by EmpireSk - 31.07.2013, 08:46

Forum Jump:


Users browsing this thread: 1 Guest(s)