Touch Thumbstick

Get help using Construct 2

Post » Thu Jun 07, 2012 3:32 am

I am trying to make my game touch compatible, but that requires smooth touch control. So I tried to implement This example but I cannot get it to work, I think it is because of some other touch events that I have, but I cannot be sure.

Here is my .capx
https://dl.dropbox.com/u/14533548/Xylon.capx
B
5
Posts: 10
Reputation: 445

Post » Mon Jun 18, 2012 8:14 am

Bump! Please help! I need this to make it work with touch!
B
5
Posts: 10
Reputation: 445

Post » Mon Jun 18, 2012 8:29 am

B
95
S
25
G
20
Posts: 3,052
Reputation: 22,613

Post » Mon Jun 18, 2012 10:23 am

Ok several problems in your code ...

First, as in the example put the Touch object with property "input compatible mode to yes" ... so you can test your "touch" code using a mouse on pc ;-p

Second one ... change all "left click" for "right click" and specially in the PC/Control section because touching the Thumbstick will now make you fire (when testing touch on a pc) if don't doing that ;-p ...

Third ... remove all references to ("stick") so all Touch.X("Stick") => Touch.X and all Touch.Y("Stick") => Touch.Y ... why ? ... probably because you don't have a layer with name "stick" !

ok ... i have testing this on a PC and now it works pressing "c" and using mouse as touch so it works also on mobile ... just something ... you could perhaps have some problem with the fire touch AND using touch stick at the same time (I don't think so but if so multitouch plugin exists ...) don't forget to add here a delay as for the click firing in pc mode !.

last comment : please add arrows key support, space to fire and remove the "while" plugin from this project if don't using it ... you mobile support stay incomplete ... the mouse pos is use to rotate the turret on pc .... but on mobile ? ...

Enjoy !
naelian2012-06-18 21:45:48
B
16
S
5
G
3
Posts: 298
Reputation: 5,240


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 28 guests