mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-20 17:26:01 +08:00
[ts] Fixed yDown branch of previous commit 89441ca leading to upward gravity. See #2729.
This commit is contained in:
parent
095a5d43e4
commit
2d6c5381e9
@ -163,7 +163,7 @@ export class PhysicsConstraint implements Updatable {
|
||||
}
|
||||
if (a >= t) {
|
||||
d = Math.pow(this.damping, 60 * t);
|
||||
const m = this.massInverse * t, e = this.strength, w = this.wind * f * skeleton.scaleX, g = (Skeleton.yDown ? -this.gravity : this.gravity) * f * skeleton.scaleY;
|
||||
const m = this.massInverse * t, e = this.strength, w = this.wind * f * skeleton.scaleX, g = this.gravity * f * skeleton.scaleY;
|
||||
do {
|
||||
if (x) {
|
||||
this.xVelocity += (w - this.xOffset * e) * m;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user