Ver código fonte

[lua] Closes 1697, call to setAttachment in wrong location.

badlogic 5 anos atrás
pai
commit
6b4c7aeda3
1 arquivos alterados com 1 adições e 1 exclusões
  1. 1 1
      spine-lua/AnimationState.lua

+ 1 - 1
spine-lua/AnimationState.lua

@@ -520,8 +520,8 @@ function AnimationState:applyAttachmentTimeline(timeline, skeleton, time, blend,
 			frameIndex = zlen(frames) - 1;
 			frameIndex = zlen(frames) - 1;
 		else
 		else
 			frameIndex = Animation.binarySearch(frames, time, 1) - 1;
 			frameIndex = Animation.binarySearch(frames, time, 1) - 1;
-			self:setAttachment(skeleton, slot, timeline.attachmentNames[frameIndex], attachments)
 		end
 		end
+		self:setAttachment(skeleton, slot, timeline.attachmentNames[frameIndex], attachments)
 	end
 	end
 
 
 	-- If an attachment wasn't set (ie before the first frame or attachments is false), set the setup attachment later.
 	-- If an attachment wasn't set (ie before the first frame or attachments is false), set the setup attachment later.