Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | puppetmaster- | |
Old Version | Published before Godot 3 was released. |
I have a RigidBody2D with mode Character.
Sometimes I change the mode to Rigid and let the body rotate physically.
But when I want to change the mode back to Character the rotation should also go back to 0.
How can I do it?
I’m not sure I understand your question but it sounds to my like set_rot(0)
would work?!
umfk | 2016-03-13 14:33
I tried all the time changing the rotation with set_transform() or set_global_transform() and never tried it the easy way
It seems set_rot(0) would do the job but when the rotation is to fast it doesn’t stay on rotation = 0
I do it in this order
body.set_mode(2)
body.set_rot(0)
Is there a possibility to stop the rotation without setting mode to static?
puppetmaster- | 2016-03-13 20:23
Well, you can just set_rot(0) on both this and the next frame, right?
Bojidar Marinov | 2016-03-19 16:26