if (xInput > 0)
transform.localEulerAngles = new Vector3(0, 0, 0);
else
transform.localEulerAngles = new Vector3(0, 180, 0);
if (xInput > 0)
transform.localEulerAngles = new Vector3(0, 0, 0);
else if (xInput < 0)
transform.localEulerAngles = new Vector3(0, 180, 0);