diff options
author | Max Horn | 2002-08-19 17:52:26 +0000 |
---|---|---|
committer | Max Horn | 2002-08-19 17:52:26 +0000 |
commit | 10d0c6b4d2efe10b966737adbf79ffa5a4c4f046 (patch) | |
tree | d0df13be6259df390cde481059227cc1c6878d50 | |
parent | a5b5b23ae8f28925609208a45af147cf0d8b90f8 (diff) | |
download | scummvm-rg350-10d0c6b4d2efe10b966737adbf79ffa5a4c4f046.tar.gz scummvm-rg350-10d0c6b4d2efe10b966737adbf79ffa5a4c4f046.tar.bz2 scummvm-rg350-10d0c6b4d2efe10b966737adbf79ffa5a4c4f046.zip |
more o5_lights work; the only thing missing should be the flashlight now
svn-id: r4775
-rw-r--r-- | gfx.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -739,7 +739,10 @@ void Gdi::drawBitmap(byte *ptr, VirtScreen *vs, int x, int y, int h, byte twobufs; int numzbuf; int sx; + bool lightsOn; + // Check whether lights are turned on or not + lightsOn = (_vm->_features & GF_AFTER_V6) || (_vm->_vars[_vm->VAR_CURRENT_LIGHTS] & LIGHTMODE_screen); CHECK_HEAP; if (_vm->_features & GF_SMALL_HEADER) @@ -824,12 +827,12 @@ void Gdi::drawBitmap(byte *ptr, VirtScreen *vs, int x, int y, int h, _bgbak_ptr = where_draw_ptr; if (_vm->hasCharsetMask(sx << 3, y, (sx + 1) << 3, bottom)) { - if (flag & dbClear) + if (flag & dbClear || (!lightsOn && vs->number == 0)) clear8ColWithMasking(); else draw8ColWithMasking(); } else { - if (flag & dbClear) + if (flag & dbClear || (!lightsOn && vs->number == 0)) clear8Col(); else blit(_backbuff_ptr, _bgbak_ptr, 8, h); @@ -2256,7 +2259,6 @@ void Gdi::resetBackground(int top, int bottom, int strip) _numLinesToProcess = bottom - top; if (_numLinesToProcess) { if ((_vm->_features & GF_AFTER_V6) || (_vm->_vars[_vm->VAR_CURRENT_LIGHTS] & LIGHTMODE_screen)) { -// if (1 /*_vm->_vars[VAR_V5_DRAWFLAGS]&2*/ ) { if (_vm->hasCharsetMask(strip << 3, top, (strip + 1) << 3, bottom)) draw8ColWithMasking(); else |