diff options
author | Paul Gilbert | 2016-03-20 14:55:41 -0400 |
---|---|---|
committer | Paul Gilbert | 2016-03-20 14:55:41 -0400 |
commit | 3c852cc240221785598023de56e5a71a0d8806fa (patch) | |
tree | c2a64b811586e4e9d8a4d5baa04d5c4f9d23bd08 /engines/bbvs | |
parent | ea54e6244e75c609e6886ba210f80fb22c479d3f (diff) | |
parent | 509a00109e79156e91c062f145ac3aa86ec8584e (diff) | |
download | scummvm-rg350-3c852cc240221785598023de56e5a71a0d8806fa.tar.gz scummvm-rg350-3c852cc240221785598023de56e5a71a0d8806fa.tar.bz2 scummvm-rg350-3c852cc240221785598023de56e5a71a0d8806fa.zip |
Merge branch 'master' into titanic
Diffstat (limited to 'engines/bbvs')
-rw-r--r-- | engines/bbvs/bbvs.cpp | 33 | ||||
-rw-r--r-- | engines/bbvs/detection.cpp | 9 | ||||
-rw-r--r-- | engines/bbvs/dialogs.cpp | 2 |
3 files changed, 23 insertions, 21 deletions
diff --git a/engines/bbvs/bbvs.cpp b/engines/bbvs/bbvs.cpp index d40d5e482f..6ae663479d 100644 --- a/engines/bbvs/bbvs.cpp +++ b/engines/bbvs/bbvs.cpp @@ -137,6 +137,21 @@ BbvsEngine::~BbvsEngine() { } void BbvsEngine::newGame() { + memset(_easterEggInput, 0, sizeof(_easterEggInput)); + _gameTicks = 0; + _playVideoNumber = 0; + memset(_inventoryItemStatus, 0, sizeof(_inventoryItemStatus)); + memset(_gameVars, 0, sizeof(_gameVars)); + memset(_sceneVisited, 0, sizeof(_sceneVisited)); + + _mouseX = 160; + _mouseY = 120; + _mouseButtons = 0; + + _currVerbNum = kVerbLook; + _currTalkObjectIndex = -1; + _currSceneNum = 0; + _currInventoryItem = -1; _newSceneNum = 32; } @@ -162,24 +177,10 @@ Common::Error BbvsEngine::run() { _sound = new SoundMan(); allocSnapshot(); - memset(_easterEggInput, 0, sizeof(_easterEggInput)); - _gameTicks = 0; - _playVideoNumber = 0; - _bootSaveSlot = -1; - - memset(_inventoryItemStatus, 0, sizeof(_inventoryItemStatus)); - memset(_gameVars, 0, sizeof(_gameVars)); - memset(_sceneVisited, 0, sizeof(_sceneVisited)); - - _mouseX = 160; - _mouseY = 120; - _mouseButtons = 0; + newGame(); - _currVerbNum = kVerbLook; - _currInventoryItem = -1; - _currTalkObjectIndex = -1; - _currSceneNum = 0; + _bootSaveSlot = -1; _newSceneNum = 31; if (ConfMan.hasKey("save_slot")) diff --git a/engines/bbvs/detection.cpp b/engines/bbvs/detection.cpp index eb894e9f13..7c0045ee73 100644 --- a/engines/bbvs/detection.cpp +++ b/engines/bbvs/detection.cpp @@ -43,7 +43,7 @@ static const ADGameDescription gameDescriptions[] = { AD_ENTRY1s("vspr0001.vnm", "7ffe9b9e7ca322db1d48e86f5130578e", 1166628), Common::EN_ANY, Common::kPlatformWindows, - ADGF_NO_FLAGS | ADGF_TESTING, + ADGF_NO_FLAGS, GUIO0() }, { @@ -52,7 +52,7 @@ static const ADGameDescription gameDescriptions[] = { AD_ENTRY1s("vspr0001.vnm", "91c76b1048f93208cd7b1a05ebccb408", 1176976), Common::RU_RUS, Common::kPlatformWindows, - GF_GUILANGSWITCH | ADGF_TESTING, + GF_GUILANGSWITCH | ADGF_NO_FLAGS, GUIO0() }, @@ -69,7 +69,7 @@ static const char * const directoryGlobs[] = { class BbvsMetaEngine : public AdvancedMetaEngine { public: BbvsMetaEngine() : AdvancedMetaEngine(Bbvs::gameDescriptions, sizeof(ADGameDescription), bbvsGames) { - _singleid = "bbvs"; + _singleId = "bbvs"; _maxScanDepth = 3; _directoryGlobs = directoryGlobs; } @@ -116,7 +116,6 @@ SaveStateList BbvsMetaEngine::listSaves(const char *target) const { pattern += ".###"; Common::StringArray filenames; filenames = saveFileMan->listSavefiles(pattern.c_str()); - Common::sort(filenames.begin(), filenames.end()); // Sort (hopefully ensuring we are sorted numerically..) SaveStateList saveList; for (Common::StringArray::const_iterator file = filenames.begin(); file != filenames.end(); ++file) { // Obtain the last 3 digits of the filename, since they correspond to the save slot @@ -131,6 +130,8 @@ SaveStateList BbvsMetaEngine::listSaves(const char *target) const { } } } + // Sort saves based on slot number. + Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator()); return saveList; } diff --git a/engines/bbvs/dialogs.cpp b/engines/bbvs/dialogs.cpp index ef7f3c9320..c8470f8eef 100644 --- a/engines/bbvs/dialogs.cpp +++ b/engines/bbvs/dialogs.cpp @@ -102,7 +102,7 @@ void MainMenu::reflowLayout() { _w = 2 * buttonWidth + buttonPadding; _h = 3 * buttonHeight + 3 * buttonPadding; _x = (screenW - _w) / 2; - _y = screenH - _h; + _y = screenH - _h - 2; int x = 0, y = 0; |