http://code.google.com/p/bullet/issues/detail?id=468
reproduced in official vehicle demo... only set center of mass in compound without shift and doubled the power (otherwise it doesn't rolls at all at normal speed, in demo the center of mass is very low) ... i don't see any influence of "roll influence" parameter, vehicle rolls over immediately with rolling influnce 0.1, with old code it doesn't....
math after fix: no effect if wheelInfo.m_rollInfluence is 0,
math before fix: no effect if wheelInfo.m_rollInfluence is 1, isn't it?
Code: Select all
#if defined ROLLING_INFLUENCE_FIX // fix. It only worked if car's up was along Y - VT.
btVector3 vChassisWorldUp = getRigidBody()->getCenterOfMassTransform().getBasis().getColumn(1);
rel_pos -= vChassisWorldUp * (vChassisWorldUp.dot(rel_pos) * wheelInfo.m_rollInfluence);
#else
rel_pos[m_indexUpAxis] *= wheelInfo.m_rollInfluence;
#endif