forked from s464965/WMICraft
18 lines
444 B
Python
18 lines
444 B
Python
|
from random import choice
|
||
|
from pygame import mixer
|
||
|
|
||
|
|
||
|
class gamePlaylist:
|
||
|
wavFiles = ["sound/2mm.ogg", "sound/3.ogg", "sound/4.ogg", "sound/5.ogg"]
|
||
|
wavMenu = ["sound/1.ogg"]
|
||
|
|
||
|
def gameAudio(self):
|
||
|
wavRandom = choice(gamePlaylist.wavFiles)
|
||
|
mixer.music.load(wavRandom)
|
||
|
mixer.music.play()
|
||
|
|
||
|
def menuAudio(self):
|
||
|
w = choice(gamePlaylist.wavMenu)
|
||
|
mixer.music.load(w)
|
||
|
mixer.music.play(-1)
|