mobile swipe gesture?

Get help using Construct 2

Post » Wed Dec 28, 2011 3:14 pm

Does anyone know a way of detecting a swipe gesture?

I have 4 object, I want the user to be able to swipe left and right to select one,

Its gotta be something to do with touch down, velocity? Can we determine the velocity of the touch/mouse object?
B
6
S
1
G
1
Posts: 42
Reputation: 810

Post » Wed Dec 28, 2011 3:37 pm

Never used the touch object, but I think you can emulate that by keeping trace of the mouse position, comparing values from one tick to another and then if the velocity is high enough during a certain amount of time, you have successfully swept (:
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Wed Dec 28, 2011 4:33 pm

Well touch and mouse are practically the same, So i'll give this ago thanks!!
B
6
S
1
G
1
Posts: 42
Reputation: 810

Post » Wed Dec 28, 2011 5:25 pm



I have been googling around for a bit and am trying to determine how to do a simple swipe event across an html element such as a div, to cause some action to happen in javascript.
carlomartin252012-01-02 17:38:31
B
2
G
1
Posts: 1
Reputation: 602

Post » Wed Dec 28, 2011 5:29 pm

Really? why, are you planning on developing a plugin?

If your looking for mobile html elements to en corporate through javascript take a look at iscroll, or jquery mobile.
B
6
S
1
G
1
Posts: 42
Reputation: 810

Post » Wed Dec 28, 2011 9:51 pm

@DiggyDog I'm actually in the end phase of developing an adaptation of iScroll, but encountered a bug when the device orientation is horizontal.
When I'll solve it, I can release it.
B
44
S
12
G
13
Posts: 628
Reputation: 10,471

Post » Sun Jan 01, 2012 10:12 pm

@septeven,

Cant Wait!!!! Dow you have a rough estimate of completion time? :) Is there anything I can do to help?
B
6
S
1
G
1
Posts: 42
Reputation: 810

Post » Mon Jan 02, 2012 4:04 am

it's coming ;) septeven2012-01-02 04:04:54
B
44
S
12
G
13
Posts: 628
Reputation: 10,471

Post » Tue Jan 31, 2012 9:21 am

Hi Septeven,

Have you got the mobile swipe gestures working yet?
B
5
S
1
G
1
Posts: 111
Reputation: 1,122

Post » Tue Jan 31, 2012 9:48 am

@2Bdigital I will be working on a carousel part for my plugin, that finally behaves with swipe gesture.
B
44
S
12
G
13
Posts: 628
Reputation: 10,471

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 0 guests