diff options
-rw-r--r-- | engines/sci/graphics/ports.cpp | 9 | ||||
-rw-r--r-- | engines/sci/graphics/screen.cpp | 20 | ||||
-rw-r--r-- | engines/sci/graphics/screen.h | 2 |
3 files changed, 25 insertions, 6 deletions
diff --git a/engines/sci/graphics/ports.cpp b/engines/sci/graphics/ports.cpp index 87f0c3d6a2..57c76126c0 100644 --- a/engines/sci/graphics/ports.cpp +++ b/engines/sci/graphics/ports.cpp @@ -106,7 +106,10 @@ void GfxPorts::init(bool usesOldGfxFunctions, GfxPaint16 *paint16, GfxText16 *te offTop = 26; break; default: - offTop = 10; + // For Mac games running with a height of 190, we do not have a menu bar + // so the top offset should be 0. + if (_screen->getHeight() == 190) + offTop = 0; break; } @@ -575,10 +578,6 @@ void GfxPorts::priorityBandsInit(int16 bandCount, int16 top, int16 bottom) { int16 y; int32 bandSize; - // This code is for 320x200 games only - if (_screen->getHeight() != 200) - return; - if (bandCount != -1) _priorityBandCount = bandCount; diff --git a/engines/sci/graphics/screen.cpp b/engines/sci/graphics/screen.cpp index a0f402f833..b019853a2b 100644 --- a/engines/sci/graphics/screen.cpp +++ b/engines/sci/graphics/screen.cpp @@ -64,7 +64,7 @@ GfxScreen::GfxScreen(ResourceManager *resMan) : _resMan(resMan) { _height = 480; } else { _width = 320; - _height = 200; + _height = getLowResScreenHeight(); } // Japanese versions of games use hi-res font on upscaled version of the game. @@ -717,4 +717,22 @@ int16 GfxScreen::kernelPicNotValid(int16 newPicNotValid) { return oldPicNotValid; } +uint16 GfxScreen::getLowResScreenHeight() { + // Some Mac SCI1/1.1 games only take up 190 rows and do not + // have the menu bar. + if (g_sci->getPlatform() == Common::kPlatformMacintosh) { + switch (g_sci->getGameId()) { + case GID_FREDDYPHARKAS: + case GID_KQ5: + case GID_KQ6: + return 190; + default: + break; + } + } + + // Everything else is 200 + return 200; +} + } // End of namespace Sci diff --git a/engines/sci/graphics/screen.h b/engines/sci/graphics/screen.h index 1d6b127adc..fc1f38ed41 100644 --- a/engines/sci/graphics/screen.h +++ b/engines/sci/graphics/screen.h @@ -181,6 +181,8 @@ private: // This defines whether or not the font we're drawing is already scaled // to the screen size (and we therefore should not upscale it ourselves). bool _fontIsUpscaled; + + uint16 getLowResScreenHeight(); }; } // End of namespace Sci |