diff options
author | Nicola Mettifogo | 2007-07-30 18:39:38 +0000 |
---|---|---|
committer | Nicola Mettifogo | 2007-07-30 18:39:38 +0000 |
commit | ba271c04054ff0ec64032df3626ab89353089415 (patch) | |
tree | 8605bfb9c402c45be982fada70898a881fcfd7ad /engines/parallaction | |
parent | 4c2ec23de7e37c148f9d3ada3cf85507c8f1db97 (diff) | |
download | scummvm-rg350-ba271c04054ff0ec64032df3626ab89353089415.tar.gz scummvm-rg350-ba271c04054ff0ec64032df3626ab89353089415.tar.bz2 scummvm-rg350-ba271c04054ff0ec64032df3626ab89353089415.zip |
Replaced some palette code in _c_endComment with a function call.
svn-id: r28334
Diffstat (limited to 'engines/parallaction')
-rw-r--r-- | engines/parallaction/callables_ns.cpp | 30 |
1 files changed, 2 insertions, 28 deletions
diff --git a/engines/parallaction/callables_ns.cpp b/engines/parallaction/callables_ns.cpp index de5e1e9862..adf74cf75c 100644 --- a/engines/parallaction/callables_ns.cpp +++ b/engines/parallaction/callables_ns.cpp @@ -341,33 +341,7 @@ void Parallaction_ns::_c_endComment(void *param) { byte* _enginePal = _gfx->_palette; Gfx::Palette pal; - uint32 si; - for (si = 0; si < 32; si++) { - - byte al = _enginePal[si*3+1]; - if (al > _enginePal[si*3+2]) { - al = _enginePal[si*3+1]; - } else { - al = _enginePal[si*3+2]; - } - - if (al < _enginePal[si*3]) { - al = _enginePal[si*3]; - } else { - al = _enginePal[si*3+1]; - } - - if (al > _enginePal[si*3+2]) { - al = _enginePal[si*3+1]; - } else { - al = _enginePal[si*3+2]; - } - - pal[si*3] = al; - pal[si*3+2] = al; - pal[si*3+1] = al; - - } + _gfx->buildBWPalette(pal); int16 w = 0, h = 0; _gfx->getStringExtent(_location._endComment, 130, &w, &h); @@ -385,7 +359,7 @@ void Parallaction_ns::_c_endComment(void *param) { _gfx->displayWrappedString(_location._endComment, 3, 5, 0, 130); _gfx->updateScreen(); - uint32 di = 0; + uint32 si, di; for (di = 0; di < PALETTE_COLORS; di++) { for (si = 0; si <= 93; si +=3) { |