aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra
diff options
context:
space:
mode:
authorJohannes Schickel2007-02-01 13:10:49 +0000
committerJohannes Schickel2007-02-01 13:10:49 +0000
commitb138b5cce12228670b92c069fc4a272e7ed96175 (patch)
tree6fc0e1b83bec1f045127b90b34961e71de152b04 /engines/kyra
parentd2b8787dd5621f57fa4daab93157f4bb59608238 (diff)
downloadscummvm-rg350-b138b5cce12228670b92c069fc4a272e7ed96175.tar.gz
scummvm-rg350-b138b5cce12228670b92c069fc4a272e7ed96175.tar.bz2
scummvm-rg350-b138b5cce12228670b92c069fc4a272e7ed96175.zip
Fix for missing Brandon in Zanthia's home (see bug #1498221 "KYRA1: Subtitles missing when meeting Zanthia
"). svn-id: r25320
Diffstat (limited to 'engines/kyra')
-rw-r--r--engines/kyra/screen.cpp15
-rw-r--r--engines/kyra/screen.h1
2 files changed, 13 insertions, 3 deletions
diff --git a/engines/kyra/screen.cpp b/engines/kyra/screen.cpp
index 759249dfb8..20f6022101 100644
--- a/engines/kyra/screen.cpp
+++ b/engines/kyra/screen.cpp
@@ -138,6 +138,16 @@ void Screen::updateScreen() {
if (_disableScreen)
return;
+ updateDirtyRects();
+
+ _forceFullUpdate = false;
+ _numDirtyRects = 0;
+ //for debug reasons (needs 640x200 screen)
+ //_system->copyRectToScreen(getPagePtr(2), SCREEN_W, 320, 0, SCREEN_W, SCREEN_H);
+ _system->updateScreen();
+}
+
+void Screen::updateDirtyRects() {
if (_forceFullUpdate) {
_system->copyRectToScreen(getCPagePtr(0), SCREEN_W, 0, 0, SCREEN_W, SCREEN_H);
} else {
@@ -149,9 +159,6 @@ void Screen::updateScreen() {
}
_forceFullUpdate = false;
_numDirtyRects = 0;
- //for debug reasons (needs 640x200 screen)
- //_system->copyRectToScreen(getPagePtr(2), SCREEN_W, 320, 0, SCREEN_W, SCREEN_H);
- _system->updateScreen();
}
uint8 *Screen::getPagePtr(int pageNum) {
@@ -237,6 +244,8 @@ void Screen::fadeSpecialPalette(int palIndex, int startIndex, int size, int fade
void Screen::fadePalette(const uint8 *palData, int delay) {
debugC(9, kDebugLevelScreen, "Screen::fadePalette(%p, %d)", (const void *)palData, delay);
+ updateDirtyRects();
+
uint8 fadePal[768];
memcpy(fadePal, _screenPalette, 768);
uint8 diff, maxDiff = 0;
diff --git a/engines/kyra/screen.h b/engines/kyra/screen.h
index aeaabd792b..db220a8e5e 100644
--- a/engines/kyra/screen.h
+++ b/engines/kyra/screen.h
@@ -200,6 +200,7 @@ public:
private:
uint8 *getPagePtr(int pageNum);
+ void updateDirtyRects();
int16 encodeShapeAndCalculateSize(uint8 *from, uint8 *to, int size);
void restoreMouseRect();