[SOLVED] Cannot Calculate the Milliseconds time difference between two vars

What exact behaviour with your lights are you trying to achieve?

While loops in rules are dangerous because you are blocking a thread. There may be more elegant ways to achieve this.

See: