Jump to content

Offline time


Mr.Aleks

Recommended Posts

Posted

How can I do to get the time that a player has been offline.

Imagine you played 3days ago, so the function should return the time you have been offline, in this case, 3 days.

Is there any function?

Posted

There isn't.

You must store current timestamp from like getRealTime().timestamp and compare it later after he joins.

That'd be time in seconds.

Posted

You can try to make a MYSQL-Table that saves the lastlogin of a player and then make a script that substracts the actual date with the last login of the player. Or just find on community a script like what are you looking for.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...