aboutsummaryrefslogtreecommitdiff
path: root/engines/cruise/gfxModule.cpp
diff options
context:
space:
mode:
authorPaul Gilbert2009-06-05 12:20:42 +0000
committerPaul Gilbert2009-06-05 12:20:42 +0000
commit862d1cf42b9d9ce61c1bcf52aa2f7efe75d5249f (patch)
tree207cbe4de3d1daaffa2db4d301d166b57c1e3e44 /engines/cruise/gfxModule.cpp
parent58d494a7cb11c97834c61f6596d38c1c71c57031 (diff)
downloadscummvm-rg350-862d1cf42b9d9ce61c1bcf52aa2f7efe75d5249f.tar.gz
scummvm-rg350-862d1cf42b9d9ce61c1bcf52aa2f7efe75d5249f.tar.bz2
scummvm-rg350-862d1cf42b9d9ce61c1bcf52aa2f7efe75d5249f.zip
Tweaks to the code that pauses for a mouse press when displaying many text messages
svn-id: r41196
Diffstat (limited to 'engines/cruise/gfxModule.cpp')
-rw-r--r--engines/cruise/gfxModule.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/engines/cruise/gfxModule.cpp b/engines/cruise/gfxModule.cpp
index 47d3f49204..50e6587d90 100644
--- a/engines/cruise/gfxModule.cpp
+++ b/engines/cruise/gfxModule.cpp
@@ -40,6 +40,7 @@ palEntry lpalette[256];
int palDirtyMin = 256;
int palDirtyMax = -1;
+bool isBlack = false;
gfxModuleDataStruct gfxModuleData = {
0, // use Tandy
@@ -237,6 +238,12 @@ void flip() {
g_system->setPalette(paletteRGBA + palDirtyMin*4, palDirtyMin, palDirtyMax - palDirtyMin + 1);
palDirtyMin = 256;
palDirtyMax = -1;
+
+ isBlack = true;
+ for (i = 0; i < 256; ++i) {
+ isBlack = (lpalette[i].R == 0) && (lpalette[i].G == 0) && (lpalette[i].B == 0);
+ if (!isBlack) break;
+ }
}
g_system->copyRectToScreen(globalScreen, 320, 0, 0, 320, 200);