Hi,
I have 3 panoramas and each one has it's own xml file. They are viewable using the combobox and when the first one loads, it's the exterior of a helicopter and I have the sound exterior_running.mp3 playing on a loop. Also the sound on/off buttons are allocated the mp3.
<plugin name="soundinterface" url="plugins/soundinterface.swf" rootpath="audio" onloaded="preloadsound(exterior_running.mp3);playsound(mymusik,exterior_running.mp3,loops);" />
<plugin name="soundon" url="skin/sound.png" zorder="10" align="bottomright" edge="bottomright" x="185" y="4" onhover="showtext(AUDIO ON,buttonstyle);" onclick="playsound(mymusik,exterior_running.mp3,loops);" />
<plugin name="soundoff" url="skin/soundoff.png" zorder="10" align="bottomright" edge="bottomright" x="150" y="4" onhover="showtext(AUDIO OFF,buttonstyle);" ondown="stopsound(mymusik);" onclick="stopsound(mymusik);" />
Then when either of the others panoramas are chosen (both interior shots) from the combobox I have the following code in their xml files and the sound file interior_running.mp3 should be running.
<plugin name="soundinterface" url="plugins/soundinterface.swf" rootpath="audio" onloaded="preloadsound(interior_running.mp3);playsound(mymusik,interior_running.mp3,loops);" />
<plugin name="soundon" url="skin/sound.png" zorder="10" align="bottomright" edge="bottomright" x="185" y="4" onhover="showtext(AUDIO ON,buttonstyle);" onclick="playsound(mymusik,interior_running.mp3,loops);" />
<plugin name="soundoff" url="skin/soundoff.png" zorder="10" align="bottomright" edge="bottomright" x="150" y="4" onhover="showtext(AUDIO OFF,buttonstyle);" ondown="stopsound(mymusik);" onclick="stopsound(mymusik);" />
but the problem is even though the new pano has loaded, the sound hasn't changed unless I actually click on the sound on/off buttons to load the new mp3.
What I'd like to do is stop the current sound playing and then start the new one in the next panorama. Is that possible?
Look forward to any advice please.
Thanks,
Andrew
.