[cpp][godot] Closes #2524, physics constraint update didn't take into account yDown properly

This commit is contained in:
Mario Zechner 2024-05-14 10:59:49 +02:00
parent 4183a58100
commit ab2de2babd

View File

@ -400,7 +400,7 @@ void PhysicsConstraint::update(Physics physics) {
a = _remaining;
if (a >= t) {
if (d == -1) d = MathUtil::pow(_damping, 60 * t);
float m = _massInverse * t, e = _strength, w = _wind, g = _gravity, h = l / f;
float m = _massInverse * t, e = _strength, w = _wind, g = _gravity * (Bone::yDown ? -1 : 1), h = l / f;
while (true) {
a -= t;
if (scaleX) {