mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-26 22:49:01 +08:00
[libgdx] Fixed physics constraint limit with negative skeleton scale.
ref #2576
This commit is contained in:
parent
cc55a2eeba
commit
112bea0603
@ -153,8 +153,8 @@ public class PhysicsConstraint implements Updatable {
|
|||||||
uy = by;
|
uy = by;
|
||||||
} else {
|
} else {
|
||||||
float a = remaining, i = inertia, t = data.step, f = skeleton.data.referenceScale, d = -1;
|
float a = remaining, i = inertia, t = data.step, f = skeleton.data.referenceScale, d = -1;
|
||||||
float qx = data.limit * delta, qy = qx * skeleton.scaleY;
|
float qx = data.limit * delta, qy = qx * Math.abs(skeleton.scaleY);
|
||||||
qx *= skeleton.scaleX;
|
qx *= Math.abs(skeleton.scaleX);
|
||||||
if (x || y) {
|
if (x || y) {
|
||||||
if (x) {
|
if (x) {
|
||||||
float u = (ux - bx) * i;
|
float u = (ux - bx) * i;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user