Hello, i’m creating FPS game for mobile
but i have little problem in my code
that if i want to look right or left
i must tilt the phone like the Car Steering wheel
i dont need it that way
i want to rotate the phone in x axis
sorry my english is bad
this photo may explain what i want
rotationX += Input.acceleration.x * sensitivityX;
rotationX = Mathf.Clamp (rotationX, minimumX, maximumX);
// transform.localEulerAngles = new Vector3(0,rotationX, 0);
transform.rotation = Quaternion.Euler(0, rotationX, 0.0f);
i hope someone can help me
or guide me to the right way