If the Switch is pressed continuously for a set time (for example, 3 seconds), the specified bit will turn ON. This is useful in preventing accidental input.
If you take your finger off the switch before it gets enabled, the Switch action will be disabled.
Add the below variable(s).
| [Name] | [Data Type] |
Var1 |
[BOOL] |
Drag and drop the following objects from the [Tool Chest] to the screen.
Default value
Set the following script on the object.
From the [Tool Chest] drag and drop the script to the Script editor.

| Legend | Block |
1 |
[Triggers] ➞ [Touch] ➞ [Touch] |
| 2 | [Operations] ➞ [Value Change] ➞ [Bool Value Change] |
3 |
[Values] ➞ [Variable] |
4 |
[Values] ➞ [Screen Object] |