Running a script for as long as a button is held
Posted: Thu Oct 10, 2019 7:55 pm
I've got a script which sets lights to random colors, and I'd like it to hold the channels at the levels it chose until a button is released.
Here is the script I'm using:
What can I do to attach this to a "flash" button so that it holds its value until the button is released? I know I could add a fixed "wait" time, however I want the values to stop being held when the button is released.
Here is the script I'm using:
Code: Select all
setfixture:0 ch:5 val:255 // Dimmer
setfixture:0 ch:7 val:random(0,255) // Red
setfixture:0 ch:8 val:random(0,255) // Green
setfixture:0 ch:9 val:random(0,255) // Blue
setfixture:0 ch:10 val:random(0,255) // White