瀏覽代碼

fixed skeletons setAttachment using getAttachment

getAttachment does not exist, now uses getAttachmentBySlotIndex
smaren 11 年之前
父節點
當前提交
9e2c588734
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      spine-js/spine.js

+ 1 - 1
spine-js/spine.js

@@ -776,7 +776,7 @@ spine.Skeleton.prototype = {
 			if (slot.data.name == slotName) {
 				var attachment = null;
 				if (attachmentName) {
-					attachment = this.getAttachment(i, attachmentName);
+					attachment = this.getAttachmentBySlotIndex(i, attachmentName);
 					if (!attachment) throw "Attachment not found: " + attachmentName + ", for slot: " + slotName;
 				}
 				slot.setAttachment(attachment);