How do I use the accelerometer

Get help using Construct 2

Post » Fri Apr 04, 2014 11:31 am

Hey,

I have this game where I need to move around with the player with no touch controls, only by tilting the device.
A good example that I could think of is dark nebula, as it moves in all directions.
How can I make that please? I saw a lot of answers in the forum, but non seems to be working...

Regards,
Andrei
B
8
S
1
Posts: 20
Reputation: 567

Post » Fri Apr 04, 2014 11:44 am

You might want to check to make sure you device can access Alpha, Beta, and Gamma. I have an iPad 1 that I was trying to get the compass and tilts to work on an HTML5 export, and I couldn't get them to work. As it turns out Safari on an iPad 1 running iOS 5.something is unable to access Alpha, Beta, and Gamma.

So just something to check...
B
17
S
4
G
3
Posts: 172
Reputation: 1,933

Post » Fri Apr 04, 2014 11:54 am

Then, as the player is small, what alternative would you recommend? If I use touch, to use buttons for left, up, right, down, or to use the screen, wherever is touched it will follow the finger's direction? So if the player is at 12, 12 position and the user presses the screen at 70,70, it will copy the finger's movement and apply it to the player?
B
8
S
1
Posts: 20
Reputation: 567

Post » Fri Apr 04, 2014 11:59 am

You could use gestures. (Of course that's a little harder to code)
B
17
S
4
G
3
Posts: 172
Reputation: 1,933

Post » Fri Apr 04, 2014 12:38 pm

I have made it work with this viewtopic.php?f=147&t=95314&p=737267&hilit=gestures#p737267 but it's not was I inted.
How can I use the tilt function? Do you have any example?
B
8
S
1
Posts: 20
Reputation: 567


Return to How do I....?

Who is online

Users browsing this forum: David181, Shenkai the ssj, tatogame, Yahoo [Bot] and 18 guests