From 3cb59d237e85805eeab377ec8d571a76d83cd029 Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Wed, 14 Jul 2010 04:34:57 +0000 Subject: Don't close the MIDI driver twice. It's unnecessary, and some of our drivers may crash. (The ALSA one did, until a few minutes ago.) svn-id: r50871 --- engines/saga/music.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'engines/saga') diff --git a/engines/saga/music.cpp b/engines/saga/music.cpp index 8b7654d689..fcf27cc845 100644 --- a/engines/saga/music.cpp +++ b/engines/saga/music.cpp @@ -177,7 +177,6 @@ Music::~Music() { _vm->getTimerManager()->removeTimerProc(&musicVolumeGaugeCallback); _mixer->stopHandle(_musicHandle); _driver->setTimerCallback(NULL, NULL); - _driver->close(); delete _driver; _parser->setMidiDriver(NULL); delete _parser; -- cgit v1.2.3 From ae1afee564070234afc0a1b4fca619b3231d4e57 Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Fri, 16 Jul 2010 03:32:59 +0000 Subject: The standalone MIDI files for one of the re-releases of Inherit the Earth are General MIDI, not MT-32. (I hope this doesn't break anything else.) svn-id: r50927 --- engines/saga/music.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'engines/saga') diff --git a/engines/saga/music.cpp b/engines/saga/music.cpp index fcf27cc845..e4a16e27da 100644 --- a/engines/saga/music.cpp +++ b/engines/saga/music.cpp @@ -158,6 +158,8 @@ Music::Music(SagaEngine *vm, Audio::Mixer *mixer) : _vm(vm), _mixer(mixer) { _driver->setGM(_vm->getGameId() != GID_ITE); } else { _parser = MidiParser::createParser_SMF(); + // ITE with standalone MIDI files is General MIDI + _driver->setGM(_vm->getGameId() == GID_ITE); } free(resourceData); } -- cgit v1.2.3 From aa631a64dce17e89cc657b4588af0ba032b9664d Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Fri, 16 Jul 2010 23:23:30 +0000 Subject: Removed unused variable. I believe thread->_instructionOffset serves the same purpose that 'addr' was inteded to. svn-id: r50951 --- engines/saga/script.cpp | 2 -- 1 file changed, 2 deletions(-) (limited to 'engines/saga') diff --git a/engines/saga/script.cpp b/engines/saga/script.cpp index 18bbca2425..5fd120ac33 100644 --- a/engines/saga/script.cpp +++ b/engines/saga/script.cpp @@ -571,9 +571,7 @@ void Script::opCall(SCRIPTOP_PARAMS) { if (iparam1 != kAddressModule) { error("Script::runThread iparam1 != kAddressModule"); } - byte *addr = thread->baseAddress(iparam1); iparam1 = scriptS->readSint16LE(); - addr += iparam1; thread->push(argumentsCount); // NOTE: The original pushes the program -- cgit v1.2.3 From 1d4c82885ddcc0442671c863eef643aef2dc7dda Mon Sep 17 00:00:00 2001 From: Max Horn Date: Sat, 17 Jul 2010 18:38:42 +0000 Subject: DEBUGGER: Simplify how our console debugger works / is used * Remove _isAttached member var and isAttached method * Engines now always call the onFrame method; whether it does something is decided by the debugger class resp. its subclasses * Make detach() protected instead of private, so that subclasses can invoke it * Remove _detach_now member var (call detach() instead). * Rename _frame_countdown to _frameCountdown and properly document it. * Add more doxygen comments * Cleanup svn-id: r50963 --- engines/saga/saga.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'engines/saga') diff --git a/engines/saga/saga.cpp b/engines/saga/saga.cpp index d1ab3bc9d7..1b7fa97f8d 100644 --- a/engines/saga/saga.cpp +++ b/engines/saga/saga.cpp @@ -352,8 +352,7 @@ Common::Error SagaEngine::run() { uint32 currentTicks; while (!shouldQuit()) { - if (_console->isAttached()) - _console->onFrame(); + _console->onFrame(); if (_render->getFlags() & RF_RENDERPAUSE) { // Freeze time while paused -- cgit v1.2.3