mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-19 20:24:49 +00:00
dial back overly agressive setRest
This commit is contained in:
parent
fb867a4a6c
commit
7552554ded
|
|
@ -1117,9 +1117,9 @@ void RigidShape::updatePos(F32 dt)
|
|||
if (mCollisionList.getCount())
|
||||
{
|
||||
F32 k = mRigid.getKineticEnergy();
|
||||
F32 G = mNetGravity;
|
||||
F32 G = mNetGravity* dt;
|
||||
F32 Kg = 0.5 * mRigid.mass * G * G;
|
||||
if (k < sRestTol * Kg* dt && ++restCount > sRestCount)
|
||||
if (k < sRestTol * Kg && ++restCount > sRestCount)
|
||||
mRigid.setAtRest();
|
||||
}
|
||||
else
|
||||
|
|
|
|||
|
|
@ -807,9 +807,9 @@ void Vehicle::updatePos(F32 dt)
|
|||
if (mCollisionList.getCount())
|
||||
{
|
||||
F32 k = mRigid.getKineticEnergy();
|
||||
F32 G = mNetGravity;
|
||||
F32 G = mNetGravity* dt;
|
||||
F32 Kg = 0.5 * mRigid.mass * G * G;
|
||||
if (k < sRestTol * Kg * dt && ++restCount > sRestCount)
|
||||
if (k < sRestTol * Kg && ++restCount > sRestCount)
|
||||
mRigid.setAtRest();
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in a new issue