diff options
Diffstat (limited to 'engines/sci/graphics/cursor.cpp')
-rw-r--r-- | engines/sci/graphics/cursor.cpp | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/engines/sci/graphics/cursor.cpp b/engines/sci/graphics/cursor.cpp index 7a37d7e865..30fc7a0f3d 100644 --- a/engines/sci/graphics/cursor.cpp +++ b/engines/sci/graphics/cursor.cpp @@ -23,6 +23,7 @@ * */ +#include "common/config-manager.h" #include "common/events.h" #include "common/macresman.h" #include "common/system.h" @@ -59,6 +60,10 @@ GfxCursor::GfxCursor(ResourceManager *resMan, GfxPalette *palette, GfxScreen *sc _zoomColor = 0; _zoomMultiplier = 0; _cursorSurface = 0; + if (g_sci && g_sci->getGameId() == GID_KQ6 && g_sci->getPlatform() == Common::kPlatformWindows) + _useOriginalKQ6WinCursors = ConfMan.getBool("windows_cursors"); + else + _useOriginalKQ6WinCursors = false; } GfxCursor::~GfxCursor() { @@ -171,6 +176,10 @@ void GfxCursor::kernelSetView(GuiResourceId viewNum, int loopNum, int celNum, Co if (_cachedCursors.size() >= MAX_CACHED_CURSORS) purgeCache(); + // Use the original Windows cursors in KQ6, if requested + if (_useOriginalKQ6WinCursors) + viewNum += 2000; // Windows cursors + if (!_cachedCursors.contains(viewNum)) _cachedCursors[viewNum] = new GfxView(_resMan, _screen, _palette, viewNum); @@ -195,7 +204,7 @@ void GfxCursor::kernelSetView(GuiResourceId viewNum, int loopNum, int celNum, Co } const byte *rawBitmap = cursorView->getBitmap(loopNum, celNum); - if (_upscaledHires) { + if (_upscaledHires && !_useOriginalKQ6WinCursors) { // Scale cursor by 2x - note: sierra didn't do this, but it looks much better width *= 2; height *= 2; @@ -226,6 +235,7 @@ void GfxCursor::kernelSetMacCursor(GuiResourceId viewNum, int loopNum, int celNu } // TODO: What about the 2000 resources? Inventory items? How to handle? + // Update: Perhaps these are handled like the Windows cursors in KQ6? // TODO: 1000 + celNum won't work for GK1 Resource *resource = _resMan->findResource(ResourceId(kResourceTypeCursor, 1000 + celNum), false); @@ -281,10 +291,10 @@ void GfxCursor::kernelSetMacCursor(GuiResourceId viewNum, int loopNum, int celNu // ffs. GfxCursor::setPosition (below) // Game, newPosition, validRect static const SciCursorSetPositionWorkarounds setPositionWorkarounds[] = { - { GID_ISLANDBRAIN, 84, 109, 46, 76, 174, 243 }, // island of dr. brain / game menu - { GID_LSL5, 23, 171, 0, 0, 26, 320 }, // larry 5 / skip forward helper - { GID_QFG1VGA, 64, 174, 40, 37, 74, 284 }, // Quest For Glory 1 VGA / run/walk/sleep sub-menu - { (SciGameId)0, -1, -1, -1, -1, -1, -1 } + { GID_ISLANDBRAIN, 84, 109, 46, 76, 174, 243 }, // island of dr. brain / game menu + { GID_LSL5, 23, 171, 0, 0, 26, 320 }, // larry 5 / skip forward helper + { GID_QFG1VGA, 64, 174, 40, 37, 74, 284 }, // Quest For Glory 1 VGA / run/walk/sleep sub-menu + { (SciGameId)0, -1, -1, -1, -1, -1, -1 } }; void GfxCursor::setPosition(Common::Point pos) { |