Closed customlogic closed 8 years ago
You can now add controllers to functions like
gui.add( state, 'reset' )
Where reset is a function on "state".
I've actually always wanted a
gui.add( someFunction )
and have that work instead of the ugly workaround
gui.add( {someFunction:function(){}}, 'someFunction' );
Maybe that can be a new issue.
Add a control that takes a function as an input, and creates a button on the GUI. When the user presses the button, the function executes.
Perhaps the UI element is similar to the checkbox, but after you press it, it returns to it's start state.