Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / A logic Question, then I can start towards that direction.

Author
Message
DarrylKev
21
Years of Service
User Offline
Joined: 5th Nov 2002
Location:
Posted: 23rd Nov 2002 17:28
Hello Group

I'm not really new to programming (some C++, fortran and basic (a long time ago) but I am new to game and 3dimensional programming.

My final goal is the creation of a real physics mecha space combat shooter. If anyone out there has played the Space Missions of Heavy Gear 2, the miniatures game Jovian Chronicles or seen an episode of Mobile Suit Gundam you know where I am heading.


To that end, I was wondering if someone(s) would answer this question. After finishing the first few camera tutorials, the logic of camera and object movement as it relates to my project would imply that I need to code such that if I hit a direction key one time the object would keep going in the direction of movement until another direction key is hit. Now if the key that is hit is not 180 degrees out from the first key the movement will not be halted, but the angle of movement will be changed.

Now if I have a camera mounted on the front of this object (or the typical 1st person viewpoint). Would the motion displayed take on the feel of zero-g movemnt???

Okay, so does this make sense given my original gaming goal. I realize that there is a whole lot of code between these simpole camera/object movements and that program I want to build, but I need to see a clear starting point.

Oh well, any comments/suggestions/critiques would be appreciated.

Thanks

DarrylKev
The Darthster
21
Years of Service
User Offline
Joined: 25th Sep 2002
Location: United Kingdom
Posted: 23rd Nov 2002 23:18
It sounds like you need motion without friction, not necessarily zero g, but I see where you're coming from. The way to do that is to have your controls change the thrust, and then the thrust will in turn acclerate the object (remember F=ma). This is so even if you let go of the controls the object will keep moving. You have a thrust vector (cartesian or polar) that changes with input, then you have a velocity vector (again cartesian or polar) that the thrust vector is added to each cycle to produce an acceleration. Thus moving the object in a frictionless way.

Login to post a reply

Server time is: 2024-03-29 14:18:52
Your offset time is: 2024-03-29 14:18:52