diff options
author | Eugene Sandulenko | 2013-08-07 20:52:23 +0300 |
---|---|---|
committer | Eugene Sandulenko | 2013-09-06 14:51:11 +0300 |
commit | ea91b8f7998cc4a06f4f5d8732a1b9b0309d95d2 (patch) | |
tree | 14868fc0cfefffa27005e3fe56f9fedb455e1061 /engines/fullpipe/gfx.cpp | |
parent | 133a77887f51ba2a01c3a6839606f121326637f9 (diff) | |
download | scummvm-rg350-ea91b8f7998cc4a06f4f5d8732a1b9b0309d95d2.tar.gz scummvm-rg350-ea91b8f7998cc4a06f4f5d8732a1b9b0309d95d2.tar.bz2 scummvm-rg350-ea91b8f7998cc4a06f4f5d8732a1b9b0309d95d2.zip |
FULLPIPE: Initial code for SC_1
Diffstat (limited to 'engines/fullpipe/gfx.cpp')
-rw-r--r-- | engines/fullpipe/gfx.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/engines/fullpipe/gfx.cpp b/engines/fullpipe/gfx.cpp index c677d0e378..8996337e2f 100644 --- a/engines/fullpipe/gfx.cpp +++ b/engines/fullpipe/gfx.cpp @@ -427,6 +427,15 @@ void Picture::draw(int x, int y, int style, int angle) { warning("Picture:draw: alpha = %0x", _alpha); } + byte *pal = _paletteData; + + if (!pal) { + pal = g_fullpipe->_globalPalette; + + if (!pal) + error("Picture::draw(): Both global and local palettes are empty"); + } + switch (style) { case 1: //flip @@ -439,7 +448,7 @@ void Picture::draw(int x, int y, int style, int angle) { if (angle) drawRotated(x1, y1, angle); else - _bitmap->putDib(x1, y1, (int32 *)_paletteData); + _bitmap->putDib(x1, y1, (int32 *)pal); } } |