diff options
Diffstat (limited to 'engines/agi/picture.cpp')
-rw-r--r-- | engines/agi/picture.cpp | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/engines/agi/picture.cpp b/engines/agi/picture.cpp index 6665e8ed4a..81a4f5a743 100644 --- a/engines/agi/picture.cpp +++ b/engines/agi/picture.cpp @@ -28,6 +28,7 @@ #include "agi/agi.h" #include "agi/graphics.h" + namespace Agi { #define nextByte data[foffs++] @@ -225,7 +226,7 @@ void PictureMgr::dynamicDrawLine() { putVirtPixel(x1, y1); for (;;) { - if ((disp = nextByte) >= 0xf0) + if ((disp = nextByte) >= 0xe0) break; dx = ((disp & 0xf0) >> 4) & 0x0f; @@ -256,10 +257,10 @@ void PictureMgr::absoluteDrawLine() { putVirtPixel(x1, y1); for (;;) { - if ((x2 = nextByte) >= 0xf0) + if ((x2 = nextByte) >= 0xe0) break; - if ((y2 = nextByte) >= 0xf0) + if ((y2 = nextByte) >= 0xe0) break; drawLine(x1, y1, x2, y2); @@ -362,14 +363,14 @@ void PictureMgr::xCorner() { for (;;) { x2 = nextByte; - if (x2 >= 0xf0) + if (x2 >= 0xe0) break; drawLine(x1, y1, x2, y1); x1 = x2; y2 = nextByte; - if (y2 >= 0xf0) + if (y2 >= 0xe0) break; drawLine(x1, y1, x1, y2); @@ -393,14 +394,14 @@ void PictureMgr::yCorner() { for (;;) { y2 = nextByte; - if (y2 >= 0xF0) + if (y2 >= 0xe0) break; drawLine(x1, y1, x1, y2); y1 = y2; x2 = nextByte; - if (x2 >= 0xf0) + if (x2 >= 0xe0) break; drawLine(x1, y1, x2, y1); @@ -418,7 +419,7 @@ void PictureMgr::yCorner() { void PictureMgr::fill() { int x1, y1; - while ((x1 = nextByte) < 0xF0 && (y1 = nextByte) < 0xf0) + while ((x1 = nextByte) < 0xe0 && (y1 = nextByte) < 0xe0) agiFill(x1, y1); foffs--; @@ -480,15 +481,15 @@ void PictureMgr::plotBrush() { for (;;) { if (patCode & 0x20) { - if ((patNum = nextByte) >= 0xF0) + if ((patNum = nextByte) >= 0xe0) break; patNum = (patNum >> 1) & 0x7f; } - if ((x1 = nextByte) >= 0xf0) + if ((x1 = nextByte) >= 0xe0) break; - if ((y1 = nextByte) >= 0xf0) + if ((y1 = nextByte) >= 0xe0) break; plotPattern(x1, y1); @@ -734,6 +735,9 @@ void PictureMgr::drawPictureV2() { break; case 0xf9: /* set pattern */ patCode = nextByte; + + if (_vm->getGameType() == GType_PreAGI) + plotBrush(); break; case 0xfA: /* plot brush */ plotBrush(); |