Hi,
I’ve got a question about Phys2D (or maybe more physics in general). I’m planning to use it to simulate movement of a mobile two-wheeled robot around a world with obstacles. The wheels are differential, i.e. the robot turns because of the different angular velocity of the wheels. On each timestep the robot determines what force/velocity to apply to each wheel.
The question is: I know how to calculate the robot’s next position and rotation from the velocities. However I imagine I can’t set the position and rotation directly since that will screw with the logic of the physics engine. So I imagine I need to do it by applying velocities/forces to the robot. Thing is…I don’t know how to since the robot is describing a circular path most of the time, and from what I saw about velocities the best I can do i s to send it in a straight line spinning around its own axis.
Anyone knows how to go about this, or if there perhaps is a way in which I can set the position and rotation directly and still have all the functionality of the engine?
Thanks