Cool, that certainly works. I’m guessing this would be better because it’s more optimised?
Ideally i wanted to use the same value rather then using now() again as the time will differ ever so slightly (but probably not worth bothering about).
I tried to find the last_updated state of the automation but i couldn’t find out how to get that. I was thinking trigger.automation.to_state.last_updated but any permutation i put in developer tools doesn’t work for me.
in the Action block as above for current_time. Defining it as a trigger variable or script variable will not work because last_triggered is not updated until the conditions are passed.
The trigger variable is undefined outside a running automation.