Created
November 9, 2011 09:20
-
-
Save cellfusion/1350941 to your computer and use it in GitHub Desktop.
duplicate MovieClip JSFL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
num = 48 | |
path = fl.getDocumentDOM().library.getItemProperty("name"); | |
path_array = path.split("/"); | |
name = path_array[path_array.length - 1]; | |
linkageBaseClass = fl.getDocumentDOM().library.getItemProperty("linkageBaseClass"); | |
linkageExportForAS = fl.getDocumentDOM().library.getItemProperty("linkageExportForAS"); | |
linkageExportInFirstFrame = fl.getDocumentDOM().library.getItemProperty("linkageExportInFirstFrame"); | |
for (i = 1; i < num; i++) { | |
fl.getDocumentDOM().library.duplicateItem(path); | |
} | |
var items = fl.getDocumentDOM().library.getSelectedItems(); | |
for (i = 0; i < items.length; i++) { | |
items[i].name = name+(i+2); | |
items[i].linkageExportForAS = linkageExportForAS; | |
items[i].linkageExportInFirstFrame = linkageExportInFirstFrame; | |
items[i].linkageBaseClass = linkageBaseClass; | |
} | |
fl.getDocumentDOM().library.selectNone(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
選択してる MovieClip の基本クラスとかそのまま複製できる JSFL