Iterate Through Library

—Question–

I am curious if there is a way to “iterate through the library.” Meaning, write a for loop that goes through each item in the library.

If there is such a thing, it would probably only include linked items, which is fine.

(I tried to Google around, unfortunately “library” is used in many places in normal coding life, outside of Flash’s library thingy, thus skewing Google’s results.)

–Reasoning–

The reason why I am asking is because I am trying to think of a way to build an audio manager. It would deal with many issues, one of which being the tedium of manually instantiating each Sound object in code. It would automatically create instances of each linked Sound object in the library. Without this, not only do I have to drag each of the 100+ sounds in the game in, create the linkage for each (which will take forever by itself), but I would have to instantiate all 100 of these sounds manually in code, then call upon them when I want them to be played.

Cheers,
Zoop

(As usual, Flash drives me to the edge of my sanity… and it isn’t because I am new to coding [15 years] or Flash. Just know it took me a lot of strength to stay calm in this message. :stuck_out_tongue: )