Fix regression in scrolling rooms.

svn-id: r41624
This commit is contained in:
Travis Howell 2009-06-18 06:10:13 +00:00
parent 68cb22d4a9
commit b8a9823f4e

View File

@ -155,11 +155,11 @@ struct VirtScreen : Graphics::Surface {
}
byte *getPixels(int x, int y) const {
return (byte *)pixels + y * pitch + (xstart * 2 + x) * bytesPerPixel;
return (byte *)pixels + y * pitch + (xstart + x) * bytesPerPixel;
}
byte *getBackPixels(int x, int y) const {
return (byte *)backBuf + y * pitch + (xstart * 2 + x) * bytesPerPixel;
return (byte *)backBuf + y * pitch + (xstart + x) * bytesPerPixel;
}
};