ecucurella
Programmer
Hi,
I use the loadsound method to load an mp3 file in the Sound object. Every time I made a scene change i load a song, one song related to every scene.
It is ok, but I have a memory problem because when i load a song the memory that Flash uses increase and if I return to an scene that i have been later it increase the memory another time !!
Is there a method to free the memory used when i don't need the song anymore?
Thanks,
This is the code i use:
var Introtrack = new Sound();
Introtrack.setVolume(100);
Introtrack.loadSound("\\songs\\intro.mp3", false);
Introtrack.start();
Introtrack.onSoundComplete = function () {
Introtrack.start();
}
I use the loadsound method to load an mp3 file in the Sound object. Every time I made a scene change i load a song, one song related to every scene.
It is ok, but I have a memory problem because when i load a song the memory that Flash uses increase and if I return to an scene that i have been later it increase the memory another time !!
Is there a method to free the memory used when i don't need the song anymore?
Thanks,
This is the code i use:
var Introtrack = new Sound();
Introtrack.setVolume(100);
Introtrack.loadSound("\\songs\\intro.mp3", false);
Introtrack.start();
Introtrack.onSoundComplete = function () {
Introtrack.start();
}