mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
skip transmitting server authorative wheel spin
it's not in itself a force-injection, so we can just use the existing calcs (also. fix the exisitng calcs so slippling is properly cleared) in addition, rigidshaeps shouldn't be trying to resolve collisions with things mounted to them any more than they should self-collide. it's a hard-locked relational association
This commit is contained in:
parent
2af8bf25d5
commit
5ea10f1cfc
2 changed files with 24 additions and 16 deletions
|
|
@ -1253,6 +1253,9 @@ bool RigidShape::updateCollision(F32 dt)
|
|||
mRigid.getTransform(&mat);
|
||||
cmat = mConvex.getTransform();
|
||||
|
||||
SceneObject* mounted;
|
||||
for (mounted = getMountList(); mounted; mounted = mounted->getMountLink())
|
||||
mounted->disableCollision();
|
||||
mCollisionList.clear();
|
||||
CollisionState *state = mConvex.findClosestState(cmat, getScale(), mDataBlock->collisionTol);
|
||||
if (state && state->mDist <= mDataBlock->collisionTol)
|
||||
|
|
@ -1260,9 +1263,12 @@ bool RigidShape::updateCollision(F32 dt)
|
|||
//resolveDisplacement(ns,state,dt);
|
||||
mConvex.getCollisionInfo(cmat, getScale(), &mCollisionList, mDataBlock->collisionTol);
|
||||
}
|
||||
|
||||
// Resolve collisions
|
||||
bool collided = resolveCollision(mRigid,mCollisionList, dt);
|
||||
|
||||
for (mounted = getMountList(); mounted; mounted = mounted->getMountLink())
|
||||
mounted->enableCollision();
|
||||
|
||||
return collided;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue