• Advertisement
Sign in to follow this  

Lua timing

This topic is 1864 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

In lua how can I get the time between two points
so if I press the enter key
and then press the enter key again a bit later
it would tell me the time passed in between the two points

How can I do that?

Share this post


Link to post
Share on other sites
Advertisement
You can use the function os.time() to get the time since epoch, or os.date() to get current the date and time, or os.clock() to get the time since program start. Barring those, you could bind to an external time tracking library.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement