I think it’s your time of day comparison.
If time of day crosses midnight, it’s resetting to 00:00:00, which is before Dusk.
The comparison should be (TimeOfDay > Dusk) OR (TimeOfDay < Dawn)?
I think it’s your time of day comparison.
If time of day crosses midnight, it’s resetting to 00:00:00, which is before Dusk.
The comparison should be (TimeOfDay > Dusk) OR (TimeOfDay < Dawn)?