android.gameengine.icadroids.sound
Class MusicPlayer

java.lang.Object
  extended by android.gameengine.icadroids.sound.MusicPlayer

public final class MusicPlayer
extends java.lang.Object

This class features a number of static methods that can be used to add music to your game. This class should be used when you want to play long sound clips or background music. For short soundclips, use the GameSound class.

Author:
Lex & Leon

Constructor Summary
MusicPlayer()
           
 
Method Summary
static void pauseAll()
          Pauses all playing music, call resumeAll to continue playing music.
static void play(java.lang.String resId, boolean loop)
          Plays the specified music.
static void resumeAll()
          Resumes playing all paused music.
static void stop()
          Stop playing music.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MusicPlayer

public MusicPlayer()
Method Detail

play

public static void play(java.lang.String resId,
                        boolean loop)
Plays the specified music.

Parameters:
resId - The name of the music that needs to played.

stop

public static void stop()
Stop playing music.


pauseAll

public static void pauseAll()
Pauses all playing music, call resumeAll to continue playing music.


resumeAll

public static void resumeAll()
Resumes playing all paused music.