[ts] Port of commit ccc5b2f: Fixed root bone transform for skeleton. See #1379.

This commit is contained in:
badlogic 2019-06-13 16:03:16 +02:00
parent 79fea3722b
commit 6090d84a5e
6 changed files with 12 additions and 12 deletions

View File

@ -2428,8 +2428,8 @@ var spine;
var sx = skeleton.scaleX; var sx = skeleton.scaleX;
var sy = skeleton.scaleY; var sy = skeleton.scaleY;
this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx; this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx;
this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sy; this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sx;
this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sx; this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sy;
this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy; this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy;
this.worldX = x * sx + skeleton.x; this.worldX = x * sx + skeleton.x;
this.worldY = y * sy + skeleton.y; this.worldY = y * sy + skeleton.y;

View File

@ -2428,8 +2428,8 @@ var spine;
var sx = skeleton.scaleX; var sx = skeleton.scaleX;
var sy = skeleton.scaleY; var sy = skeleton.scaleY;
this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx; this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx;
this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sy; this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sx;
this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sx; this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sy;
this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy; this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy;
this.worldX = x * sx + skeleton.x; this.worldX = x * sx + skeleton.x;
this.worldY = y * sy + skeleton.y; this.worldY = y * sy + skeleton.y;

View File

@ -2428,8 +2428,8 @@ var spine;
var sx = skeleton.scaleX; var sx = skeleton.scaleX;
var sy = skeleton.scaleY; var sy = skeleton.scaleY;
this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx; this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx;
this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sy; this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sx;
this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sx; this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sy;
this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy; this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy;
this.worldX = x * sx + skeleton.x; this.worldX = x * sx + skeleton.x;
this.worldY = y * sy + skeleton.y; this.worldY = y * sy + skeleton.y;

View File

@ -2428,8 +2428,8 @@ var spine;
var sx = skeleton.scaleX; var sx = skeleton.scaleX;
var sy = skeleton.scaleY; var sy = skeleton.scaleY;
this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx; this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx;
this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sy; this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sx;
this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sx; this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sy;
this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy; this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy;
this.worldX = x * sx + skeleton.x; this.worldX = x * sx + skeleton.x;
this.worldY = y * sy + skeleton.y; this.worldY = y * sy + skeleton.y;

View File

@ -2428,8 +2428,8 @@ var spine;
var sx = skeleton.scaleX; var sx = skeleton.scaleX;
var sy = skeleton.scaleY; var sy = skeleton.scaleY;
this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx; this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx;
this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sy; this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sx;
this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sx; this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sy;
this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy; this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy;
this.worldX = x * sx + skeleton.x; this.worldX = x * sx + skeleton.x;
this.worldY = y * sy + skeleton.y; this.worldY = y * sy + skeleton.y;

View File

@ -2428,8 +2428,8 @@ var spine;
var sx = skeleton.scaleX; var sx = skeleton.scaleX;
var sy = skeleton.scaleY; var sy = skeleton.scaleY;
this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx; this.a = spine.MathUtils.cosDeg(rotation + shearX) * scaleX * sx;
this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sy; this.b = spine.MathUtils.cosDeg(rotationY) * scaleY * sx;
this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sx; this.c = spine.MathUtils.sinDeg(rotation + shearX) * scaleX * sy;
this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy; this.d = spine.MathUtils.sinDeg(rotationY) * scaleY * sy;
this.worldX = x * sx + skeleton.x; this.worldX = x * sx + skeleton.x;
this.worldY = y * sy + skeleton.y; this.worldY = y * sy + skeleton.y;