• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

os.time()

milbradt

New Member
Joined
Dec 25, 2011
Messages
177
Solutions
1
Reaction score
4
Hello!

I do not know how the os.time ()
How to know the right time to add the desired time?

Ex:
local 2Hours = 2 * 60 * 1000
local 15Minutes = 15 * 1000


doCreatureSetStorage(cid, storage, (os.time() + 2Hours))

doCreatureSetStorage(cid, storage, (os.time() + 15Minutes))


Am I doing right?
 
os.time() is in seconds.
2 hours = 60 x 60 = 3600 = 1 hour x 2 = 7200
15 minutes = 15 x 60 = 900
So 7200 for 2 hours and 900 for 15 minutes.
Or with calculation: 2 * 60 * 60 and 15 * 60
 
Back
Top