@@ -447,9 +447,13 @@ void RigidBody::OnActiveTransformChanged()
|
||||
// Change actor transform (but with locking)
|
||||
ASSERT(!_isUpdatingTransform);
|
||||
_isUpdatingTransform = true;
|
||||
Transform transform;
|
||||
Transform transform = _transform;
|
||||
PhysicsBackend::GetRigidActorPose(_actor, transform.Translation, transform.Orientation);
|
||||
transform.Scale = _transform.Scale;
|
||||
if (transform.Translation.IsNanOrInfinity() || transform.Orientation.IsNanOrInfinity())
|
||||
{
|
||||
LOG(Error, "GetRigidActorPose retuned NaN/Inf transformation");
|
||||
transform = _transform;
|
||||
}
|
||||
if (_parent)
|
||||
{
|
||||
_parent->GetTransform().WorldToLocal(transform, _localTransform);
|
||||
|
||||
Reference in New Issue
Block a user