Simple swipe on object

Attached Files

The following files have been attached to this tutorial:

.capx

Stats

5,011 visits, 8,350 views

Tools

Hello all !

Today, I will explain to you how to detect simple swipe events !

You don't need a lot of Global/Local variable and no more events !

Let's begin :)

First step

First, you have to create your unique variable : IsSwiping

After, make your event like this :

Why ?

In construct 2, AngleAt(0) (which return angle with touch id 0) return values of angle like this.

Now, you can make your own directions !

Moreover, "1000" value in the first event mean the speed of the swipe :)

The higher value is, the harder is it to swipe ;)

(Sorry for English, I'm french ^^ Tell me if I'm wrong)

.CAPX
  • 1 Comments

  • Order by
Want to leave a comment? Login or Register an account!
  • Your swipe left and right code is backwards. it needs to be swapped around in your capx.