I am having an issue with the stopSound method not functioning for me. I have a theme song playing in the background via media.newEventSound
This track is about 15 seconds long, i have some buttons and i want when the button is pressed to stop the sound, fade the screen out and load a new screen. I have created this listener method but for some reason the stopSound method just doesnt seem to work no matter what I do. Any ideas? Thanks!
local sound_theme = media.newEventSound(“themeSong.caf”);
local sound_selection = media.newEventSound(“selection.caf”);
local listenerContinue = function(event)
– buttonContinueRolled:removeEventListener(“touch”, listenerContinue);
media.stopSound();
timer.cancel( playBubbleSound )
timer.cancel( playSlowTheme )
media.playEventSound(sound_selection);
– local rect = display.newRect( 0, 0, 768, 1024 )
– rect:setFillColor(0,0,0)
– transition.to( rect, {time=2000, alpha=1.0} )
end [import]uid: 6317 topic_id: 892 reply_id: 300892[/import]