How do I change the lighting settings in game when it gets to a certain time of day?
if game.Lighting.TimeOfDay >= 20:00:00 then
local light = -- wherever your point light or whatever it is
--change light here
I wouldn’t recommend using
It’s better to use >= in case there’s a bit of lag and the if statement checks at 19:59:59 and its next check is at 20:00:01 then the light won’t change.
Are you wanting to change the Lighting Properties? The term “settings” can mean different things.
Here’s a post a couple of weeks ago that I saw:
you can have your code check the time value, and when it gets to a certain time, you adjust the other settings in your lighting service.