- Home /
iPad tilt gives weird behaviour
Hey folks,
I'm moving a 2D object on the X axis (via transform.position.x) in landscape mode. When I tilt the device past roughly 45 degrees the object stops moving and even the values being displayed for things like rotation stop at the last value prior to tilting past that angle.
I'm calculating the angle with: Mathf.Rad2Deg * Mathf.Atan2(Input.acceleration.y, Input.acceleration.x)
Movement of the object works just fine except, like I say, when tilting left or right past around 45 degrees.
Any thoughts?
Thanks!
Your answer
![](https://koobas.hobune.stream/wayback/20220613074152im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Pinch vs. Rotate gestures: can they be made size/resolution-independent? 2 Answers
Are soft shadows supported on iOS ? 2 Answers
need help launching game to app store 1 Answer
iphone ios version and sdk version 1 Answer
What do i need to run my built application for iphone using unity to be run on android devices 1 Answer