From 444810c5989327efb41b35aa01861fa3b5cb6d58 Mon Sep 17 00:00:00 2001 From: badlogic Date: Sat, 5 Dec 2020 10:06:08 +0100 Subject: [PATCH] [lua] Fixed #1820 - Port of TransformMode.noRotationOrReflection was incorrect. - AnimationState.applyAttachmentTimeline was passed incorrect arguments. --- spine-lua/AnimationState.lua | 2 +- spine-lua/Bone.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/spine-lua/AnimationState.lua b/spine-lua/AnimationState.lua index fc7a92a4e..15df3437f 100644 --- a/spine-lua/AnimationState.lua +++ b/spine-lua/AnimationState.lua @@ -381,7 +381,7 @@ function AnimationState:apply (skeleton) self:applyRotateTimeline(timeline, skeleton, animationTime, mix, timelineBlend, timelinesRotation, ii * 2, firstFrame) elseif timeline.type == Animation.TimelineType.attachment then - self:applyAttachmentTimeline(skeleton, animationTime, timelineBlend, true) + self:applyAttachmentTimeline(timeline, skeleton, animationTime, timelineBlend, true) else timeline:apply(skeleton, animationLast, animationTime, self.events, mix, timelineBlend, MixDirection._in) end diff --git a/spine-lua/Bone.lua b/spine-lua/Bone.lua index 14076df80..6d72bfa48 100644 --- a/spine-lua/Bone.lua +++ b/spine-lua/Bone.lua @@ -164,7 +164,7 @@ function Bone:updateWorldTransformWith (x, y, rotation, scaleX, scaleY, shearX, self.b = pa * lb - pb * ld self.c = pc * la + pd * lc self.d = pc * lb + pd * ld - return + elseif transformMode == TransformMode.noScale or transformMode == TransformMode.noScaleOrReflection then local cos = math_cos(math_rad(rotation)) local sin = math_sin(math_rad(rotation))