mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
optimised R_ExpandPlane too
This commit is contained in:
parent
5533c97c69
commit
2692d6f9dc
1 changed files with 7 additions and 3 deletions
|
|
@ -625,7 +625,7 @@ visplane_t *R_CheckPlane(visplane_t *pl, INT32 start, INT32 stop)
|
||||||
// overlap.
|
// overlap.
|
||||||
void R_ExpandPlane(visplane_t *pl, INT32 start, INT32 stop)
|
void R_ExpandPlane(visplane_t *pl, INT32 start, INT32 stop)
|
||||||
{
|
{
|
||||||
INT32 unionl, unionh;
|
// INT32 unionl, unionh;
|
||||||
// INT32 x;
|
// INT32 x;
|
||||||
|
|
||||||
#ifdef POLYOBJECTS_PLANES
|
#ifdef POLYOBJECTS_PLANES
|
||||||
|
|
@ -634,6 +634,9 @@ void R_ExpandPlane(visplane_t *pl, INT32 start, INT32 stop)
|
||||||
return;
|
return;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
if (pl->minx > start) pl->minx = start;
|
||||||
|
if (pl->maxx < stop) pl->maxx = stop;
|
||||||
|
/*
|
||||||
if (start < pl->minx)
|
if (start < pl->minx)
|
||||||
{
|
{
|
||||||
unionl = start;
|
unionl = start;
|
||||||
|
|
@ -651,15 +654,16 @@ void R_ExpandPlane(visplane_t *pl, INT32 start, INT32 stop)
|
||||||
{
|
{
|
||||||
unionh = pl->maxx;
|
unionh = pl->maxx;
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
for (x = start; x <= stop; x++)
|
for (x = start; x <= stop; x++)
|
||||||
if (pl->top[x] != 0xffff || pl->bottom[x] != 0x0000)
|
if (pl->top[x] != 0xffff || pl->bottom[x] != 0x0000)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
if (x <= stop)
|
if (x <= stop)
|
||||||
I_Error("R_ExpandPlane: planes in same subsector overlap?!\nminx: %d, maxx: %d, start: %d, stop: %d\n", pl->minx, pl->maxx, start, stop);
|
I_Error("R_ExpandPlane: planes in same subsector overlap?!\nminx: %d, maxx: %d, start: %d, stop: %d\n", pl->minx, pl->maxx, start, stop);
|
||||||
*/
|
|
||||||
pl->minx = unionl, pl->maxx = unionh;
|
pl->minx = unionl, pl->maxx = unionh;
|
||||||
|
*/
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue