Uploaded May 2026 | Updated September 2026, 38 minutes ago
Learn how to use listener action scripts in Rive to detect the difference between a single click and a double click — something that's much harder to pull off without scripting.
Jeff walks through building a double click detector script that uses a configurable time threshold to distinguish between the two events. The script fires a clicked trigger for single clicks and a doubleClicked trigger for double clicks, both of which can drive state machine transitions.
You'll see the full setup: creating the listener action script with its default template, wiring it to a view model with clicked and doubleClicked triggers, attaching it to a listener on the state machine, and applying it to a fun bubble animation with hover, pop-in, and pop-out states.
0:00 — What are listener action scripts
0:28 — Default script template structure
0:53 — Double click detector script walkthrough
2:49 — Wiring the script to a state machine listener
4:12 — Setting up state machine transitions with any state
4:54 — Applying to a bubble animation
Learn how to use listener action scripts in Rive to detect the difference between a single click and a double click — something that's much harder to pull off without scripting.
Jeff walks through building a double click detector script that uses a configurable time threshold to distinguish between the two events. The script fires a clicked trigger for single clicks and a doubleClicked trigger for double clicks, both of which can drive state machine transitions.
You'll see the full setup: creating the listener action script with its default template, wiring it to a view model with clicked and doubleClicked triggers, attaching it to a listener on the state machine, and applying it to a fun bubble animation with hover, pop-in, and pop-out states.
0:00 — What are listener action scripts
0:28 — Default script template structure
0:53 — Double click detector script walkthrough
2:49 — Wiring the script to a state machine listener
4:12 — Setting up state machine transitions with any state
4:54 — Applying to a bubble animation










