Hallo,
In this AS2 example, there's two mp3 files with linkage names "annoying-mosquito" and "fly-swatter."
I play the 1st mp3:
SND = new Sound([_target]);
SND.attachSound("annoying-mosquito");
SND.start();
Then I play the 2nd mp3:
SND.attachSound("fly-swatter");
SND.start();
Both the 1st mp3 & the 2nd mp3 are attached to the same variable SND with (seemingly) no ill effect.
Question: do I need to clear the contents of the variable SND before the 2nd attachSound?
Or is Flash doing that for me?
- - - - -
I've concluded this AS2 code is safe.
Flash loads the sound into memory and knows what to do with it.
SND is only a pointer to that sound in memory and can be set to other sounds as needed.


Reply With Quote

Bookmarks