diff options
-rw-r--r-- | engines/draci/font.cpp | 11 | ||||
-rw-r--r-- | engines/draci/game.cpp | 2 |
2 files changed, 8 insertions, 5 deletions
diff --git a/engines/draci/font.cpp b/engines/draci/font.cpp index a3a261e293..4902965aa3 100644 --- a/engines/draci/font.cpp +++ b/engines/draci/font.cpp @@ -158,6 +158,10 @@ void Font::drawChar(Surface *dst, uint8 chr, int tx, int ty, bool markDirty) con int curr = y * _maxCharWidth + x; int colour = _charData[charOffset + curr]; + // If pixel is transparent, skip it + if (colour == _transparent) + continue; + // Replace colour with font colours switch (colour) { @@ -177,10 +181,9 @@ void Font::drawChar(Surface *dst, uint8 chr, int tx, int ty, bool markDirty) con colour = kFontColour4; break; } - - // Paint pixel (if not transparent) - if (colour != _transparent) - ptr[x] = colour; + + // Paint the pixel + ptr[x] = colour; } // Advance to next row diff --git a/engines/draci/game.cpp b/engines/draci/game.cpp index 08207d4574..58eb10a0ce 100644 --- a/engines/draci/game.cpp +++ b/engines/draci/game.cpp @@ -54,7 +54,7 @@ Game::Game(DraciEngine *vm) : _vm(vm) { for (i = 0; i < numPersons; ++i) { _persons[i]._x = personData.readUint16LE(); _persons[i]._y = personData.readUint16LE(); - _persons[i]._fontColour = personData.readByte() - 1; + _persons[i]._fontColour = personData.readByte(); } // Close persons file |