Rapier does not move RigidBody in expected direction

Hi! I have a RigidBody with the components (Velocity, Transform). When changing the rotation with transform.rotation = …, the “forward” direction of the body remains the same when adding velocity. How come this happens? I can’t use angular velocity, because I’m rotating alongside a camera.

Thanks!

Presumably the velocity given is in world space rather than model space.

I understand that, but is there a way to fix it?

As you're talking about components, I presume you mean bevy_rapier3d specifically? This Velocity and bevy's Transform?

Yes, those are the components I’m using.

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.