of     1   

HabaneroDude
#182934541Wednesday, February 03, 2016 4:13 PM GMT

Trying to make a script that makes all dynamic lighting in Workspace turn on or off depending on the TimeOfDay. I'm more of a builder than a scripter... I copied a few lines from multiple scripts but it doesn't work. local children = game.Workspace:GetChildren() local l = game.Lighting:GetMinutesAfterMidnight()/60 for c = 1, #children do if children[c].className == "SurfaceLight, PointLight" then children[c].Enabled = l18 end end - HabaneroDude
JarodOfOrbiter
#182935222Wednesday, February 03, 2016 4:36 PM GMT

local children = game.Workspace:GetChildren() local l = game.Lighting:GetMinutesAfterMidnight()/60 for c = 1, #children do if children[c].className == "SurfaceLight" or children[c].ClassName == "PointLight" then children[c].Enabled = l18 end end
HabaneroDude
#182935363Wednesday, February 03, 2016 4:41 PM GMT

Makes more sense but it still doesn't work. - HabaneroDude
TimeTicks
#182935388Wednesday, February 03, 2016 4:42 PM GMT

if TimeOfDay == "00:00:00" then globalshadows = false end
JarodOfOrbiter
#182935428Wednesday, February 03, 2016 4:43 PM GMT

That wouldn't work very well TimeTicks. Also, you need to loop the time checking, OP.

    of     1