Zoomulator
- 3
- 0
I'm currently developing a game using a pre-existing physics library called Box2D and I've stumbled into some unexpected behavior that I can't pinpoint being actual physics or an artifact of the programming.
My spaceship is traveling through a 2D vacuum facing straight along it's velocity vector. If I apply a force right behind it to simulate a thruster, it accelerates and continues on the same path.
Now, say I rotate the spaceship 90deg while it's still traveling in the same direction. I fire the thruster and expect it to keep facing 90deg off it's former course and make a curved path, but instead it rotates back toward it's velocity's direction.
I would also expect that if the spaceship was spinning, that it'd keep spinning if I fired the back thruster and that it'd expand out into a spiral path. Instead it stabilizes the spin and runs off straight.
So basically the question is, will a thruster being the only force and pointed right at the center of mass cancel out spin?
My spaceship is traveling through a 2D vacuum facing straight along it's velocity vector. If I apply a force right behind it to simulate a thruster, it accelerates and continues on the same path.
Now, say I rotate the spaceship 90deg while it's still traveling in the same direction. I fire the thruster and expect it to keep facing 90deg off it's former course and make a curved path, but instead it rotates back toward it's velocity's direction.
I would also expect that if the spaceship was spinning, that it'd keep spinning if I fired the back thruster and that it'd expand out into a spiral path. Instead it stabilizes the spin and runs off straight.
So basically the question is, will a thruster being the only force and pointed right at the center of mass cancel out spin?