I’m experimenting big delays (up to 5secs) on my sounds/music at the beginning of the project. Specially when I exported to HTML and try to run it locally on my PC. Is there a way programmatically to wait until the song is fully loaded so I can start my 1st Game Level??? Thank you!
i think the audio plays when you start to interact with the project. hope that helps :)
Thank you for your response, but unfortunately is not like that. For my first level I have an mp3 song that last 2 minutes. If I ran the project with the wick Editor, the delay is about 1 second. If I export the project in html to run it locally in my machine, the delay is about 5 to 6 seconds. During that time, I’m already playing the game and other short sound FXs like coins are working.
oooohhhh, that makes sense. thanks for the clarity!
Yeah, I wish that I could somehow catch when the sound is fully loaded into the project so I can start the level. It is very weird when the level start without the music. It is not acceptable. I should be able to control that. If not, I would need to create a title demo screen that maintain the user busy while all sounds load.
I think this might help:
Click here to see the full conversation
Thank you, but it is different. That would help to maintain the same track running in a loop. What I need is somehow to detect if the sound completed buffering; or if the sound started playing; or if the sound loaded completely.
To my knowledge that doesn’t exist. You want to know when a sound is done buffering so it plays the whole thing with no pause, right?
Yes, at the moment that the buffering is completed, then I can start the game Level with the sound.
So what u really need is a loading sign that preloads the project before entering!
Wow, that’s something I was currently trying to find out how to do…
Well, that could be a way to do it, but what I really want to accomplish is to make sure that the level start with the music properly. Right now, the Level starts without the music and then the music starts playing. I’m assuming that the music started right after the buffering is completed.
Imaging that you are playing the first Level of Super Mario Bros, and starts in mute and then the music starts playing after 6 seconds. That is not aceptable.
Anything to do with wifi maybe? Or is lag making the music slow down? Maybe you can send a file and I can see what it’s like.
mmm… It should not be related to wifi, because if you export your project as html, you should be able to play your game without internet. I did it like that, and the music has a 5 or 6 seconds delay.
do you mean 5-6 (range) or 5/6 (fraction)?
Good catch, let me modify that one. Thank you! (5 or 6 seconds)
Hmm, we don’t yet have a way to wait until loaded. However, the delay for HTML files may not be fixable in a straightforward way. I’ll look into this for the 1.19 release.