- Posted on
Sun Apr 26, 2015 12:44 am
-
howartp
offline
-
- Posts: 4559
- Joined: Jan 09, 2014
- Location: West Yorkshire, UK
Ok, two options spring to mind.
1) Use Python to iterate through all Lights-that-are-on and issue the Off command.
2) Use a virtual device/group (I can't recall which), add the lights which are controlled by the script to it, and Save its state with the lights in your desired position (ie mostly off). Send the TurnOn command to the virtual thing and it will put the lights into the saved state.
3) In the UI, you can overwrite a delayed action time with another; if you can do this in script, just overwrite the delay with one for a small number of seconds.
You say AllLightsOff will be slow - depending how many lights are in this script compared to your total number of lights, nothing is going to be very quick here - all we're ultimately doing is sending AllLightsOff but manually. It just depends how many we're talking about and which option you pick.