From 46b44b923bca221fbd7f95d8c55c34d658fa31d1 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Sat, 27 Oct 2012 19:08:53 +0200 Subject: HOPKINS: Use platform detection in order to properly initialize the mouse cursor Also fix mass-renaming error in header --- engines/hopkins/detection.cpp | 4 ++++ engines/hopkins/dialogs.cpp | 2 +- engines/hopkins/hopkins.cpp | 11 +++++++---- engines/hopkins/hopkins.h | 1 + engines/hopkins/menu.cpp | 2 +- 5 files changed, 14 insertions(+), 6 deletions(-) diff --git a/engines/hopkins/detection.cpp b/engines/hopkins/detection.cpp index ffbf243122..0be4337862 100644 --- a/engines/hopkins/detection.cpp +++ b/engines/hopkins/detection.cpp @@ -47,6 +47,10 @@ Common::Language HopkinsEngine::getLanguage() const { return _gameDescription->desc.language; } +Common::Platform HopkinsEngine::getPlatform() const { + return _gameDescription->desc.platform; +} + bool HopkinsEngine::getIsDemo() const { return _gameDescription->desc.flags & ADGF_DEMO; } diff --git a/engines/hopkins/dialogs.cpp b/engines/hopkins/dialogs.cpp index 503c35832d..feeb8843d8 100644 --- a/engines/hopkins/dialogs.cpp +++ b/engines/hopkins/dialogs.cpp @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the _globals.FRee Software - * Foundation, Inc., 51 _globals.FRanklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ diff --git a/engines/hopkins/hopkins.cpp b/engines/hopkins/hopkins.cpp index dbdb067950..6143219283 100644 --- a/engines/hopkins/hopkins.cpp +++ b/engines/hopkins/hopkins.cpp @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the _globals.FRee Software - * Foundation, Inc., 51 _globals.FRanklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ @@ -514,8 +514,11 @@ void HopkinsEngine::INIT_SYSTEM() { // Set graphics mode _graphicsManager.SET_MODE(640, 480); - _eventsManager.mouse_linux = true; - + if (getPlatform() == Common::kPlatformLinux) + _eventsManager.mouse_linux = true; + else + _eventsManager.mouse_linux = false; + switch (_globals.FR) { case 0: if (!_eventsManager.mouse_linux) @@ -524,7 +527,7 @@ void HopkinsEngine::INIT_SYSTEM() { _fileManager.CONSTRUIT_SYSTEM("LSOUAN.SPR"); break; case 1: - _fileManager.CONSTRUIT_SYSTEM("LSOU_globals.FR.SPR"); + _fileManager.CONSTRUIT_SYSTEM("LSOUFR.SPR"); break; case 2: _fileManager.CONSTRUIT_SYSTEM("SOUES.SPR"); diff --git a/engines/hopkins/hopkins.h b/engines/hopkins/hopkins.h index 8b601dc356..82bc3317b0 100644 --- a/engines/hopkins/hopkins.h +++ b/engines/hopkins/hopkins.h @@ -119,6 +119,7 @@ public: uint32 getFeatures() const; Common::Language getLanguage() const; + Common::Platform HopkinsEngine::getPlatform() const; uint16 getVersion() const; bool getIsDemo() const; bool shouldQuit() const; diff --git a/engines/hopkins/menu.cpp b/engines/hopkins/menu.cpp index cfa9ed2c0f..8722b9e5d8 100644 --- a/engines/hopkins/menu.cpp +++ b/engines/hopkins/menu.cpp @@ -16,7 +16,7 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the _globals.FRee Software - * Foundation, Inc., 51 _globals.FRanklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ -- cgit v1.2.3 From 2888a3863c5a67b251bedef1f5984dabd2e7e044 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Sat, 27 Oct 2012 19:09:28 +0200 Subject: HOPKINS: Add detection for Win95 demo --- engines/hopkins/detection_tables.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/engines/hopkins/detection_tables.h b/engines/hopkins/detection_tables.h index 0781a530e8..9e1d329f39 100644 --- a/engines/hopkins/detection_tables.h +++ b/engines/hopkins/detection_tables.h @@ -70,6 +70,21 @@ static const HopkinsGameDescription gameDescriptions[] = { GUIO1(GUIO_NONE) }, }, + { + // Hopkins FBI Win95 Demo, provided by Strangerke + { + "hopkins", + 0, + { + {"Hopkins.exe", 0, "0c9ebfe371f4dcf84a49f333f04839a0", 376897}, + AD_LISTEND + }, + Common::EN_ANY, + Common::kPlatformWindows, + ADGF_DEMO, + GUIO1(GUIO_NONE) + }, + }, { // Hopkins FBI Win95, provided by Strangerke { -- cgit v1.2.3