Question on time

Hello Developers! I’m trying to make the training start when is like 3:00 PM EST, but I don’t know how to link the real time with roblox.

  1. What do you want to achieve? Keep it simple and clear!
    I want to do the training start when is like 3:00 PM est, like if is 3:00 PM EST the training starts.

  2. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I tried searching on youtube, but I didn’t found anything useful, I would like some help.

I’m trying to do the training start a 3:00 PM EST, for example when is 3:00 PM EST a GUI will be visible, is just an example, the problem I’m having is I don’t know how to link the real-time with roblox.

I hope you can help me.

Kindest regards,
Waum_a.

1 Like

I believe os.time() is your best bet to accomplish this.

You can read more about it here

Hope this solves your problem! :smile:

1 Like

I’m testing the example script of roblox and I dont understand this output: image

2. print(os.time({
3. year=2020, month=4, day=15, -- Date components
4. hour=16, min=28, sec=0 -- Time components
5. })) --> 1586968080```

If that seems too complex you can also try os.date() to simplify your work.

as for os.time(), it would require more than just printing as it is more complex coding.

Also, I didn’t understand what is “timestamp”.

That is because you don’t access it that way. Its a dictionary.
Heres my function for getting an array of the time. Bot LocalTime and UTC:
(It will return a table with the values in, its easy to use)

3 Likes