I'd like to transform the quternion given by the phone since that seems a lot more accurate than using the gyro.
into a ray that points out of the top of the phone
flatten it to the x and y plane to calculate the angle
I think I need to first have the player calibrate it by having them point it toward the screen before pressing a button. This will determine which way the player is facing. hopefully it's just the quaternion multiplied by the conjugate of the quaternion gotten during calibration.
I'd like to transform the quternion given by the phone since that seems a lot more accurate than using the gyro.
I think I need to first have the player calibrate it by having them point it toward the screen before pressing a button. This will determine which way the player is facing. hopefully it's just the quaternion multiplied by the conjugate of the quaternion gotten during calibration.