Jump to content
scotg

Let's talk suspension

Recommended Posts

I'm looking at the model.cfg for the Offroad pick-up truck, and wondering exactly what are all the the wheel bones. Every wheel has a standard number ranging from wheel_1_1 and wheel_2_1 to wheel_1_4 and wheel_2_4. Right off, I count EIGHT wheels for the Offroad. Each number has additional bones associated to its base wheel, and they seem to be attached to the chassis in this order: wheel_x_x_damper_land, wheel_x_x_damper, wheel_x_x_steering, wheel_x_x, wheel_x_x_unhide, and wheel_x_x_hide. This is a potential of forty-eight bones.

Am I correct to assume that the bones prior to the wheel itself are suspension parts? If so, then looking at a typical wishbone suspension, which part would be the A-arm, and which is the spring?

What do the _unhide & _hide parts do? My guess is for tire damage or maybe lose a hubcap... Could it be either, both, or none of the above?

 

I've got a 4x4 vehicle with independent wishbone suspension, and I just need to know how complex I can make its suspension in-game given what's available from the Offroad as a template.

Share this post


Link to post
Share on other sites

FYI this is the wrong section for this question.  The appropriate section would be the o2 or whatever the call it now modeling section in ArmA3 editing.

 

As for your question all vehicles are inherently 8 wheeled vehicles.  It's just that most do not include all 8 wheels.  wheel_1_1 is the name of a specific wheel.  the first number is which side is the wheel on, either driver side or passenger side.  The second number is the place the wheel is in relative to the other wheels, one being at the front and two, three and four going to the rear.  So example, if I remember right, wheel_2_3 would be the passenger side, 3rd wheel from the front. 

 

The "wheel_x_x_damper_land" are what someone would consider the suspension.  They don't actually act like a real car's suspension but with good modeling you can hide that.  Usually it's weighed at a certain amount for the suspension components, kind of like characters are weighed.  This does not include the wheel or the steering hub.

 

As far as the steering hub, I forgot the names but there's atleast four steering hubs.  You should only have two if you're doing a 4 wheeled vehicle.

  • Like 1

Share this post


Link to post
Share on other sites

Thanks DH! This clears up a lot of things. The BIS page on model.cfg says that in wheel_x_y the x is the position from front to back, while y is the position from left to right. It's a little baffling when you have a bone called wheel_1_4, which by their logic would indicate 4 columns of wheels (like a pair of quad roller skates) instead of 4 rows (like a Stryker). They must have been sleep-deprived when writing that page, like I was when I picked the wrong section for this thread.

 

I'd guess the steering hub must be wheel_x_y_steering. When looking at the bones in the model.cfg, there is a wheel_x_y_steering for ALL EIGHT wheels.

 

I suppose a conventional 4-wheel vehicle might have 2 steered wheels, but specialized, unique vehicles might have steering on all wheels. The Nissan 300zx TT is an example of this; it has a system called HICAS in which the rear wheels turned opposite the front wheels to a smaller degree. The visible difference of its rear steering was negligible, but the effect was faster, tighter cornering. For a more effective visual usage, somebody may have designed their own vehicle with all-wheel steering. Front loaders and train cars have similar steering functions. This is one of the appeals to having a game we can edit and import our own stuff into - R&D. We'd get to see how it might look in a real setting, and how it could be utilized in certain situations.  I'm getting off topic for the current vehicle I'm working on, but I'd hope to be able to tackle this easily if I ever need to.

 

So what I want to know is: if I have wishbone suspension on a vehicle with exposed wheels and suspension, how would I rig the A-arms and springs? Are they already part of the skeleton, like wheel_x_y_damper perhaps, or would I have to create a special IK animation for them? I can weight the springs as long as I could have the A-arm pointing towards the wheel at all times while attached to the frame.

Share this post


Link to post
Share on other sites

You can use any custom name for those parts if you want, as long as p3d, model.cfg and config are all matched.

You can't do Front and Rear steering. Only Frontsteering works.

 

 

Don't think of ingame suspension as realworld parts. Think of it as action.   "damper" -  translation up or down. "steering" - rotation around wheels vertical axis, "wheel" - rotation around axle, purely for visuals.  (Hide/Unhide for damage, optional)

Because whatever realworld suspension type you might want to create - you have to pressfit it into this configuration, without use of IK.  To move other parts of the suspension properly you would have to create extra animations and, together with weightpainting, somehow fit it to the movement of the wheel.

 

If you want a terrible example, look at the suspension / drivetrain of the vanilla militarytrucks when moving over bumpy ground. It's supposed to be a rigid axles, but it looks like some alien organism. Accurate or precise suspension action is not what PhysX can deliver.

  • Like 1

Share this post


Link to post
Share on other sites

I've worked with several game engines in the past 12 years. I'm no expert, though, since most of that has been on a non-professional level. I'm gonna have to call BS on "what PhysX can deliver," but I'm not pointing fingers at you x3kj. I don't think it's a condition of what PhysX can or cannot do; it's a matter of what the game engine programmers have or have not thought to include in their world. I've made mods for UT2004, Battlefield 2, Crysis, and lately ArmA 3. Here's what I don't get: Of all those engines, UT2004 (unreal engine 2.5) is the only one that had some kind of suspension realism. The tank treads flexing didn't always work, but the suspension arms could point to the wheel without relying on weighting/deforming. All the other titles on that list had only faked the suspension or none at all (but they also all supported tank tread flexing). How is it that the oldest game in my repertoire has better vehicle skeleton than the newest? Ok that was a bit of a rant, but it was due. Incidentally, Unreal Tournament 3 supported better tread flexing AND suspension rigging.

I see what you mean about those rigid axles; it's strange how something so rudimentary would be so complex to make it look right. I can see other examples of the pseudo suspension at work in the Offroad and the Quadbike, as tested. It's probably the same for other vehicles, but I didn't happen to test any others. This is that faked suspension I mentioned above. It's not pretty, but it's not as ugly as no suspension animation at all, except in the case of rigid axles. The ground vehicle physics in ArmA 3 are sub-par, anyway, so I suppose this is tolerable. It just seems like, if they figure out how to make 2D surfaces look like 3D (parallax occlusion), rag doll, super-realistic helicopter physics, etc, then why can't they get a simple vehicle suspension setup working?

Share this post


Link to post
Share on other sites

scotg if you want to understand how these work and make your own, be sure to check out the Samples_F in your ARMA tools dir.  Specifically there's a Test_Tank and Test_Car that you can completely open, tear apart, modify, and learn from.  It includes the configs, model.cfg, the models themselves, etc.

  • Like 1

Share this post


Link to post
Share on other sites

scotg if you want to understand how these work and make your own, be sure to check out the Samples_F in your ARMA tools dir.  Specifically there's a Test_Tank and Test_Car that you can completely open, tear apart, modify, and learn from.  It includes the configs, model.cfg, the models themselves, etc.

It looks like there might be updated samples, but I have referenced them before. I don't believe I am trying tricky stuff, but the test models are of very limited help. The last time I tried a tank it crashed my game. The car is of no help, and seems to have memory points that the Offroad doesn't. My SUV should work a lot more like the Offroad (BTW, I've made a Lambo LM002, one of quite a few vehicles I'm working on). I've actually got a lot of issues with this vehicle that I'm not sure how to fix... maybe I should start a new thread for that?

At this point I would like to ask the admin if they could move this thread to a more appropriate section. I'll leave it to your better judgment.

Share this post


Link to post
Share on other sites

I don't think it's a condition of what PhysX can or cannot do; it's a matter of what the game engine programmers have or have not thought to include in their world.

[...]

It just seems like, if they figure out how to make 2D surfaces look like 3D (parallax occlusion), rag doll, super-realistic helicopter physics, etc, then why can't they get a simple vehicle suspension setup working?

Physx does independant suspension because it is easy to implement and has less computational cost. And it does the "translation up down" thing because it is easy as well. For standard roadcars that is acceptable, for something more special (buggies etc) it isn't. A real suspension would have to follow a certain curve. That Arma has no inverse kinematics is not a physx fault, true

  • Like 1

Share this post


Link to post
Share on other sites

I get that it's less taxing on the CPU to fake real suspension, but the visual should also work, or it's all crap. It's like going to a second rate magic show, where instead of smoke and mirrors to hide the illusion, they use curtains. Even though you already know it's not real magic, the curtains - even the classy, expensive kind - just cheapen the act. I would think that developers of a game featuring more terrain than road would have thought "gee, maybe we should make suspension look visually acceptable by allowing the use of a skeletal rig for vehicles."

Getting back on topic, I think that there is a better way to create this illusion than what they've done with weights. After all, other modders have succeeded in creating more realistic towing, pilot-controlled turrets, and flexible antennae that bend when vehicles move. This is probably where scripting actually comes in - either in config or xml. I'm the artist with dangerously limited scripting knowledge type, so I wouldn't know.  There might still remain a certain level of weighting necessary, eg: if you have a spring modeled from a cylinder with alpha and bump to imitate the coil. Then, you'd weight the end edges of the cylinder to different parts of the suspension, just like it's already done with the quadbike.

Share this post


Link to post
Share on other sites

I just might. I'll admit that I'm one of the least likely candidates for pulling off such a task, but if that's what has to happen to get it done...

Share this post


Link to post
Share on other sites

 There might still remain a certain level of weighting necessary, eg: if you have a spring modeled from a cylinder with alpha and bump to imitate the coil. Then, you'd weight the end edges of the cylinder to different parts of the suspension, just like it's already done with the quadbike.

When compessing a coilspring, the "gaps" between 2 "revolutions" get smaller. If you compess a cylinder with alpha texture, the entire thing just gets squished, which looks wrong. It would only look adequate for small movements relative to the length of the cylinder.

Share this post


Link to post
Share on other sites

Then sub-divide the cylinder along its length and split it into different sections if you're that fussy :)

Share this post


Link to post
Share on other sites

that wouldnt help, same problem.

Even if you would model a 3D spring, you would still have the same problem

Share this post


Link to post
Share on other sites

Surely not if they were different selection names animated based on the animation phase of the previous section? So section1 compresses and when its fully compressed section2 begins to compress etc.

Share this post


Link to post
Share on other sites

 

So section1 compresses and when its fully compressed section2 begins to compress etc.

No, that's not how standard coil springs work ( so obviously not what i'm meaning). If you compress a cylinder with alpha texture the spring wire gets thinner. The gap and the "wire thickness" will always stay the same size relative to each other -> looks weird

Share this post


Link to post
Share on other sites

No, that's not how standard coil springs work ( so obviously not what i'm meaning). If you compress a cylinder with alpha texture the spring wire gets thinner. The gap and the "wire thickness" will always stay the same size relative to each other -> looks weird

True it doesn't look quite right, but doesn't it look more weird to you when there is no movement at all? While examining a weight-defined spring animation, it's easy to see its flaws because it's the focus of your attention. When playing the game your focus is probably going to be on something else other than suspension. You might or might not notice something is off about the springs while following a vehicle on a mission, for example, but you're more likely to notice if they aren't doing anything at all. Perhaps it's a matter of perspective, but that's just my take on it.

 

Surely not if they were different selection names animated based on the animation phase of the previous section? So section1 compresses and when its fully compressed section2 begins to compress etc.

That sounds like it might work for a telescope or something. It'd still look a little off, but probably only if closely examining it during a game. Not to say that such a level of observation doesn't happen during a game - it does, but for regular gameplay, these tricks would work to some level.

Share this post


Link to post
Share on other sites

whoa, are we seriously trying to figure out how to animate a coil spring?  Make an 8 or 12 sided cylinder, slap an alpha spring texture on it, duplicate and invert the cylinder, weigh the bottom of the spring to the "damper", call it a day and go have a beer at the bar.

 

Also, name your wheel, steering and suspension components just like BIS has it.  I've changed the names on a truck in ArmA2 and the suspension didn't work right despite doing everything possible to make it work.  EVERYTHING, including the adjust the names in the model.cfg.  I finally gave up and changed all of the names in the model and model config and it worked.  It appears the names bis use are some how unique.

 

Also the reference is wrong, first number is what side the wheel is on, the second is the placement of the wheel, hence wheel_1_4.

 

And defiantly use the sample models.  I'm in a real pickle now with the truck I have importing it into ArmA3 :(

  • Like 1

Share this post


Link to post
Share on other sites

whoa, are we seriously trying to figure out how to animate a coil spring?  Make an 8 or 12 sided cylinder, slap an alpha spring texture on it, duplicate and invert the cylinder, weigh the bottom of the spring to the "damper", call it a day and go have a beer at the bar.

 

Also, name your wheel, steering and suspension components just like BIS has it.  I've changed the names on a truck in ArmA2 and the suspension didn't work right despite doing everything possible to make it work.  EVERYTHING, including the adjust the names in the model.cfg.  I finally gave up and changed all of the names in the model and model config and it worked.  It appears the names bis use are some how unique.

 

Also the reference is wrong, first number is what side the wheel is on, the second is the placement of the wheel, hence wheel_1_4.

 

And defiantly use the sample models.  I'm in a real pickle now with the truck I have importing it into ArmA3 :(

There's more than simple spring weighting being discussed. I'm sure we've got that figured out. One other member said that with a fully modeled spring you'd still have an unnatural squishing look, but I don't think that's true if you weight the vertices within a ring group the same. Example: if your coil had 24 sections, and was made from a 6-sided cylinder, then 6 vertices would be the same, and 25 groups of vertices would have weight assignments that gradually shift favor from the body to the damper_land. This would be handy if you had a spring that was larger than life, and would look just wrong as a cylinder. The original point of this thread was supposed to be how to use the spring weight trick combined with other suspension parts, that are not weighted but still move via skeletal system (or IK or advanced scripting). Whatever it takes, I'm sure it can be done. "So do it," said someone to me, but that's like asking an armless man to mow your lawn - it can be done, but do you really want to wait that long? 

 

This is how I've set up the left front wheel, and others are the same, except _1_2 for left rear, _2_1 for right front, and _2_2 for right rear:

            "wheel_1_1_damper_land",    "", -- I have the actual wheel model named this

            "wheel_1_1_damper",    "wheel_1_1_damper_land", -- no model, but linked to the damper_land. What's the difference between damper and damper_land?

            "wheel_1_1_steering",    "wheel_1_1_damper", -- no model, linked to damper. Can a model piece go here if it exists?

            "wheel_1_1",    "wheel_1_1_steering", -- no model, linked to steering. One would think this is where the wheel model should actually go.

            "wheel_1_1_unhide",    "wheel_1_1", -- not sure what hide unhide do; I assume one is wheel & tire, the other is just wheel. So then maybe the actual model goes here?

            "wheel_1_1_hide",    "wheel_1_1", -- see above, both are linked to wheel.

 

I figured out the reference page has it backwards.

 

I used the sample model of the test_car, but then started to implement some physX parameters of the Offroad into my current car project.

Share this post


Link to post
Share on other sites

 

Also the reference is wrong, first number is what side the wheel is on

 

doesnt matter how you call it, as long as p3d, model.cfg and config all match together

  • Like 1

Share this post


Link to post
Share on other sites

There's no point in modeling an actual spring even if you weigh it correctly.  It sucks up a lot of polygons for a part on the vehicle that is hardly seen or looked at.  I'd rather spend those polygon on more visible objects that players will see the most.  Just my two cents.  I will tell you there's no point in trying to make a IK skeleton system for the suspension.  I know because I've tried with my HMMWV.  It's too complicated and complex and the effort you put into this can be better spent elsewhere.

 

"wheel_1_1_damper_land" I'm pretty sure is the land contact points (vertices) in the land contact lod

 

"wheel_1_1_damper"  inherits the movement from the land contact points.  This section of your model is what you would consider the moving suspension parts, which are weighed from 0 - 100.  This is a "translation y" (I think it's y) animation, meaning it moves up and down.  The weighing makes the model parts morph.  There's no actual way to animate realistic suspension components in ArmA.

 

Also another note about dampers is solid axles are weigh with both dampers.  i.e. a rear axle will have one side weighed "wheel_1_2_damper" and the other side "wheel_2_2_damper".  You will have the adjust the weighs to make it look right in ArmA.  I say that to say this because I'm sure you'll get to this point, this makes properly animating a spinning drive shaft next to impossible, so don't waste time on trying to properly animate a drive shaft.  I can go more into this later if you'd like.  Half shafts for independent suspension can be animated properly but you'll have to set up bones for them in the model.cfg because half shafts are usually angled down.

 

"wheel_1_1_steering" is the steering hub, inheriting the movement of the dampers.  This is a "rotational" animation with an axis usually defined by two points in the memory lod.  If the wheel doesn't have a steering hub then damper goes straight to wheel.  Or something like that.

 

"wheel_1_1" is the wheel itself, inheriting the movement of the steering or the damper if the wheel doesn't have steering.  This animation is a "rotational" animation with an axis usually defined by the rotation type in the model.cfg, however depending on how you model your wheel you may need to set up memory points.  Depending on how you want to model the damage for the wheel the "wheel_1_1" could be or could not be represented by a 3d model in the visual LODs.

 

"wheel_1_1_unhide" inheriting the movement of "wheel_1_1" is the damaged parts of the wheel, like a shredded tire, that becomes visible once the vehicle is completely destroyed.  Sometimes this could be a proxy (I could be wrong on this, don't quote me)

 

"wheel_1_1_hide" inheriting the movement of "wheel_1_1" is opposite of "wheel_1_1_unhide".  These parts of the wheel disappear once the vehicle is destroyed, like a tire.  (I could be wrong on this, don't quote me)

 

The biggest thing to take away from this is each section has it's own special animation.  For example for the front wheels it's only animation is spinning.  It, by itself, does not turn or go up and down with the suspension.  Rather, it inherits the animation from the other wheel components.  This is why the skeleton bones are set up the way they are.

 

Take this with a grain of salt.  I've been modeling since OFP.  Unless you have a wild hair to experiment there's no point in trying to make the game engine do something it wasn't designed for.  This suspension system is not "2015 new video game technology"  The animations have been like this since ofp.  The reason why there's no point is because experimenting is not developing an addon, rather experimenting is simply experimenting.  It takes a lot of time, effort and patience. 

 

If you want to make an addon, don't experiment.  If you want to experiment, don't intend on making an addon.  They are two separate goals.  In my honest opinion, the point where you confuse the two is the point where you become lost in the development which takes a heavy motivational toll on your desire to reach your goal.  This is why the HMMWVs I released for ArmA2 don't have animated suspension.  I also don't think the HMMWVs in RHS has animated suspension neither, which I probably ought to fix.

 

But again, this is just my two cents.  Take it with a grain of salt.

  • Like 1

Share this post


Link to post
Share on other sites

This is why the HMMWVs I released for ArmA2 don't have animated suspension.  I also don't think the HMMWVs in RHS has animated suspension neither, which I probably ought to fix.

Kinda blows, huh? Alright... pooh. I foresee an issue with solid axle when you need the gear compartment modeled. would all those vertices in that part be weighted 50/50 (assuming it's in the very center)? I think the center is weighted to the root (i.e: not really weighted) in the A3 ground transports, which is why it looks so awful.

Share this post


Link to post
Share on other sites

I don't know if the differential has to have 50% strength for each section, but the weight needs to be the same for both sections afaik.  To be honest I tested the weighing out in game but I guess you could test the weighing in buldozer by animating the parts with the mouse wheel.

Share this post


Link to post
Share on other sites

I will tell you there's no point in trying to make a IK skeleton system for the suspension.  I know because I've tried with my HMMWV.  It's too complicated and complex and the effort you put into this can be better spent elsewhere.

 

...

The biggest thing to take away from this is each section has it's own special animation.  For example for the front wheels it's only animation is spinning.  It, by itself, does not turn or go up and down with the suspension.  Rather, it inherits the animation from the other wheel components.  This is why the skeleton bones are set up the way they are.

 

...

 

The reason why there's no point is because experimenting is not developing an addon, rather experimenting is simply experimenting.  It takes a lot of time, effort and patience. 

 

If you want to make an addon, don't experiment.  If you want to experiment, don't intend on making an addon.  They are two separate goals.  In my honest opinion, the point where you confuse the two is the point where you become lost in the development which takes a heavy motivational toll on your desire to reach your goal.

 

But again, this is just my two cents.  Take it with a grain of salt.

I wanted to revisit this before it becomes outdated and gets closed. It's still on my mind, but it has been on a back burner. First, I agree with your two cents on confusing experimenting and addon making; it truly can take its toll on your motivation. Often, though, this comes more in the form of other modders's opinions who would railroad people into developing only strictly into the confines of the established game.

More importantly, however, I wanted to ask you if you ever tried using proxies for your suspensions? I realize it's an experiment, but it is one that already sort of works. Since a character's proxy can follow a memory point within the confines of its own skeleton (e.g.: holding the steering wheel or pilot stick), why not make a "character," with IK bones (or whatever more advanced bones characters use compared to vehicles), of your suspension and attach it to the model separately? The only roadblock I can see with this is: would the suspension require a crew spot for it to work?

IF such an experiment works, then it'll surely make more unique and more visually appealing addons. Look a the Apache chopper those guys made, which has an interactive dashboard and pilot-controllable turret with IHAADS. I imagine there was some serious experimenting there, but it paid off.

I think if we didn't experiment, then we'd still all be playing pong - or worse: pinball.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×