[csharp] Port fix of additive scale mixing. See #2028, see commit a5b6762.

This commit is contained in:
Harald Csaszar 2022-01-26 15:24:39 +01:00
parent 4cbae2411a
commit f5f91899f4

View File

@ -773,8 +773,8 @@ namespace Spine {
bone.scaleY = by + (Math.Abs(y) * Math.Sign(by) - by) * alpha;
break;
case MixBlend.Add:
bone.scaleX = (x - bone.data.scaleX) * alpha;
bone.scaleY = (y - bone.data.scaleY) * alpha;
bone.scaleX += (x - bone.data.scaleX) * alpha;
bone.scaleY += (y - bone.data.scaleY) * alpha;
break;
}
} else {
@ -856,7 +856,7 @@ namespace Spine {
bone.scaleX = bx + (Math.Abs(x) * Math.Sign(bx) - bx) * alpha;
break;
case MixBlend.Add:
bone.scaleX = (x - bone.data.scaleX) * alpha;
bone.scaleX += (x - bone.data.scaleX) * alpha;
break;
}
} else {
@ -933,7 +933,7 @@ namespace Spine {
bone.scaleY = by + (Math.Abs(y) * Math.Sign(by) - by) * alpha;
break;
case MixBlend.Add:
bone.scaleY = (y - bone.data.scaleY) * alpha;
bone.scaleY += (y - bone.data.scaleY) * alpha;
break;
}
} else {