diff options
author | Matthew Hoops | 2011-09-29 16:59:02 -0400 |
---|---|---|
committer | Matthew Hoops | 2011-09-29 16:59:02 -0400 |
commit | 447b7204f34230044c379022f9a89d14129acbb7 (patch) | |
tree | 5841eca0ef5058aa775c24a344d0e43c9c9bad3c | |
parent | 7390d327f19df4d0da38ef6d989aa99bfd08b684 (diff) | |
download | scummvm-rg350-447b7204f34230044c379022f9a89d14129acbb7.tar.gz scummvm-rg350-447b7204f34230044c379022f9a89d14129acbb7.tar.bz2 scummvm-rg350-447b7204f34230044c379022f9a89d14129acbb7.zip |
PEGASUS: Returning from the pause menu works now
-rw-r--r-- | engines/pegasus/pegasus.cpp | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/engines/pegasus/pegasus.cpp b/engines/pegasus/pegasus.cpp index 037688b337..690af4b214 100644 --- a/engines/pegasus/pegasus.cpp +++ b/engines/pegasus/pegasus.cpp @@ -684,10 +684,6 @@ void PegasusEngine::doGameMenuCommand(const tGameMenuCommand command) { error("Load game"); break; case kMenuCmdPauseQuit: -#if 1 - // TODO: This doesn't work yet - error("Return to main menu"); -#else // TODO: Fade out throwAwayEverything(); pauseMenu(false); @@ -697,7 +693,6 @@ void PegasusEngine::doGameMenuCommand(const tGameMenuCommand command) { // TODO: Fade in if (!isDemo()) resetIntroTimer(); -#endif break; case kMenuCmdNoCommand: break; @@ -1087,7 +1082,21 @@ void PegasusEngine::doDeath() { } void PegasusEngine::throwAwayEverything() { - // TODO + if (_items.getNumItems() != 0) + _currentItemID = g_interface->getCurrentInventoryItem()->getObjectID(); + else + _currentItemID = kNoItemID; + + if (_biochips.getNumItems() != 0) + _currentItemID = g_interface->getCurrentBiochip()->getObjectID(); + else + _currentItemID = kNoItemID; + + useMenu(0); + useNeighborhood(0); + + delete g_interface; + g_interface = 0; } void PegasusEngine::processShell() { |