private void RotateManually(float rotationThisFrame) { rigidBody.freezeRotation = true; // take manual control of rotation transform.Rotate(Vector3.forward * rotationThisFrame); rigidBody.freezeRotation = false; // resume physics control of rotation }
As soon as i enter play mode, the “Freeze Rotation” constraits will untick, and if the rocket will collide will spin like crazy.
Unfortunately, Ben’s solution did not work as expected. For this reason, he introduces a new one in lecture “Spit & Polish” (currently #71). The fix is very simple. Remove the freezeRotation lines. Then add the following line at the top of your rotation part: rigidBody.angularVelocity = Vector3.zero;.