Jump to content

Audio loops every x seconds


Ozvooky
 Share

Recommended Posts

Hi everyone, in my game I am attempting to get some background music to play, and the code looks like this:

 

this.theme = this.game.add.audio('theme');
this.theme.volume = 0.3;
this.theme.play();
 
The music plays, however whilst it is playing, the music starts playing from the beginning while the music is playing. This continues occurring, until there is 10 themes playing at the same time, 10s or something behind each other. How can i fix this?
Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...