[HELP] Get total days...
#1

Hello everybody!

I need to convert the gettime() in days, example:

Using gettime():
LastLogin[playerid] = 1464549743;
ActualLogin[playerid] = 1464549657;

How to get the total days since the last login?
Thanks!
Reply
#2

You simply divide the difference by 1 day in seconds

days = (ActualLogin[playerid] - LastLogin[playerid]) / (60 * 60 * 24);
Reply
#3

Quote:
Originally Posted by Nero_3D
Посмотреть сообщение
You simply divide the difference by 1 day in seconds

days = (ActualLogin[playerid] - LastLogin[playerid]) / (60 * 60 * 24);
OMG - So simple!
Thank you.. Rep+.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)