fix bug that was introducing a local velocity to an entity when it was parented to a moving avatar

This commit is contained in:
Seth Alves 2019-01-15 11:36:08 -08:00 committed by Andrew Meadows
parent d64858b1c7
commit 2bf7ac2745

View file

@ -3833,22 +3833,22 @@ void EntityItemProperties::copySimulationRestrictedProperties(const EntityItemPo
setParentJointIndex(entity->getParentJointIndex());
}
if (!_localPositionChanged && !_positionChanged) {
setPosition(entity->getWorldPosition());
setLocalPosition(entity->getLocalPosition());
}
if (!_localRotationChanged && !_rotationChanged) {
setRotation(entity->getWorldOrientation());
setLocalRotation(entity->getLocalOrientation());
}
if (!_localVelocityChanged && !_velocityChanged) {
setVelocity(entity->getWorldVelocity());
setLocalVelocity(entity->getLocalVelocity());
}
if (!_localAngularVelocityChanged && !_angularVelocityChanged) {
setAngularVelocity(entity->getWorldAngularVelocity());
setLocalAngularVelocity(entity->getLocalAngularVelocity());
}
if (!_accelerationChanged) {
setAcceleration(entity->getAcceleration());
}
if (!_localDimensionsChanged && !_dimensionsChanged) {
setDimensions(entity->getScaledDimensions());
setLocalDimensions(entity->getUnscaledDimensions());
}
}