mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 17:01:28 +00:00
CON: Remove bounds check on rotatesprite coordinates.
git-svn-id: https://svn.eduke32.com/eduke32@5973 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
0b75ca3ec1
commit
9627f24d54
3 changed files with 0 additions and 17 deletions
|
@ -2904,12 +2904,6 @@ nullquote:
|
|||
continue;
|
||||
}
|
||||
|
||||
if (EDUKE32_PREDICT_FALSE(pos.x < -(320<<16) || pos.x >= (640<<16) || pos.y < -(200<<16) || pos.y >= (400<<16)))
|
||||
{
|
||||
CON_ERRPRINTF("invalid coordinates: %d, %d\n", pos.x, pos.y);
|
||||
continue;
|
||||
}
|
||||
|
||||
int32_t blendidx = 0;
|
||||
|
||||
NEG_ALPHA_TO_BLEND(alpha, blendidx, orientation);
|
||||
|
|
|
@ -402,15 +402,6 @@ function _rotspr(x, y, zoom, ang, tilenum, shade, pal, orientation,
|
|||
y = 65536*y
|
||||
end
|
||||
|
||||
-- XXX: This is the same as the check in gameexec.c, but ideally we'd want
|
||||
-- rotatesprite to accept all coordinates and simply draw nothing if the
|
||||
-- tile's bounding rectange is beyond the screen.
|
||||
-- XXX: Currently, classic rotatesprite() is not correct with some large
|
||||
-- zoom values.
|
||||
if (not (x >= -320*65536 and x < 640*65536) or not (y >= -200*65536 and y < 400*65536)) then
|
||||
error(format("invalid coordinates (%.03f, %.03f)", x, y), 2)
|
||||
end
|
||||
|
||||
local blendidx = 0
|
||||
if (alpha < 0) then
|
||||
-- See NEG_ALPHA_TO_BLEND.
|
||||
|
|
|
@ -2999,8 +2999,6 @@ dodefault:
|
|||
y<<=16;
|
||||
}
|
||||
|
||||
// NOTE: Unlike CON, no error on large x/y.
|
||||
|
||||
orientation &= (ROTATESPRITE_MAX-1);
|
||||
|
||||
rotatesprite_(x,y,z,a,tilenum,shade,pal,2|orientation,alpha,0,x1,y1,x2,y2);
|
||||
|
|
Loading…
Reference in a new issue