Converting force and torque from world space to local space


i cannot find search button on this new forum :confused:

lets say, when player presses forward button, force vector will be local

Vector3f localForce = new Vector3f(0f, 0f, 1f);

if i want to go forward relative to player, not world, i simply do

Vector3f worldForce = rigidBody.getPhysicsRotation().mult(localForce);

but what if i have worldForce and want to convert it back to localForce?


1 Like

perfect thanks :slight_smile: