|
Controls loading, mixing, and playing the sounds.
Having seperate classes allows different groups of sounds to be loaded,
and unloaded from memory easily.
|
Methods
|
|
GetSound
Initialize
Load
Play
PlayMusic
__init__
_debug
|
|
|
GetSound
|
GetSound ( self, name )
Returns a Sound object for the given name.
|
|
|
Initialize
|
Initialize ( self )
Initializes the mixer.
|
|
|
Load
|
Load ( self, names=sound_list )
Loads sounds.
|
|
|
Play
|
Play (
self,
name,
volume=[ 1.0, 1.0 ],
wait=1,
)
Plays the sound with the given name.
name - of the sound.
volume - left and right. Ranges 0.0 - 1.0
wait - if there is a sound of this type playing wait for it.
|
|
|
PlayMusic
|
PlayMusic ( self, musicname )
Plays a music track. Only one can be played at a time.
So if there is one playing, it will be stopped and the new one started.
|
|
|
__init__
|
__init__ ( self )
|
|
|
_debug
|
_debug (
self,
x,
debug_level=0,
)
|
|