1 #ifndef HEADER_DUMMYSOUNDAGENT_H 2 #define HEADER_DUMMYSOUNDAGENT_H 3 4 #include "SoundAgent.h" 5 6 /** 7 * NO sound and music. 8 */ 9 class DummySoundAgent : public SoundAgent { 10 protected: setSoundVolume(int)11 virtual void setSoundVolume(int ) {} setMusicVolume(int)12 virtual void setMusicVolume(int ) {} 13 public: playSound(Mix_Chunk *,int,int)14 virtual int playSound(Mix_Chunk *, int /*volume*/, int /*loops*/) 15 { return -1; } 16 playMusic(const Path &,BaseMsg * finished)17 virtual void playMusic(const Path &, 18 BaseMsg *finished) 19 { 20 if (finished) { 21 delete finished; 22 } 23 } stopMusic()24 virtual void stopMusic() {} 25 }; 26 27 #endif 28