Latest Vehicle Changes: Feedback Wanted
by Tim Gift · in Torque Game Engine · 02/06/2003 (6:11 pm) · 23 replies
I've been checking in a few more changes over the past few days... the more useful are probably the ability to set the center of mass relative to the origin of the shape, as well as the ability to set which wheels are powered (the example buggy is now rear wheel drive).
Today I just checked in support for static & kinetic friction coefficients on the tires and I'm basically looking for feedback on all these changes. If anybody is playing with the wheeled vehicles, now is the time to speak up :)
Today I just checked in support for static & kinetic friction coefficients on the tires and I'm basically looking for feedback on all these changes. If anybody is playing with the wheeled vehicles, now is the time to speak up :)
#2
Tim, those changes are excellent ! So was your last ones too. This is becoming more and more exciting. Controling the center of mass will be gladly appreciated and the traction for the rear-front wheels also.
I'm not good with car setup but my brother will try to play with this tonight or tomorow. We'll give you more feedback as soon as he has roughly tested it.
Really nice work. Thanks !
Gilles Jr Lafrance
02/07/2003 (6:51 am)
waouhhh, wheely time ! I did the longest buggy wheely world record, heheTim, those changes are excellent ! So was your last ones too. This is becoming more and more exciting. Controling the center of mass will be gladly appreciated and the traction for the rear-front wheels also.
I'm not good with car setup but my brother will try to play with this tonight or tomorow. We'll give you more feedback as soon as he has roughly tested it.
Really nice work. Thanks !
Gilles Jr Lafrance
#3
02/07/2003 (7:12 am)
Heh I was just talking to a friend saying I wanted to play around with car physics this weekend. At least now I'll start further ahead of the game.
#4
What's the center of mass change for by the way? I don't get it.
02/07/2003 (7:50 am)
The Rear-Front traction option is great. That was a feature that was needed... as long as it acts realistically :)What's the center of mass change for by the way? I don't get it.
#5
02/07/2003 (7:54 am)
The center of mass should allow for realistic roll rates to be applied. The lower the center of gravity the harder it should be to flip or roll the vechicle. Plus I THINK placing it closer to he rear of the vechicle should make power slides easier to perform.
#6
AFAIK, previously, the centre of gravity (or mass) was based on the origin of the vehicle body model. Moving this into script would allow you to fine-tune it as you like without requiring you to export your DTS file again.
It's also great that the moment of inertia script setting has now made it into the Head. I can rip out my own implementation :o)
With these changes, I believe the only remaining feature that relies on the model's origin is the choice of which wheels will steer (wheel y position > 0).
I've been playing with these new changes and like what I see. Thanks Tim!
I've come across some collision issues that I'll elaborate on once I have some screen shots put together. They involve static DTS shapes with the car moving at a low rate of speed. Stay tuned!
- LightWave Dave
02/07/2003 (9:19 am)
Greetings!AFAIK, previously, the centre of gravity (or mass) was based on the origin of the vehicle body model. Moving this into script would allow you to fine-tune it as you like without requiring you to export your DTS file again.
It's also great that the moment of inertia script setting has now made it into the Head. I can rip out my own implementation :o)
With these changes, I believe the only remaining feature that relies on the model's origin is the choice of which wheels will steer (wheel y position > 0).
I've been playing with these new changes and like what I see. Thanks Tim!
I've come across some collision issues that I'll elaborate on once I have some screen shots put together. They involve static DTS shapes with the car moving at a low rate of speed. Stay tuned!
- LightWave Dave
#7
I just checked in the ability to set the steering on each wheel. You can set a -1 to 1 value where 1 is steer normal, and -1 is counter steer. The vehicle still defaults to front wheel steering, so if you don't want them to steer, you have to turn them off (set steering to 0).
02/07/2003 (10:23 am)
David, thanks for the moi script setting tip :) I ended up calling it something else, but I added it because I saw your post about it.I just checked in the ability to set the steering on each wheel. You can set a -1 to 1 value where 1 is steer normal, and -1 is counter steer. The vehicle still defaults to front wheel steering, so if you don't want them to steer, you have to turn them off (set steering to 0).
#8
02/07/2003 (11:17 am)
It would be nice to be able to set the center of gravity "visually" by placing a NULL ( yeah I use LW ) and giving it a "magic name" like "COG" or some such. That way you don't have to do any trial and error guessing what the numbers should be.
#9
02/07/2003 (11:28 am)
FYI, if you turn on the bounding box rendering ($GameBase::boundingBox=true) from the console, the center of mass is rendered as the small white box. You can then tweak the numbers in the script, re-exec the script, re-spawn the vehicle and see the new center of mass.
#10
02/07/2003 (11:32 am)
Wow Tim, that's another really great features ! Just tryed playing with the 4 wheels that steers. Really cool ! You're hungry today ! Way to go :)
#11
You can now in script write a function to allow your vehicle to change from Front, to rear to all wheel drive. (along with having only one powered wheel)
And (haven't checked if this was exposed in the scripting) Make your vehicle Front Steering, Rear Steering, all wheel steering, and choose if it follows the <-- = Wheel turns Left vs <--- = wheel turns right.
I'll have to write some scripts to change these via keybinds for testing.
02/07/2003 (11:37 am)
So if I've caught all the script changes right... (haven't had a chance to test with all the vehicle changes)You can now in script write a function to allow your vehicle to change from Front, to rear to all wheel drive. (along with having only one powered wheel)
And (haven't checked if this was exposed in the scripting) Make your vehicle Front Steering, Rear Steering, all wheel steering, and choose if it follows the <-- = Wheel turns Left vs <--- = wheel turns right.
I'll have to write some scripts to change these via keybinds for testing.
#12
Tim, I must say I like the steering changes. Here's the buggy with rear-wheel drive, and four-wheel steering:

Boy, does that thing corner!
- LightWave Dave
02/07/2003 (11:48 am)
Greetings!Tim, I must say I like the steering changes. Here's the buggy with rear-wheel drive, and four-wheel steering:

Boy, does that thing corner!
- LightWave Dave
#14
I think we should be worried, GM has a patent on this kind of thing. ;)
02/07/2003 (12:35 pm)
Cool, I gotta check this stuff out.I think we should be worried, GM has a patent on this kind of thing. ;)
#15
As promised, here's the collision issue that I've been having with the latest wheeled vehicle code. After trying out a number of different approaches, it looks like it may be related to wheel collisions not being as robust as they could be (as Tim mentioned in his News posting). So, for those that are interested, here we go!
What I've been attempting to build is a jump ramp for wheeled vehicles. There's no problem with building your basic wedge-shaped ramp, but what I'm after is a curved ramp. Eventually, I'd like to drive a vehicle around a loop.
So you know what I'm working with, here's what the ramp looks like, with visible polygon edges. The collision mesh is identical to this:
www.gnometech.com/torque/images/stuntramprender.jpg
A player has no problem running up this ramp (ie: colliding with it). However, in my previous discussions with Tim, he's stated that vehicle/wheel collisions are handled very differently.
When you slowly drive the buggy towards the ramp:
www.gnometech.com/torque/images/stuntramp01.jpg
the wheels continue to move along the plane of the terrain rather than move up the ramp. This causes the buggy to drive into, rather than up, the ramp.
When the vehicle body strikes the ramp, it lurches up momentarily as it seems to collide with the ramp:
www.gnometech.com/torque/images/stuntramp02.jpg
However, the forward momentum forces the buggy through the ramp, and you end up on the other side.
If you bring the buggy around to the back of the ramp, the body does collide with it. If you continue to push into the ramp, it is possible for it to raise up the back, but it again appears that it is only the buggy body and not the wheels that are colliding.
www.gnometech.com/torque/images/stuntramp03.jpg
So, there you have it. Tim, any thoughts on how to make this work? Or am I just approaching this wrong by having a concave ramp structure?
You may find the test jump ramp DTS file here: www.gnometech.com/torque/files/jumpramp.zip
- LightWave Dave
Edit:
As the issue has been resolved below, I changed all 'image' tags to 'url' so those with low bandwidth connections don't need to always view my pics when opening this thread.
02/07/2003 (1:54 pm)
Greetings!As promised, here's the collision issue that I've been having with the latest wheeled vehicle code. After trying out a number of different approaches, it looks like it may be related to wheel collisions not being as robust as they could be (as Tim mentioned in his News posting). So, for those that are interested, here we go!
What I've been attempting to build is a jump ramp for wheeled vehicles. There's no problem with building your basic wedge-shaped ramp, but what I'm after is a curved ramp. Eventually, I'd like to drive a vehicle around a loop.
So you know what I'm working with, here's what the ramp looks like, with visible polygon edges. The collision mesh is identical to this:
www.gnometech.com/torque/images/stuntramprender.jpg
A player has no problem running up this ramp (ie: colliding with it). However, in my previous discussions with Tim, he's stated that vehicle/wheel collisions are handled very differently.
When you slowly drive the buggy towards the ramp:
www.gnometech.com/torque/images/stuntramp01.jpg
the wheels continue to move along the plane of the terrain rather than move up the ramp. This causes the buggy to drive into, rather than up, the ramp.
When the vehicle body strikes the ramp, it lurches up momentarily as it seems to collide with the ramp:
www.gnometech.com/torque/images/stuntramp02.jpg
However, the forward momentum forces the buggy through the ramp, and you end up on the other side.
If you bring the buggy around to the back of the ramp, the body does collide with it. If you continue to push into the ramp, it is possible for it to raise up the back, but it again appears that it is only the buggy body and not the wheels that are colliding.
www.gnometech.com/torque/images/stuntramp03.jpg
So, there you have it. Tim, any thoughts on how to make this work? Or am I just approaching this wrong by having a concave ramp structure?
You may find the test jump ramp DTS file here: www.gnometech.com/torque/files/jumpramp.zip
- LightWave Dave
Edit:
As the issue has been resolved below, I changed all 'image' tags to 'url' so those with low bandwidth connections don't need to always view my pics when opening this thread.
#16
02/07/2003 (2:22 pm)
The dts collision engine only supports convex shapes. If your ramp collision mesh is the same as the visible mesh, then it will not work correctly. You'll have to break it up into smaller convex regions... or build it with Quark or Worldcraft which does this automatically.
#19
And for those interested, set all wheels to not be powered by the engine and when you press the movement key the car will go into Neutral.
02/07/2003 (3:29 pm)
Very nice being able to change steering, and powered wheels on the fly.And for those interested, set all wheels to not be powered by the engine and when you press the movement key the car will go into Neutral.
#20
I know the rigid and vehicle files were changed, any others?
Thanks!
02/07/2003 (4:02 pm)
Hey, can anyone tell me what files were changed?I know the rigid and vehicle files were changed, any others?
Thanks!
Torque Owner Mike Stoddart