Multiple Touch scripting

Get help using Construct 2

Post » Thu Mar 07, 2013 4:37 pm

I was trying to figure out the best/easiest way to have the functionality of having a sprite (round), when you touch and drag you move it around normally. But if you have one finger on it, then put another finger down and turn, the sprite will turn with the 2nd finger (like a knob pretty much).

I tried an event where if touching sprite and on Nth Touch started (1), to set the angle of the sprite to where the 2nd touch is. It seems like the sprite turns a little towards the 2nd touch but then nothing else. Its weird because I don't really see any event to keep running on the Nth touch like is touching?

Anyone do something like this that could help? I'm sure it is probably not too hard but I program all day and then get home and try and do more and my brain is usually fried by then :(
Twitter: https://twitter.com/pudgyplatypus

Learn to make a clicker game for cheap!
https://www.scirra.com/store/games-with ... e-game-666

Try out Pixel Golf on the Scirra Arcade!
https://www.scirra.com/arcade/sports-ga ... el-golf-67

Pudgy Platypus Games website!
www.pudgyplatypus.com
B
53
S
16
G
5
Posts: 206
Reputation: 6,826

Post » Tue Mar 26, 2013 7:50 pm

hey dude. i dont know the answer but i have some ideas. am i right if i assume that you want to move the sprite around like a circle and you want the second finger to be the center? like a dividers?
at first i would try using the MultiTouch Plugin.
http (colon) //www.scirra.com/forum/plugin-multi-touch_topic49525.html

secondly i would try to create a "limited revolute joint" on "second touch".
you can ad limited revolute joints to your sprites if they have physics behaviour.

i have no idea if this is going to work and how this is going to work but i hope i could help you a little bit.
B
23
S
6
G
5
Posts: 132
Reputation: 4,487


Return to How do I....?

Who is online

Users browsing this forum: heliogame and 19 guests