diff options
-rw-r--r-- | engines/scumm/gfx.cpp | 4 | ||||
-rw-r--r-- | engines/scumm/gfx.h | 4 | ||||
-rw-r--r-- | engines/scumm/scumm.cpp | 15 |
3 files changed, 12 insertions, 11 deletions
diff --git a/engines/scumm/gfx.cpp b/engines/scumm/gfx.cpp index b78059bd94..fd529b36fe 100644 --- a/engines/scumm/gfx.cpp +++ b/engines/scumm/gfx.cpp @@ -251,7 +251,7 @@ GdiV2::~GdiV2() { } #ifdef USE_RGB_COLOR -Gdi16Bit::Gdi16Bit(ScummEngine *vm) : Gdi(vm) { +GdiHE16bit::GdiHE16bit(ScummEngine *vm) : GdiHE(vm) { } #endif @@ -3674,7 +3674,7 @@ void Gdi::unkDecode11(byte *dst, int dstPitch, const byte *src, int height) cons #undef READ_BIT_256 #ifdef USE_RGB_COLOR -void Gdi16Bit::writeRoomColor(byte *dst, byte color) const { +void GdiHE16bit::writeRoomColor(byte *dst, byte color) const { WRITE_UINT16(dst, READ_LE_UINT16(_vm->_hePalettes + 2048 + color * 2)); } #endif diff --git a/engines/scumm/gfx.h b/engines/scumm/gfx.h index 54ce724da1..2e7111e78b 100644 --- a/engines/scumm/gfx.h +++ b/engines/scumm/gfx.h @@ -430,11 +430,11 @@ public: }; #ifdef USE_RGB_COLOR -class Gdi16Bit : public Gdi { +class GdiHE16bit : public GdiHE { protected: virtual void writeRoomColor(byte *dst, byte color) const; public: - Gdi16Bit(ScummEngine *vm); + GdiHE16bit(ScummEngine *vm); }; #endif diff --git a/engines/scumm/scumm.cpp b/engines/scumm/scumm.cpp index 362430d704..4fd1f6b32d 100644 --- a/engines/scumm/scumm.cpp +++ b/engines/scumm/scumm.cpp @@ -114,17 +114,18 @@ ScummEngine::ScummEngine(OSystem *syst, const DetectorResult &dr) _rnd("scumm") { - if (_game.heversion > 0) { - _gdi = new GdiHE(this); - } else if (_game.platform == Common::kPlatformNES) { - _gdi = new GdiNES(this); #ifdef USE_RGB_COLOR - } else if (_game.features & GF_16BIT_COLOR) { + if (_game.features & GF_16BIT_COLOR) { if (_game.platform == Common::kPlatformPCEngine) _gdi = new GdiPCEngine(this); - else - _gdi = new Gdi16Bit(this); + else if (_game.heversion > 0) + _gdi = new GdiHE16bit(this); + } else #endif + if (_game.heversion > 0) { + _gdi = new GdiHE(this); + } else if (_game.platform == Common::kPlatformNES) { + _gdi = new GdiNES(this); } else if (_game.version <= 1) { _gdi = new GdiV1(this); } else if (_game.version == 2) { |