Screwed up Plane

Hi Everybody,
I’m working on getting the controls for a plane down for a game i’m working on. I gen get it to roll, climb/dive and then when i tried to make it fire a bullet with space, when you fire the bullet it moves the plane like up and to the right i think.
Try for yourself
http://mercury.walagata.com/w/dr nick/plane_physics.blend

Any ideas would be appreciated
Thanks

Also if anyone knows y it double posted :slight_smile:

hi
for that kind of simulation/game you should set gravity to 0.0 in the world parameters

Also the size of your plane was too big (i mean the property named size in the logic panel)(switch into wireframe by pressing Z and see the circle around your plane center, the size value reduces its size (it’s a circle because your plane is a considered as a sphere by default, by the game engine).

You should reset your plane’s origin in the F9 panel by clicking on centre new or centre. (and it will move your center at the barycentre of your mesh or something…). Your origin was much below the plane which was a good idea at first sight because your missiles would spot there and would not kick the plane upwards every time. However, the cicrle which I talked about earlier has its center at the centre, so you’d better reset the center to its “real” position, to have better results in simulation. The problem of the plane’s popping up at each missile shot was due to the fact that the missiled spawned “inside” the plane because it spawned inside the collision sphere which is centered on the plane’s center. After resetting the plane’s centre to something more realistic, you should also set your missile to Ghost, or create another “launcher” object which you link to the plane and put below.

here’s your file… I’ve changed the plane’s speed in addition to what’s above, and added a light in your rocket’s layer, because it needed one to look shaded when playing.

www.ece.fr/~schroder/ecequisse/cours_de_blender/plane_physics_works_better.blend

Jonathan