I'v been trying to make(only just begun, i'm stuck) a Gravity Force / Roketz / Bratwurst - clone of my own just for kicks and becouse I first figured it would be relativly easy
.
I'm trying to make the physics-part but I can't seem to make it work as I want it to.
In this type of game i'm figuring you have two forces, first of the gravity whitch wants to pull everyting downward, and then the force outputted by the ships-thrusters and only after the thrust exeeds the power of the gravity will the ship be able to accelerate forward.
I mean I have it all finished in my head but I just can't seem to figure out in whitch end to start yet and I wondering if someone could give me some pointers.
What I'm really stuck on is the whole accelerate-part. Since gravity willhave to pull everyting down, the ship won't just stop when using thrusters but slow down as the thrust works against gravity and then begin it's journey forward. And if you cut the thrust the ship will again not just stop and go towards gravity since it had a momentum(whitch won't last though).
How would I go about in practice coding this?, the soft slowing down between gravitys pull and the momentum after thrust slowly getting lower and lower before the ship is again pulled down by gravity.
Hope all that rambling got through.
One more thing though, i'm a newbie and i'm comming from other languages where I rely heavily on Object and OO style programming(from c# to php even). HOW, does one go about applying gravity to more objects then only the ship I wanna control,
I mean, If I could use classes and such I could make a class(once I knew how to code the gravity part) a let it be used to handle everything in the game that needs to be controlled by gravity. But how, oh how does one work it out in dark basic ???.
I think i'm not used to thinking in Basic-ways.
Thanks in advance.