From 63f20379db690d793eb57300f236c3ae6fd142d6 Mon Sep 17 00:00:00 2001 From: NathanSweet Date: Thu, 5 Dec 2013 14:52:34 +0100 Subject: [PATCH] Better root flipY logic. --- spine-c/src/spine/Bone.c | 2 +- spine-csharp/src/Bone.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/spine-c/src/spine/Bone.c b/spine-c/src/spine/Bone.c index 41c9f42b7..61eda1088 100644 --- a/spine-c/src/spine/Bone.c +++ b/spine-c/src/spine/Bone.c @@ -76,7 +76,7 @@ void spBone_updateWorldTransform (spBone* self, int flipX, int flipY) { self->data->inheritRotation ? self->parent->worldRotation + self->rotation : self->rotation; } else { CONST_CAST(float, self->worldX) = flipX ? -self->x : self->x; - CONST_CAST(float, self->worldY) = (flipY != yDown) ? -self->y : self->y; + CONST_CAST(float, self->worldY) = (flipY && flipY != yDown) ? -self->y : self->y; CONST_CAST(float, self->worldScaleX) = self->scaleX; CONST_CAST(float, self->worldScaleY) = self->scaleY; CONST_CAST(float, self->worldRotation) = self->rotation; diff --git a/spine-csharp/src/Bone.cs b/spine-csharp/src/Bone.cs index 926499dae..cf1eccd54 100644 --- a/spine-csharp/src/Bone.cs +++ b/spine-csharp/src/Bone.cs @@ -85,7 +85,7 @@ namespace Spine { worldRotation = data.inheritRotation ? parent.worldRotation + rotation : rotation; } else { worldX = flipX ? -x : x; - worldY = (flipY != yDown) ? -y : y; + worldY = (flipY && flipY != yDown) ? -y : y; worldScaleX = scaleX; worldScaleY = scaleY; worldRotation = rotation;