Hello. I have this current script that somehow works as it should be. It’s a script that loops my light sequence when triggered. But I’m just wondering if this can be written in a much simpler way?
So currently, it works as I want it to. But when I check the history, It starts, play the entire sequence, and then stops at the end of it. Then repeats it again until it meets the time specified.
Is there a simpler way to write something that will loop the light from 4PM to 4AM?
Question for you:
What if the current time is not > 16:00 or < 04:00 and script.light_themes_off_s is on? Your service_template doesn’t produce a result for that possibility (and will cause an execution error).