Skip to main content
Version: 4.3.0

Finger Touch

Use Finger Touch to take different executions when the device screen is touched by one or two fingers and when the device screen is not touched.

note

For two-touch to be detected, the first finger can not leave the screen when the second finger is detected. Touch 0 is the first finger detected on the screen; and Touch 2 is the second finger, in addition to the first finger, detected on the screen.

finger touch node

Input

NameData TypeDescription
DetectStringChoose Touch 0 to detect the first touch; choose Touch 1 to detect the second touch

Output

NameData TypeDescription
IdleExecExecute the next node when no finger touch detected on the device screen
On StartExecExecute the next node as soon as someone's finger touches the device screen
StayExecExecute the next node when someone's finger stays on the device screen
On StopExecExecute the next node as soon as someone's finger leaves the device screen
Current PositionVec2The position of tapping point in the current frame. If the node execution is Idle (no touch detected), this position returns (-1, -1).
Last UpdatedVec2The position of last updated tapping point

Test the Effect

note

Two-touch can only be tested in the TikTok app.

Test your effect on your mobile device by scanning the QR code from within the TikTok app. Learn more about how to preview your effect. Be sure to point your camera at an image of the target texture.

target tracker qr code