diff options
author | Florian Kagerer | 2009-10-11 20:29:38 +0000 |
---|---|---|
committer | Florian Kagerer | 2009-10-11 20:29:38 +0000 |
commit | 2109a0ff9dc7e8dac3a17e79bec2565e219bea6f (patch) | |
tree | 8130426dd29a8607068b9ed071a603bd9bcede26 /engines/kyra | |
parent | 29a6fdf367b09a944a255e58d11207ce494d6a54 (diff) | |
download | scummvm-rg350-2109a0ff9dc7e8dac3a17e79bec2565e219bea6f.tar.gz scummvm-rg350-2109a0ff9dc7e8dac3a17e79bec2565e219bea6f.tar.bz2 scummvm-rg350-2109a0ff9dc7e8dac3a17e79bec2565e219bea6f.zip |
LOL/PC-98: cleanup
svn-id: r44946
Diffstat (limited to 'engines/kyra')
-rw-r--r-- | engines/kyra/script_lol.cpp | 28 |
1 files changed, 4 insertions, 24 deletions
diff --git a/engines/kyra/script_lol.cpp b/engines/kyra/script_lol.cpp index 71e9b1d24f..acc0f7cab6 100644 --- a/engines/kyra/script_lol.cpp +++ b/engines/kyra/script_lol.cpp @@ -2217,34 +2217,14 @@ int LoLEngine::olol_restoreMagicShroud(EMCState *script) { Palette **tpal3 = &fadeTab[2]; Palette **tpal4 = 0; - if (_flags.use16ColorMode) { - const uint8 *s = _res->fileData("LITEPAL1.COL", 0); - (*tpal1)->copy(s, 0, 16); - delete[] s; - } else { - _screen->loadPalette("LITEPAL1.COL", **tpal1); - } - + int len = _flags.use16ColorMode ? 48 : 768; + _res->loadFileToBuf("LITEPAL1.COL", (*tpal1)->getData(), len); tpal2 = _screen->generateFadeTable(tpal3, 0, *tpal1, 21); - if (_flags.use16ColorMode) { - const uint8 *s = _res->fileData("LITEPAL2.COL", 0); - (*tpal2)->copy(s, 0, 16); - delete[] s; - } else { - _screen->loadPalette("LITEPAL2.COL", **tpal2); - } - + _res->loadFileToBuf("LITEPAL2.COL", (*tpal2)->getData(), len); tpal4 = tpal2++; - if (_flags.use16ColorMode) { - const uint8 *s = _res->fileData("LITEPAL3.COL", 0); - (*tpal1)->copy(s, 0, 16); - delete[] s; - } else { - _screen->loadPalette("LITEPAL3.COL", **tpal1); - } - + _res->loadFileToBuf("LITEPAL3.COL", (*tpal1)->getData(), len); _screen->generateFadeTable(tpal2, *tpal4, *tpal1, 4); for (int i = 0; i < 21; i++) { |