Jump to content
  • Advertisement
Sign in to follow this  
DirectXFreak

Ok, so how did they do it in treadmarks?

This topic is 5145 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey, How did they do the tank physics in treadmarks? It looks like the tank is just one rigid body... no springs or wheels... Can anybody explain how?

Share this post


Link to post
Share on other sites
Advertisement
Does anybody know? I'm really lost when it comes to tank physics... Can somebody point me in the right direction? I understand rigid body dynamics, but what about driving it around?

Share this post


Link to post
Share on other sites
I would guess it's just a box with 4 contact points at the bottom corners. Not really 'tank physics',
just box physics. I don't think they are doing anything special.

Share this post


Link to post
Share on other sites
Hmmm, ok, so how would you code something like that?
Would you check to see if one of the points are colliding and if so apply the force (acceleration from the gas pedal)? I thinking I'm starting to understand but there's still some fuzziness, any help you be greatly appreciated.
I'm just trying to figure out how to drive it around in 3D!

Share this post


Link to post
Share on other sites
Battlefield 1942 had some amazing tank physics I thought. The ways the track laid over the bumpy terrain was excellent. When tanks fired they rolled back slightly and it all looked perfect.

Share this post


Link to post
Share on other sites
Yeah, they do some cool stuff. But there's no where on the net (at least that I can find) that tells me how! What kind of math equations does treadmarks use? If anybody knows where I can find out then please tell me (and don't say google, I've tried that).

Share this post


Link to post
Share on other sites
Quote:
Original post by Hybrid
When tanks fired they rolled back slightly and it all looked perfect.


== animation not physics. typically for things like firing animations where you want a subtle feel to the "physics" you'll handle the recoil with an animation that just layers above the "physics" of the tank. it's amazingly simple to get a feeling of "amazing" physics if you have a good animator and some really rudimentary physics...

-me

Share this post


Link to post
Share on other sites
Hmmm, ok, I have another question...

If you were going to model a tank using springs and wheels and the base rigid body model, would you model the wheels as mass points?

In other words, would it just be a point where the wheel would touch the ground? And if so, would you apply the force of the treads only if the points were touching the ground? And if that was true, would you then place the base of the tank on top of springs over the box points that would then add the essence of weight tranfer to the tank? (It would pitch slightly when it fires)

Is this a valid way to do it? Is there something I'm missing?

Share this post


Link to post
Share on other sites
The reason I say box physics, because in Treadmarks, the entire tank is two pieces, the turret, and the
body. The turret has nothing to do with how the body moves, so you just have the body. And this body is
one complete unit, all the treads and other detail is just painted on a box. There are no springs, no wheels, or complex connections.
That's my guess.

I haven't played Treadmarks in a while, but you get a sense of the physics by moving the tank over very
steep terrain. Find a map with peaks and try to climb up them and let the tank hang over a cliff
or something. This will give you a sense where those contact points are located.

Share this post


Link to post
Share on other sites
Ok,
I'm starting to get a good grasp on this! Thanks so much for your help guys!

I just have one more question, where would you apply the force on the tank? To the very rear of the box? And what kind of friction equations would you use? Thanks!

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!