We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 85fca26 commit 71e63a7Copy full SHA for 71e63a7
1 file changed
Source/PC/Graphics_PC.cpp
@@ -695,6 +695,14 @@ bool cGraphics_PC::Sprite_OnScreen_Check() {
695
mFodder->mVideo_Draw_Columns -= ax;
696
ax >>= 1;
697
mFodder->mVideo_Draw_FrameDataPtr += ax;
698
+
699
+ // Ensure the destination X never remains negative after clipping.
700
+ // A remaining -1 here would underflow the destination pointer in Video_Draw_8.
701
+ if (mFodder->mVideo_Draw_PosX < 0)
702
+ {
703
+ ++mFodder->mVideo_Draw_PosX;
704
+ --mFodder->mVideo_Draw_Columns;
705
+ }
706
}
707
708
ax = mFodder->mVideo_Draw_PosX + mFodder->mVideo_Draw_Columns;
0 commit comments