Hello,

I am trying to convert some drawings on stage into a movieclip via jsfl.
It works when all the elements on stage are separatly grouped. JSFL doesnt seem to 'see' non grouped drawings as seperate entities.

To clearify, I have on frame on the main timeline. In this frame I have three shapes that are grouped and two shapes that are just plain circles made of a stroke. So in total I have 5 entities on stage. The JSFL script below outputs just three times. Does anybody know how I can get all five shapes on stage via jsfl, no matter if the are grouped or just drawings? I want each item to be converted into a MovieClip.


var doc = fl.getDocumentDOM()
var tl = doc.getTimeline()
var layers = tl.layers;

tl.setSelectedLayers(0);

fl.outputPanel.clear();

for (var l=0; l<layers.length; l++) {

        var shapes = layers[l].frames[0].elements

        for (var k=0; k<shapes.length; k++) {
                
                doc.selectNone();
                
                var shape = shapes[k];
                
                shape.selected = true;
                
                fl.trace('selected = '+shape);

                shape.selected = false;

        }

}
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to