Skip to content

Commit

Permalink
PRINCE: Implement pauseEngineIntern() - pause and resume music in GMM
Browse files Browse the repository at this point in the history
  • Loading branch information
lukaslw committed Nov 8, 2014
1 parent 9f2c3d7 commit ccb051f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
10 changes: 10 additions & 0 deletions engines/prince/prince.cpp
Expand Up @@ -427,6 +427,16 @@ Common::Error PrinceEngine::run() {
return Common::kNoError;
}

void PrinceEngine::pauseEngineIntern(bool pause) {
Engine::pauseEngineIntern(pause);
if (pause) {
_midiPlayer->pause();
}
else {
_midiPlayer->resume();
}
}

bool AnimListItem::loadFromStream(Common::SeekableReadStream &stream) {
int32 pos = stream.pos();

Expand Down
1 change: 1 addition & 0 deletions engines/prince/prince.h
Expand Up @@ -256,6 +256,7 @@ class PrinceEngine : public Engine {
virtual ~PrinceEngine();

virtual bool hasFeature(EngineFeature f) const;
virtual void pauseEngineIntern(bool pause);
virtual bool canSaveGameStateCurrently();
virtual bool canLoadGameStateCurrently();
virtual Common::Error saveGameState(int slot, const Common::String &desc);
Expand Down

0 comments on commit ccb051f

Please sign in to comment.