Tilt controls - GS viewer

drs997drs997 Member, PRO Posts: 27

Hi Guys,

I'm trying to figure out tilt controls for my game. My game is in landscape orientation, and I want the actor to move up when tilted to the left, and move down when tilted to the right.

I followed a video tutorial, seemed simple enough. When testing in GS viewer, results are not as expected.

To try and debug, I placed 2 actors on the scene that display the values of game.accelerometer. X and game.accelerometer. Y.

When the iPhone is laying flat on my desk, these values are constantly changing. How can this be?

When testing on PC, the values remain constant at zero.

Hope you can help,
Thanks

Comments

  • mc99093mc99093 Member, PRO Posts: 133

    here is a tutorial that will help you

  • SocksSocks London, UK.Member Posts: 12,822

    @drs997 said:
    I placed 2 actors on the scene that display the values of game.accelerometer. X and game.accelerometer. Y.

    When the iPhone is laying flat on my desk, these values are constantly changing. How can this be?

    Your phone is probably moving very slightly.

    @drs997 said:
    When testing on PC, the values remain constant at zero.

    Does your PC have an accelerometer built in ?

Sign In or Register to comment.