PlaceholderGames / 2020-yr1-group-7

CS1S464 2020 Group 7
1 stars 0 forks source link

Loading sounds #29

Closed 30001606VA closed 3 years ago

30001606VA commented 3 years ago

I've repurposed a music file I made near the beginning to be the menu music. The problem being that I need to find out how to play a different music file depending on the screen you're currently on. I've tried playing the game music in the update method, but it will keep playing the first second of the song over and over again. Will keep looking for a fix.

30001606VA commented 3 years ago

Issue solved. I needed to use "pygame.mixer.music.stop()" to end the menu music that was playing. After it stopped I implemented "pygame.mixer.music.load()" into the update method under the start game if statement which started to play the intended background music whenever the player clicks the start button.