aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Kiewitz2009-10-15 08:03:01 +0000
committerMartin Kiewitz2009-10-15 08:03:01 +0000
commit1259c3ded7cb2e96d17af9b6d2e6e0b0083ce34c (patch)
tree4c6bf58494a4381851b90f64e1792ebb8c248e73
parent0868fd24d27b8398247527e334e0f8849726092a (diff)
downloadscummvm-rg350-1259c3ded7cb2e96d17af9b6d2e6e0b0083ce34c.tar.gz
scummvm-rg350-1259c3ded7cb2e96d17af9b6d2e6e0b0083ce34c.tar.bz2
scummvm-rg350-1259c3ded7cb2e96d17af9b6d2e6e0b0083ce34c.zip
SCI/newgui: SciGuiTransitions fadeIn now uses setIntensity() like sierra sci does, fixes blackout in longbow and others
svn-id: r45106
-rw-r--r--engines/sci/gui/gui_transitions.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/engines/sci/gui/gui_transitions.cpp b/engines/sci/gui/gui_transitions.cpp
index 0fcc9cee77..b6f04fb003 100644
--- a/engines/sci/gui/gui_transitions.cpp
+++ b/engines/sci/gui/gui_transitions.cpp
@@ -151,16 +151,10 @@ void SciGuiTransitions::fadeOut() {
void SciGuiTransitions::fadeIn() {
byte workPalette[4 * 256];
GuiPalette *newPalette = &_palette->_sysPalette;
- int16 stepNr, colorNr;
+ int16 stepNr;
for (stepNr = 0; stepNr <= 100; stepNr += 10) {
- for (colorNr = 1; colorNr < 255; colorNr++){
- workPalette[colorNr * 4 + 0] = newPalette->colors[colorNr].r * stepNr / 100;
- workPalette[colorNr * 4 + 1] = newPalette->colors[colorNr].g * stepNr / 100;
- workPalette[colorNr * 4 + 2] = newPalette->colors[colorNr].b * stepNr / 100;
- workPalette[colorNr * 4 + 3] = 100;
- }
- g_system->setPalette(workPalette + 4, 1, 254);
+ _palette->setIntensity(1, 254, 100, true);
_gui->wait(2);
}
}