Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Problem with looping background music. [resolved]

Status
Not open for further replies.
I noticed that when playing background music like so:

Code:
Audio.bgm_play("Audio/bgm/drums_loop.mp3", 100, 100)

The audio doesn't loop fluidly, instead there is a slight pause between loops! How can I remedy this problem?

EDIT: I double checked the audio file to ensure that it doesn't have a pause in it and well, it doesn't so I know it's not the file.
 
Ok I found the problem, it wasn't with the code. For some reason my audio editing software decides to add it's own silence before and after the audio whenever I save it. I don't yet know why but it happens whenever I save the file as mp3. Whenever I use the wave format it doesn't do it. Of course the wave format is a larger file size but... I'll deal with that later. Thanks for the help.

For the record, when using the following code:

Audio.bgm_play("Audio/bgm/drums_loop.mp3", 100, 100)

Background music does in fact loop fluidly and correctly. If you're having the same problem I did, check your audio file closer!
 
Status
Not open for further replies.

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top