internal void Update(GodotRigidBody rigidbody) { Velocity.FromGodotVector3(_sceneRoot.ToLocal(rigidbody.LinearVelocity)); AngularVelocity.FromGodotVector3(_sceneRoot.ToLocal(rigidbody.AngularVelocity)); // No need to read Position or Rotation. They're write-only from the patch to the component. Mass = rigidbody.Mass; DetectCollisions = !rigidbody.GetChild <CollisionShape>()?.Disabled ?? false; CollisionDetectionMode = rigidbody.ContinuousCd switch { true => MRECollisionDetectionMode.Continuous, false => MRECollisionDetectionMode.Discrete }; UseGravity = !Mathf.IsZeroApprox(rigidbody.GravityScale); ConstraintFlags = rigidbody.GetMRERigidBodyConstraints(); }