Hi, i did a simple movement player script using character controller. Player rotate of 90 degree on the Y asse, now without smooth effect(i will do in a second moment)
But after 4 or 5 rotates the rotate it becomes more and more inaccurate.
I don’t undestand why.
void Update()
{
pController.SimpleMove(pController.transform.forward * forceValue);
}
public void rotateDX()
{
if (isRoteable)
pController.transform.Rotate(transform.rotation.x, transform.rotation.y - 90, transform.rotation.z, Space.World);
else
Debug.Log("Chiama GameOver");
}
public void rotateSX()
{
if (isRoteable)
pController.transform.Rotate(transform.rotation.x, transform.rotation.y + 90, transform.rotation.z, Space.World);
else
Debug.Log("Chiama GameOver");
}