mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-19 08:16:41 +08:00
[unity] Minor refactoring: renamed a preprocessor constant.
This commit is contained in:
parent
69460f3bd6
commit
e11dea1497
@ -30,7 +30,7 @@
|
||||
// Contributed by: Mitch Thompson
|
||||
|
||||
#if UNITY_2019_2 || UNITY_2019_3 || UNITY_2019_4 || UNITY_2020_1 || UNITY_2020_2 // note: 2020.3+ uses old bahavior again
|
||||
#define HINGE_JOINT_NEW_BEHAVIOUR
|
||||
#define HINGE_JOINT_2019_BEHAVIOUR
|
||||
#endif
|
||||
|
||||
using System.Collections;
|
||||
@ -174,7 +174,7 @@ namespace Spine.Unity.Examples {
|
||||
|
||||
joint.GetComponent<Rigidbody2D>().mass = joint.connectedBody.mass * massFalloffFactor;
|
||||
|
||||
#if HINGE_JOINT_NEW_BEHAVIOUR
|
||||
#if HINGE_JOINT_2019_BEHAVIOUR
|
||||
float referenceAngle = (rbParent.transform.eulerAngles.z - t.eulerAngles.z + 360f) % 360f;
|
||||
float minAngle = referenceAngle - rotationLimit;
|
||||
float maxAngle = referenceAngle + rotationLimit;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user