Sfoglia il codice sorgente

Fixed Skeleton#setAttachment.

closes #215
NathanSweet 11 anni fa
parent
commit
cc89e1a3a6
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  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);