I'm currently trying to make a simple little 3D Asteroids clone for programming practice, but I've hit a major snag; I need to simulate realistic space physics for the player controlled ship.
I've tried a bit of a 'cheat' method by recording the old position of the ship, moving and rotating it, then measuring the distance it's moved, moving it back and translating the ship the distance it's moved. Thinking this over, it's pretty obvious why it doesn't work! I'm sure it *is* possible doing it this way with a bit of modification, but my brains are just not working at the moment.
The alternative is to get maths heavy and perform vertex calculations, etc. I'll admit that my geometry isn't brilliant with this sort of thing. Essentially, all I need to do is add the thrust vector to the velocity vector. Sounds simple enough I guess, but I don't really know where to start.
Any ideas? Articles I can read? (that isn't written in double-dutch!)
Thanks. :)
EDIT: Adding vertices isn't the problem by the way. When they are using rectagular coords (XYZ, etc.) it's easy! It's much harder when it involves angles and velocities though which is what blitz uses...
I've tried a bit of a 'cheat' method by recording the old position of the ship, moving and rotating it, then measuring the distance it's moved, moving it back and translating the ship the distance it's moved. Thinking this over, it's pretty obvious why it doesn't work! I'm sure it *is* possible doing it this way with a bit of modification, but my brains are just not working at the moment.
The alternative is to get maths heavy and perform vertex calculations, etc. I'll admit that my geometry isn't brilliant with this sort of thing. Essentially, all I need to do is add the thrust vector to the velocity vector. Sounds simple enough I guess, but I don't really know where to start.
Any ideas? Articles I can read? (that isn't written in double-dutch!)
Thanks. :)
EDIT: Adding vertices isn't the problem by the way. When they are using rectagular coords (XYZ, etc.) it's easy! It's much harder when it involves angles and velocities though which is what blitz uses...