aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/palette.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/scumm/palette.cpp')
-rw-r--r--engines/scumm/palette.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/engines/scumm/palette.cpp b/engines/scumm/palette.cpp
index 38577cd0c4..5c0c58595b 100644
--- a/engines/scumm/palette.cpp
+++ b/engines/scumm/palette.cpp
@@ -141,6 +141,7 @@ void ScummEngine::resetPalette() {
};
#ifdef USE_RGB_COLOR
+#ifndef DISABLE_TOWNS_DUAL_LAYER_MODE
static const byte tableTownsV3Palette[] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0xA0, 0x00, 0xA0, 0x00, 0x00, 0xA0, 0xA0,
0xA0, 0x00, 0x00, 0xA0, 0x00, 0xA0, 0xA0, 0x60, 0x00, 0xA0, 0xA0, 0xA0,
@@ -155,6 +156,7 @@ void ScummEngine::resetPalette() {
0xFF, 0x57, 0x57, 0xD6, 0x94, 0x40, 0xFF, 0xFF, 0x57, 0xFF, 0xFF, 0xFF
};
#endif
+#endif
if (_game.version <= 1) {
if (_game.platform == Common::kPlatformApple2GS) {
@@ -215,6 +217,7 @@ void ScummEngine::resetPalette() {
// else we initialise and then lock down the first 16 colors.
if (_renderMode != Common::kRenderEGA)
setPaletteFromTable(tableAmigaMIPalette, sizeof(tableAmigaMIPalette) / 3);
+#ifndef DISABLE_TOWNS_DUAL_LAYER_MODE
} else if (_game.platform == Common::kPlatformFMTowns) {
if (_game.id == GID_INDY4 || _game.id == GID_MONKEY2)
_townsClearLayerFlag = 0;
@@ -226,6 +229,7 @@ void ScummEngine::resetPalette() {
#endif
_townsScreen->toggleLayers(_townsActiveLayerFlags);
+#endif // DISABLE_TOWNS_DUAL_LAYER_MODE
}
setDirtyColors(0, 255);
}
@@ -493,8 +497,10 @@ void ScummEngine::cyclePalette() {
int valueToAdd;
int i, j;
+#ifndef DISABLE_TOWNS_DUAL_LAYER_MODE
if (_game.platform == Common::kPlatformFMTowns && (!_townsPaletteFlags & 1))
return;
+#endif
valueToAdd = VAR(VAR_TIMER);
if (valueToAdd < VAR(VAR_TIMER_NEXT))
@@ -537,8 +543,10 @@ void ScummEngine::moveMemInPalRes(int start, int end, byte direction) {
}
void ScummEngine::palManipulateInit(int resID, int start, int end, int time) {
+#ifndef DISABLE_TOWNS_DUAL_LAYER_MODE
if (_game.platform == Common::kPlatformFMTowns && (!_townsPaletteFlags & 1))
return;
+#endif
byte *string1 = getStringAddress(resID);
byte *string2 = getStringAddress(resID + 1);
@@ -1008,9 +1016,11 @@ void ScummEngine::setCurrentPalette(int palindex) {
if (_game.id == GID_LOOM && _game.platform == Common::kPlatformPCEngine) {
setPCEPaletteFromPtr(pals);
#ifdef USE_RGB_COLOR
+#ifndef DISABLE_TOWNS_DUAL_LAYER_MODE
} else if (_game.platform == Common::kPlatformFMTowns) {
towns_setPaletteFromPtr(pals);
#endif
+#endif
} else {
setPaletteFromPtr(pals);
}
@@ -1111,6 +1121,7 @@ void ScummEngine::updatePalette() {
_palDirtyMin = 256;
#ifdef USE_RGB_COLOR
+#ifndef DISABLE_TOWNS_DUAL_LAYER_MODE
if (_game.platform == Common::kPlatformFMTowns) {
p = palette_colors;
for (i = first; i < first + num; ++i) {
@@ -1120,6 +1131,7 @@ void ScummEngine::updatePalette() {
return;
}
#endif
+#endif
_system->setPalette(palette_colors, first, num);
}