engine: remove preceding assertion failure, continue loop then instead.

Interestingly, that test case then appears to be drawn fully. Heh.
Also, move one clamp from r1874 one up in the data flow chain.
Doesn't seem to break textured overhead map view with Last Pissed Time.

git-svn-id: https://svn.eduke32.com/eduke32@3878 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2013-06-13 17:11:00 +00:00
parent ee4ef76365
commit 2b61290666

View file

@ -6721,13 +6721,15 @@ static void fillpolygon(int32_t npoints)
for (z=npoints-1; z>=0; z--)
{
const int32_t zz=xb1[z];
const int32_t y1=ry1[z], y2=ry1[zz];
// NOTE: clamp for crash prevention... :-/
// r1874 says: "Fix more overheadmap crashes, this time with 'Last
// Pissed Time'"
const int32_t day1 = clamp(y1>>12, 0, ydim-1);
const int32_t day2 = clamp(y2>>12, 0, ydim-1);
const int32_t y1 = clamp(ry1[z], 0, (ydim<<12)-1);
const int32_t y2 = clamp(ry1[zz], 0, (ydim<<12)-1);
const int32_t day1 = y1>>12;
const int32_t day2 = y2>>12;
if (day1 != day2)
{
@ -6797,7 +6799,8 @@ static void fillpolygon(int32_t npoints)
if (x1 > x2)
continue;
Bassert((unsigned)x1 < xdim+0u || (unsigned)x2 < xdim+0u);
if ((unsigned)x1 >= xdim+0u || (unsigned)x2 >= xdim+0u)
continue;
if (globalpolytype < 1)
{