fdmfdm

Not all sounds stopping if the app is closed and the same sound is playing more than once

Recommended Posts

hi there,

I'm pretty sure i found a bug where if you have the same sound running multiple times and you close the app, it does not stop all the sounds (only 1 i believe).

 

i would like to not though, that it does trigger a result when you try to play the same sound twice, but it will still play it 2 times at the same time. 

 

 

Share this post


Link to post
Share on other sites
function playresult(result)
{
	console.log("playresult");
	if(result.status != "success")
	{
		alert("playresult " + JSON.stringify(result));
	}
}

function playsound2(result)
{
	console.log("playsound2 " + result.id);
	overwolf.media.audio.play(result.id,playresult);
}

function playsound(songpath)
{
	overwolf.media.audio.create(songpath,playsound2);
}

where playsound is called 2 times for the same sound, and different moments in time.

Share this post


Link to post
Share on other sites

I can't send the logs right now, but the exact thing i do is:

 

i call in this order (through callbacks)
overwolf.media.audio.create
overwolf.media.audio.play

 

after play i check the result.status in the callback, and the first time i do this with an audiofile it just gives me "success",

but the 2+ time i get "error"

 

so to get the error:

 
overwolf.media.audio.create(songpath, function(result){overwolf.media.audio.play(result.id,function(){})});
 
 
call this twice and the 2nd time the song will be played again, but it won't be stopped if you close the app.
 
 
 
 
 
 
 
one last attempt to make it clear:
as a testing scene i created a button that plays a sound with the function above (except cleaner).
if i press that button twice, i play the song 2 times, but with the 2nd time not stopping if i close the app (it does stop if i close overwolf obviously)
 
 
if you still need my logs, please tell me so i can upload them when i get a chance

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now