[Solved] Lua timer script producing all-numeric value instead of proper time


It looks like you are saving the Unix Timestamp to your file, you can try and make it human readable using an online time converter (https://time.is/Unix_time_converter)

Besides this, take some time to read the os.time() implementation details on this lua page: https://www.lua.org/pil/22.1.html

The time function, when called without arguments, returns the current date and time, coded as a number. (In most systems, that number is the number of seconds since some epoch.)

If you want the time in between certain action, save the initial timestamp and diff it at the end of the action. This is natively supported in lua using os.difftime(). (http://www.lua.org/manual/5.3/manual.html#pdf-os.difftime)

1

solved Lua timer script producing all-numeric value instead of proper time