[unity] Fixed one more compile error on older Unity versions introduced in last commit 1af0805. See #3013.

This commit is contained in:
Harald Csaszar 2026-01-23 22:28:21 +01:00
parent da7d20c4bc
commit 06d5d32a41

View File

@ -109,7 +109,11 @@ namespace Spine.Unity.Examples {
float t = 0; float t = 0;
while (t < 0.5f) { while (t < 0.5f) {
#if RIGIDBODY2D_USES_LINEAR_VELOCITY
t = (ragdoll.RootRigidbody.linearVelocity.magnitude > 0.09f) ? 0 : t + Time.deltaTime; t = (ragdoll.RootRigidbody.linearVelocity.magnitude > 0.09f) ? 0 : t + Time.deltaTime;
#else
t = (ragdoll.RootRigidbody.velocity.magnitude > 0.09f) ? 0 : t + Time.deltaTime;
#endif
yield return null; yield return null;
} }