- Home /
Windows Phone 8 & Gyro
Hi there!
Is Unity supporting gyroscope in Windows Phone 8? Because it doesn't work... I tested my prototype on Lumia 820 & 920. On both gyro doesn't work, but same project work perfectly on my BB Z10.
Any ideas? We need gyro on WP8 to our projects.. :/
Answer by Gaello · Jan 21, 2014 at 06:50 PM
Gyro on WP8 is turn off by default...
Input.gyro.enabled = true;
solved problem ;)
Hi...
I was trying exactly the same thing....but it didnt work for me... I am using a character controller for an fps game using gyro for rotation...
Is this code correct...??
void Update() { .....
Input.gyro.enable = true;
//rotate the character controller
transform.rotation = Input.gyro.attitude;
......
}
also, is there any problem writing enable in Update()... also, is the following code better/correct...??
transform.Rotate(0, Input.gyro.rotationRate.y, 0);
(im just rotating it across y axis...)
Thanks in advance... :D
use Input.gyro.enable = true; in Start :)
also you should look at this: http://blog.heyworks.com/how-to-write-gyroscope-controller-with-unity3d/
good luck :)
Your answer
Follow this Question
Related Questions
Gyroscope on windows phones. Enabled but no working 0 Answers
External gyroscope question 1 Answer
How to setup android build so that users without gyroscope do not see it in Play Store ? 1 Answer
Calibration Script 0 Answers
gyro to mouse look 0 Answers