mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 09:28:46 +02:00
try another way of fixing held object snagging at slow velocity
This commit is contained in:
parent
742e48b0c8
commit
fbe3cb9511
1 changed files with 4 additions and 0 deletions
|
@ -256,6 +256,10 @@ bool EntityMotionState::remoteSimulationOutOfSync(uint32_t simulationStep) {
|
||||||
_serverPosition = bulletToGLM(xform.getOrigin());
|
_serverPosition = bulletToGLM(xform.getOrigin());
|
||||||
_serverRotation = bulletToGLM(xform.getRotation());
|
_serverRotation = bulletToGLM(xform.getRotation());
|
||||||
_serverVelocity = getBodyLinearVelocity();
|
_serverVelocity = getBodyLinearVelocity();
|
||||||
|
if (glm::length2(_serverVelocity) < MIN_LINEAR_SPEED_SQUARED) {
|
||||||
|
_serverVelocity *= 0.0f;
|
||||||
|
}
|
||||||
|
|
||||||
_serverAngularVelocity = bulletToGLM(_body->getAngularVelocity());
|
_serverAngularVelocity = bulletToGLM(_body->getAngularVelocity());
|
||||||
_lastStep = simulationStep;
|
_lastStep = simulationStep;
|
||||||
_serverActionData = _entity->getActionData();
|
_serverActionData = _entity->getActionData();
|
||||||
|
|
Loading…
Reference in a new issue