Fix #2300 (mostly,karts get stuck there atm, but can't drive through the door).
This commit is contained in:
parent
b7837fd05c
commit
fc67252e78
@ -496,6 +496,11 @@ void PhysicalObject::init()
|
|||||||
btVector3 inertia(1,1,1);
|
btVector3 inertia(1,1,1);
|
||||||
if (m_body_type != MP_EXACT)
|
if (m_body_type != MP_EXACT)
|
||||||
m_shape->calculateLocalInertia(m_mass, inertia);
|
m_shape->calculateLocalInertia(m_mass, inertia);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (m_mass == 0)
|
||||||
|
inertia.setValue(0, 0, 0);
|
||||||
|
}
|
||||||
btRigidBody::btRigidBodyConstructionInfo info(m_mass, m_motion_state,
|
btRigidBody::btRigidBodyConstructionInfo info(m_mass, m_motion_state,
|
||||||
m_shape, inertia);
|
m_shape, inertia);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user