Does any one have this problem with the bonnet (or the perceived part of the cuboid as the bonnet) not rising under acceleratio instead it dips and likewise when braking, it rises.
I took the vehicle demo and only changed the following 3 paramters
mass to 80.f
engine force to 3000.f
Softened the suspension to 10.f
This exagerates the effects.
Also when turning left, you would expect the car to lean (rolls) to its right, instead it performs like a motor-bike and it leans to its left!
Regards
Man
vehicle demo bonnet should rise under acceleration not dip
-
- Posts: 3
- Joined: Mon Oct 05, 2009 12:55 pm
-
- Posts: 169
- Joined: Sun Jan 14, 2007 7:56 pm
- Location: Norway
Re: vehicle demo bonnet should rise under acceleration not dip
Sounds like the centre of gravity is below the ground, to keep the vehicle from tipping over too often. Take a look at line 310/320 in VehicleDemo.cpp. Adjust the centre of gravity higher (like, zero) and you'll probably get the behaviour you're looking for.
Cheers,
Ola
Cheers,
Ola
-
- Posts: 3
- Joined: Mon Oct 05, 2009 12:55 pm
Re: vehicle demo bonnet should rise under acceleration not dip
Thanks ola.
I have tried to set them to localTransform.setOrigin(btVector(0,1.5,0)) and even higher, it had the effect of car chasis being visually rendered higher but made no differences to the dip/rise and leaning behaviours.
Usually to simulate this dipping and rise, I would expect that under acceleration, the wheels move as result of engine force applied to it, the chasis would be slightly behind the wheel (as the chasis technically is stationary) and hence the center of mass would shift towards the rear end which shud squash the rear suspension hence giving the nose rise effect and under braking, the wheels slows down fast but chasis still going at prev speed and center of mass temporarily shifts forwrds, hence nose dip.
So, this shud mean center of gravity height should only affect its leaning behaviour ( higher center gravity will give more pronounced roll and easier to totally roll over as it has greater chance of its line of gravity going over its right wheels contact point etc).
Regards
Man
I have tried to set them to localTransform.setOrigin(btVector(0,1.5,0)) and even higher, it had the effect of car chasis being visually rendered higher but made no differences to the dip/rise and leaning behaviours.
Usually to simulate this dipping and rise, I would expect that under acceleration, the wheels move as result of engine force applied to it, the chasis would be slightly behind the wheel (as the chasis technically is stationary) and hence the center of mass would shift towards the rear end which shud squash the rear suspension hence giving the nose rise effect and under braking, the wheels slows down fast but chasis still going at prev speed and center of mass temporarily shifts forwrds, hence nose dip.
So, this shud mean center of gravity height should only affect its leaning behaviour ( higher center gravity will give more pronounced roll and easier to totally roll over as it has greater chance of its line of gravity going over its right wheels contact point etc).
Regards
Man
-
- Posts: 169
- Joined: Sun Jan 14, 2007 7:56 pm
- Location: Norway
Re: vehicle demo bonnet should rise under acceleration not dip
I forgot that you must translate the chassis as well. So if you set the translation to zero (subtracting 1 meter) like I suggested, try subtracting 1 from connectionHeight at line 345 as well (it'll then be 0.2). I just tried it and then the vehicle bobs forward when braking etc.
Cheers,
Ola
Cheers,
Ola
-
- Posts: 3
- Joined: Mon Oct 05, 2009 12:55 pm
Re: vehicle demo bonnet should rise under acceleration not dip
Thx Ola
That is much better.
Obviously I need to understand a bit more about this. Having fun with the experiementation.
Thx again.
Man
That is much better.
Obviously I need to understand a bit more about this. Having fun with the experiementation.
Thx again.
Man