Skip to content

Commit 06d5d32

Browse files
committed
[unity] Fixed one more compile error on older Unity versions introduced in last commit 1af0805. See #3013.
1 parent da7d20c commit 06d5d32

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

spine-unity/Assets/Spine/Samples~/Spine Examples/Scripts/RaggedySpineboy.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,11 @@ IEnumerator WaitUntilStopped () {
109109

110110
float t = 0;
111111
while (t < 0.5f) {
112+
#if RIGIDBODY2D_USES_LINEAR_VELOCITY
112113
t = (ragdoll.RootRigidbody.linearVelocity.magnitude > 0.09f) ? 0 : t + Time.deltaTime;
114+
#else
115+
t = (ragdoll.RootRigidbody.velocity.magnitude > 0.09f) ? 0 : t + Time.deltaTime;
116+
#endif
113117
yield return null;
114118
}
115119

0 commit comments

Comments
 (0)