rename "ffloor" global to "visffloor"
prevent name conflicts with a bunch of local variables named "ffloor"
This commit is contained in:
1 parent
363f4c56f4
commit
9be5780597
4 files changed
+99
-97
No files matched your search
+31
-31
@@ -842,9 +842,9 @@ static void R_Subsector(size_t num)
|
||||
ceilingplane = NULL;
|
||||
|
||||
numffloors = 0;
|
||||
ffloor[numffloors].slope = NULL;
|
||||
ffloor[numffloors].plane = NULL;
|
||||
ffloor[numffloors].polyobj = NULL;
|
||||
visffloor[numffloors].slope = NULL;
|
||||
visffloor[numffloors].plane = NULL;
|
||||
visffloor[numffloors].polyobj = NULL;
|
||||
|
||||
if (frontsector->ffloors)
|
||||
{
|
||||
@@ -864,8 +864,8 @@ static void R_Subsector(size_t num)
|
||||
}
|
||||
}
|
||||
|
||||
ffloor[numffloors].plane = NULL;
|
||||
ffloor[numffloors].polyobj = NULL;
|
||||
visffloor[numffloors].plane = NULL;
|
||||
visffloor[numffloors].polyobj = NULL;
|
||||
|
||||
heightcheck = P_GetFFloorBottomZAt(rover, viewx, viewy);
|
||||
planecenterz = P_GetFFloorBottomZAt(rover, frontsector->soundorg.x, frontsector->soundorg.y);
|
||||
@@ -878,7 +878,7 @@ static void R_Subsector(size_t num)
|
||||
light = R_GetPlaneLight(frontsector, planecenterz,
|
||||
viewz < heightcheck);
|
||||
|
||||
ffloor[numffloors].plane = R_FindPlane(
|
||||
visffloor[numffloors].plane = R_FindPlane(
|
||||
*rover->bottomheight, *rover->bottompic,
|
||||
*frontsector->lightlist[light].lightlevel,
|
||||
*rover->bottomxoffs, *rover->bottomyoffs, *rover->bottomangle,
|
||||
@@ -888,22 +888,22 @@ static void R_Subsector(size_t num)
|
||||
, R_NoEncore(rover->master->frontsector, true), true, frontsector
|
||||
);
|
||||
|
||||
ffloor[numffloors].slope = *rover->b_slope;
|
||||
visffloor[numffloors].slope = *rover->b_slope;
|
||||
|
||||
// Tell the renderer this sector has slopes in it.
|
||||
if (ffloor[numffloors].slope)
|
||||
if (visffloor[numffloors].slope)
|
||||
frontsector->hasslope = true;
|
||||
|
||||
ffloor[numffloors].height = heightcheck;
|
||||
ffloor[numffloors].ffloor = rover;
|
||||
visffloor[numffloors].height = heightcheck;
|
||||
visffloor[numffloors].ffloor = rover;
|
||||
numffloors++;
|
||||
}
|
||||
|
||||
if (numffloors >= MAXFFLOORS)
|
||||
break;
|
||||
|
||||
ffloor[numffloors].plane = NULL;
|
||||
ffloor[numffloors].polyobj = NULL;
|
||||
visffloor[numffloors].plane = NULL;
|
||||
visffloor[numffloors].polyobj = NULL;
|
||||
|
||||
heightcheck = P_GetFFloorTopZAt(rover, viewx, viewy);
|
||||
planecenterz = P_GetFFloorTopZAt(rover, frontsector->soundorg.x, frontsector->soundorg.y);
|
||||
@@ -915,7 +915,7 @@ static void R_Subsector(size_t num)
|
||||
{
|
||||
light = R_GetPlaneLight(frontsector, planecenterz, viewz < heightcheck);
|
||||
|
||||
ffloor[numffloors].plane = R_FindPlane(
|
||||
visffloor[numffloors].plane = R_FindPlane(
|
||||
*rover->topheight, *rover->toppic,
|
||||
*frontsector->lightlist[light].lightlevel,
|
||||
*rover->topxoffs, *rover->topyoffs, *rover->topangle,
|
||||
@@ -925,14 +925,14 @@ static void R_Subsector(size_t num)
|
||||
, R_NoEncore(rover->master->frontsector, false), false, frontsector
|
||||
);
|
||||
|
||||
ffloor[numffloors].slope = *rover->t_slope;
|
||||
visffloor[numffloors].slope = *rover->t_slope;
|
||||
|
||||
// Tell the renderer this sector has slopes in it.
|
||||
if (ffloor[numffloors].slope)
|
||||
if (visffloor[numffloors].slope)
|
||||
frontsector->hasslope = true;
|
||||
|
||||
ffloor[numffloors].height = heightcheck;
|
||||
ffloor[numffloors].ffloor = rover;
|
||||
visffloor[numffloors].height = heightcheck;
|
||||
visffloor[numffloors].ffloor = rover;
|
||||
numffloors++;
|
||||
}
|
||||
}
|
||||
@@ -956,49 +956,49 @@ static void R_Subsector(size_t num)
|
||||
}
|
||||
|
||||
polysec = po->lines[0]->backsector;
|
||||
ffloor[numffloors].plane = NULL;
|
||||
visffloor[numffloors].plane = NULL;
|
||||
|
||||
if (polysec->floorheight <= ceilingcenterz
|
||||
&& polysec->floorheight >= floorcenterz
|
||||
&& (viewz < polysec->floorheight))
|
||||
{
|
||||
light = R_GetPlaneLight(frontsector, polysec->floorheight, viewz < polysec->floorheight);
|
||||
ffloor[numffloors].plane = R_FindPlane(polysec->floorheight, polysec->floorpic,
|
||||
visffloor[numffloors].plane = R_FindPlane(polysec->floorheight, polysec->floorpic,
|
||||
(light == -1 ? frontsector->lightlevel : *frontsector->lightlist[light].lightlevel), polysec->floor_xoffs, polysec->floor_yoffs,
|
||||
polysec->floorpic_angle-po->angle,
|
||||
(light == -1 ? frontsector->extra_colormap : frontsector->lightlist[light].extra_colormap), NULL, po
|
||||
,NULL // will ffloors be slopable eventually?
|
||||
, R_NoEncore(polysec, false), false, frontsector);
|
||||
|
||||
ffloor[numffloors].height = polysec->floorheight;
|
||||
ffloor[numffloors].polyobj = po;
|
||||
ffloor[numffloors].slope = NULL;
|
||||
// ffloor[numffloors].ffloor = rover;
|
||||
po->visplane = ffloor[numffloors].plane;
|
||||
visffloor[numffloors].height = polysec->floorheight;
|
||||
visffloor[numffloors].polyobj = po;
|
||||
visffloor[numffloors].slope = NULL;
|
||||
// visffloor[numffloors].ffloor = rover;
|
||||
po->visplane = visffloor[numffloors].plane;
|
||||
numffloors++;
|
||||
}
|
||||
|
||||
if (numffloors >= MAXFFLOORS)
|
||||
break;
|
||||
|
||||
ffloor[numffloors].plane = NULL;
|
||||
visffloor[numffloors].plane = NULL;
|
||||
|
||||
if (polysec->ceilingheight >= floorcenterz
|
||||
&& polysec->ceilingheight <= ceilingcenterz
|
||||
&& (viewz > polysec->ceilingheight))
|
||||
{
|
||||
light = R_GetPlaneLight(frontsector, polysec->floorheight, viewz < polysec->floorheight);
|
||||
ffloor[numffloors].plane = R_FindPlane(polysec->ceilingheight, polysec->ceilingpic,
|
||||
visffloor[numffloors].plane = R_FindPlane(polysec->ceilingheight, polysec->ceilingpic,
|
||||
(light == -1 ? frontsector->lightlevel : *frontsector->lightlist[light].lightlevel), polysec->ceiling_xoffs, polysec->ceiling_yoffs, polysec->ceilingpic_angle-po->angle,
|
||||
(light == -1 ? frontsector->extra_colormap : frontsector->lightlist[light].extra_colormap), NULL, po
|
||||
,NULL // will ffloors be slopable eventually?
|
||||
, R_NoEncore(polysec, true), false, frontsector);
|
||||
|
||||
ffloor[numffloors].polyobj = po;
|
||||
ffloor[numffloors].height = polysec->ceilingheight;
|
||||
ffloor[numffloors].slope = NULL;
|
||||
// ffloor[numffloors].ffloor = rover;
|
||||
po->visplane = ffloor[numffloors].plane;
|
||||
visffloor[numffloors].polyobj = po;
|
||||
visffloor[numffloors].height = polysec->ceilingheight;
|
||||
visffloor[numffloors].slope = NULL;
|
||||
// visffloor[numffloors].ffloor = rover;
|
||||
po->visplane = visffloor[numffloors].plane;
|
||||
numffloors++;
|
||||
}
|
||||
|
||||
|
||||
+7
-6
@@ -53,7 +53,7 @@ static visplane_t **freehead = &freetail;
|
||||
visplane_t *floorplane;
|
||||
visplane_t *ceilingplane;
|
||||
|
||||
visffloor_t ffloor[MAXFFLOORS];
|
||||
visffloor_t visffloor[MAXFFLOORS];
|
||||
INT32 numffloors;
|
||||
|
||||
//SoM: 3/23/2000: Boom visplane hashing routine.
|
||||
@@ -134,8 +134,9 @@ void R_AllocPlaneMemory(void)
|
||||
|
||||
for (unsigned i = 0; i < MAXFFLOORS; i++)
|
||||
{
|
||||
ffloor[i].f_clip = ffloor_f_clip + (i * viewwidth);
|
||||
ffloor[i].c_clip = ffloor_c_clip + (i * viewwidth);
|
||||
visffloor_t *ffloor = &visffloor[i];
|
||||
ffloor->f_clip = ffloor_f_clip + (i * viewwidth);
|
||||
ffloor->c_clip = ffloor_c_clip + (i * viewwidth);
|
||||
}
|
||||
|
||||
yslopetab = static_cast<fixed_t*>(Z_Realloc(yslopetab, sizeof(*yslopetab) * (viewheight * 16), PU_STATIC, NULL));
|
||||
@@ -313,9 +314,9 @@ void R_ClearFFloorClips(void)
|
||||
// opening / clipping determination
|
||||
for (p = 0; p < MAXFFLOORS; p++)
|
||||
{
|
||||
visffloor_t *fffloor = &ffloor[p];
|
||||
std::fill(fffloor->f_clip, fffloor->f_clip + viewwidth, static_cast<INT16>(viewheight));
|
||||
std::fill(fffloor->c_clip, fffloor->c_clip + viewwidth, static_cast<INT16>(-1));
|
||||
visffloor_t *ffloor = &visffloor[p];
|
||||
std::fill(ffloor->f_clip, ffloor->f_clip + viewwidth, static_cast<INT16>(viewheight));
|
||||
std::fill(ffloor->c_clip, ffloor->c_clip + viewwidth, static_cast<INT16>(-1));
|
||||
}
|
||||
|
||||
numffloors = 0;
|
||||
|
||||
+1
-1
@@ -114,7 +114,7 @@ typedef struct planemgr_s
|
||||
polyobj_t *polyobj;
|
||||
} visffloor_t;
|
||||
|
||||
extern visffloor_t ffloor[MAXFFLOORS];
|
||||
extern visffloor_t visffloor[MAXFFLOORS];
|
||||
extern INT32 numffloors;
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
+60
-59
@@ -1244,13 +1244,13 @@ static void R_RenderSegLoop(drawcolumndata_t* dc)
|
||||
|
||||
for (i = 0; i < numffloors; i++)
|
||||
{
|
||||
if (ffloor[i].polyobj && (!curline->polyseg || ffloor[i].polyobj != curline->polyseg))
|
||||
if (visffloor[i].polyobj && (!curline->polyseg || visffloor[i].polyobj != curline->polyseg))
|
||||
continue;
|
||||
|
||||
if (ffloor[i].height < viewz)
|
||||
if (visffloor[i].height < viewz)
|
||||
{
|
||||
INT32 top_w = (ffloor[i].f_frac >> HEIGHTBITS) + 1;
|
||||
INT32 bottom_w = ffloor[i].f_clip[rw_x];
|
||||
INT32 top_w = (visffloor[i].f_frac >> HEIGHTBITS) + 1;
|
||||
INT32 bottom_w = visffloor[i].f_clip[rw_x];
|
||||
|
||||
if (top_w < top)
|
||||
top_w = top;
|
||||
@@ -1259,22 +1259,22 @@ static void R_RenderSegLoop(drawcolumndata_t* dc)
|
||||
bottom_w = bottom;
|
||||
|
||||
// Polyobject-specific hack to fix plane leaking -Red
|
||||
if (ffloor[i].polyobj && top_w >= bottom_w)
|
||||
if (visffloor[i].polyobj && top_w >= bottom_w)
|
||||
{
|
||||
ffloor[i].plane->top[rw_x] = 0xFFFF;
|
||||
ffloor[i].plane->bottom[rw_x] = 0x0000; // fix for sky plane drawing crashes - Monster Iestyn 25/05/18
|
||||
visffloor[i].plane->top[rw_x] = 0xFFFF;
|
||||
visffloor[i].plane->bottom[rw_x] = 0x0000; // fix for sky plane drawing crashes - Monster Iestyn 25/05/18
|
||||
}
|
||||
else if (top_w <= bottom_w)
|
||||
{
|
||||
fftop = (INT16)top_w;
|
||||
ffbottom = (INT16)bottom_w;
|
||||
|
||||
ffloor[i].plane->top[rw_x] = fftop;
|
||||
ffloor[i].plane->bottom[rw_x] = ffbottom;
|
||||
visffloor[i].plane->top[rw_x] = fftop;
|
||||
visffloor[i].plane->bottom[rw_x] = ffbottom;
|
||||
|
||||
// Lactozilla: Cull part of the column by the 3D floor if it can't be seen
|
||||
// "bottom" is the top pixel of the floor column
|
||||
if (ffbottom >= bottom-1 && R_FFloorCanClip(&ffloor[i]) && !curline->polyseg)
|
||||
if (ffbottom >= bottom-1 && R_FFloorCanClip(&visffloor[i]) && !curline->polyseg)
|
||||
{
|
||||
rw_floormarked = true;
|
||||
floorclip[rw_x] = fftop;
|
||||
@@ -1293,10 +1293,10 @@ static void R_RenderSegLoop(drawcolumndata_t* dc)
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (ffloor[i].height > viewz)
|
||||
else if (visffloor[i].height > viewz)
|
||||
{
|
||||
INT32 top_w = ffloor[i].c_clip[rw_x] + 1;
|
||||
INT32 bottom_w = (ffloor[i].f_frac >> HEIGHTBITS);
|
||||
INT32 top_w = visffloor[i].c_clip[rw_x] + 1;
|
||||
INT32 bottom_w = (visffloor[i].f_frac >> HEIGHTBITS);
|
||||
|
||||
if (top_w < top)
|
||||
top_w = top;
|
||||
@@ -1305,22 +1305,22 @@ static void R_RenderSegLoop(drawcolumndata_t* dc)
|
||||
bottom_w = bottom;
|
||||
|
||||
// Polyobject-specific hack to fix plane leaking -Red
|
||||
if (ffloor[i].polyobj && top_w >= bottom_w)
|
||||
if (visffloor[i].polyobj && top_w >= bottom_w)
|
||||
{
|
||||
ffloor[i].plane->top[rw_x] = 0xFFFF;
|
||||
ffloor[i].plane->bottom[rw_x] = 0x0000; // fix for sky plane drawing crashes - Monster Iestyn 25/05/18
|
||||
visffloor[i].plane->top[rw_x] = 0xFFFF;
|
||||
visffloor[i].plane->bottom[rw_x] = 0x0000; // fix for sky plane drawing crashes - Monster Iestyn 25/05/18
|
||||
}
|
||||
else if (top_w <= bottom_w)
|
||||
{
|
||||
fftop = (INT16)top_w;
|
||||
ffbottom = (INT16)bottom_w;
|
||||
|
||||
ffloor[i].plane->top[rw_x] = fftop;
|
||||
ffloor[i].plane->bottom[rw_x] = ffbottom;
|
||||
visffloor[i].plane->top[rw_x] = fftop;
|
||||
visffloor[i].plane->bottom[rw_x] = ffbottom;
|
||||
|
||||
// Lactozilla: Cull part of the column by the 3D floor if it can't be seen
|
||||
// "top" is the height of the ceiling column
|
||||
if (fftop <= top+1 && R_FFloorCanClip(&ffloor[i]) && !curline->polyseg)
|
||||
if (fftop <= top+1 && R_FFloorCanClip(&visffloor[i]) && !curline->polyseg)
|
||||
{
|
||||
rw_ceilingmarked = true;
|
||||
ceilingclip[rw_x] = ffbottom;
|
||||
@@ -1538,19 +1538,19 @@ static void R_RenderSegLoop(drawcolumndata_t* dc)
|
||||
|
||||
for (i = 0; i < numffloors; i++)
|
||||
{
|
||||
if (curline->polyseg && (ffloor[i].polyobj != curline->polyseg))
|
||||
if (curline->polyseg && (visffloor[i].polyobj != curline->polyseg))
|
||||
continue;
|
||||
|
||||
ffloor[i].f_frac += ffloor[i].f_step;
|
||||
visffloor[i].f_frac += visffloor[i].f_step;
|
||||
}
|
||||
|
||||
for (i = 0; i < numbackffloors; i++)
|
||||
{
|
||||
if (curline->polyseg && (ffloor[i].polyobj != curline->polyseg))
|
||||
if (curline->polyseg && (visffloor[i].polyobj != curline->polyseg))
|
||||
continue;
|
||||
|
||||
ffloor[i].f_clip[rw_x] = ffloor[i].c_clip[rw_x] = (INT16)((ffloor[i].b_frac >> HEIGHTBITS) & 0xFFFF);
|
||||
ffloor[i].b_frac += ffloor[i].b_step;
|
||||
visffloor[i].f_clip[rw_x] = visffloor[i].c_clip[rw_x] = (INT16)((visffloor[i].b_frac >> HEIGHTBITS) & 0xFFFF);
|
||||
visffloor[i].b_frac += visffloor[i].b_step;
|
||||
}
|
||||
|
||||
rw_scale += rw_scalestep;
|
||||
@@ -1881,11 +1881,11 @@ void R_StoreWallRange(INT32 start, INT32 stop)
|
||||
{
|
||||
for (i = 0; i < numffloors; i++)
|
||||
{
|
||||
if (ffloor[i].polyobj && (!ds_p->curline->polyseg || ffloor[i].polyobj != ds_p->curline->polyseg))
|
||||
if (visffloor[i].polyobj && (!ds_p->curline->polyseg || visffloor[i].polyobj != ds_p->curline->polyseg))
|
||||
continue;
|
||||
|
||||
ffloor[i].f_pos = P_GetZAt(ffloor[i].slope, segleft .x, segleft .y, ffloor[i].height) - viewz;
|
||||
ffloor[i].f_pos_slope = P_GetZAt(ffloor[i].slope, segright.x, segright.y, ffloor[i].height) - viewz;
|
||||
visffloor[i].f_pos = P_GetZAt(visffloor[i].slope, segleft .x, segleft .y, visffloor[i].height) - viewz;
|
||||
visffloor[i].f_pos_slope = P_GetZAt(visffloor[i].slope, segright.x, segright.y, visffloor[i].height) - viewz;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2630,19 +2630,19 @@ void R_StoreWallRange(INT32 start, INT32 stop)
|
||||
{
|
||||
for (i = 0; i < numffloors; i++)
|
||||
{
|
||||
ffloor[i].f_pos >>= 4;
|
||||
ffloor[i].f_pos_slope >>= 4;
|
||||
visffloor[i].f_pos >>= 4;
|
||||
visffloor[i].f_pos_slope >>= 4;
|
||||
|
||||
if (linedef->special == HORIZONSPECIAL) // Horizon lines extend FOFs in contact with them too.
|
||||
{
|
||||
ffloor[i].f_step = 0;
|
||||
ffloor[i].f_frac = (centeryfrac>>4);
|
||||
visffloor[i].f_step = 0;
|
||||
visffloor[i].f_frac = (centeryfrac>>4);
|
||||
topfrac++; // Prevent 1px HOM
|
||||
}
|
||||
else
|
||||
{
|
||||
ffloor[i].f_frac = (centeryfrac>>4) - FixedMul(ffloor[i].f_pos, rw_scale);
|
||||
ffloor[i].f_step = ((centeryfrac>>4) - FixedMul(ffloor[i].f_pos_slope, ds_p->scale2) - ffloor[i].f_frac)/(range);
|
||||
visffloor[i].f_frac = (centeryfrac>>4) - FixedMul(visffloor[i].f_pos, rw_scale);
|
||||
visffloor[i].f_step = ((centeryfrac>>4) - FixedMul(visffloor[i].f_pos_slope, ds_p->scale2) - visffloor[i].f_frac)/(range);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2686,14 +2686,14 @@ void R_StoreWallRange(INT32 start, INT32 stop)
|
||||
|
||||
auto setup_back_fof = [&]
|
||||
{
|
||||
//ffloor[i].slope = *rover->b_slope;
|
||||
ffloor[i].b_pos = roverleft;
|
||||
ffloor[i].b_pos_slope = roverright;
|
||||
ffloor[i].b_pos >>= 4;
|
||||
ffloor[i].b_pos_slope >>= 4;
|
||||
ffloor[i].b_frac = (centeryfrac >> 4) - FixedMul(ffloor[i].b_pos, rw_scale);
|
||||
ffloor[i].b_step = (centeryfrac >> 4) - FixedMul(ffloor[i].b_pos_slope, ds_p->scale2);
|
||||
ffloor[i].b_step = (ffloor[i].b_step-ffloor[i].b_frac)/(range);
|
||||
//visffloor[i].slope = *rover->b_slope;
|
||||
visffloor[i].b_pos = roverleft;
|
||||
visffloor[i].b_pos_slope = roverright;
|
||||
visffloor[i].b_pos >>= 4;
|
||||
visffloor[i].b_pos_slope >>= 4;
|
||||
visffloor[i].b_frac = (centeryfrac >> 4) - FixedMul(visffloor[i].b_pos, rw_scale);
|
||||
visffloor[i].b_step = (centeryfrac >> 4) - FixedMul(visffloor[i].b_pos_slope, ds_p->scale2);
|
||||
visffloor[i].b_step = (visffloor[i].b_step-visffloor[i].b_frac)/(range);
|
||||
};
|
||||
|
||||
if (backsector->ffloors)
|
||||
@@ -2788,20 +2788,20 @@ void R_StoreWallRange(INT32 start, INT32 stop)
|
||||
{
|
||||
auto setup_back_polyobj = [&](fixed_t height)
|
||||
{
|
||||
if (ffloor[i].plane->minx > ds_p->x1)
|
||||
ffloor[i].plane->minx = ds_p->x1;
|
||||
if (visffloor[i].plane->minx > ds_p->x1)
|
||||
visffloor[i].plane->minx = ds_p->x1;
|
||||
|
||||
if (ffloor[i].plane->maxx < ds_p->x2)
|
||||
ffloor[i].plane->maxx = ds_p->x2;
|
||||
if (visffloor[i].plane->maxx < ds_p->x2)
|
||||
visffloor[i].plane->maxx = ds_p->x2;
|
||||
|
||||
ffloor[i].slope = NULL;
|
||||
ffloor[i].b_pos = height;
|
||||
ffloor[i].b_pos = (ffloor[i].b_pos - viewz) >> 4;
|
||||
ffloor[i].b_step = FixedMul(-rw_scalestep, ffloor[i].b_pos);
|
||||
ffloor[i].b_frac = (centeryfrac >> 4) - FixedMul(ffloor[i].b_pos, rw_scale);
|
||||
visffloor[i].slope = NULL;
|
||||
visffloor[i].b_pos = height;
|
||||
visffloor[i].b_pos = (visffloor[i].b_pos - viewz) >> 4;
|
||||
visffloor[i].b_step = FixedMul(-rw_scalestep, visffloor[i].b_pos);
|
||||
visffloor[i].b_frac = (centeryfrac >> 4) - FixedMul(visffloor[i].b_pos, rw_scale);
|
||||
};
|
||||
|
||||
while (i < numffloors && ffloor[i].polyobj != curline->polyseg)
|
||||
while (i < numffloors && visffloor[i].polyobj != curline->polyseg)
|
||||
i++;
|
||||
|
||||
if (i < numffloors && backsector->floorheight <= frontsector->ceilingheight &&
|
||||
@@ -2862,8 +2862,8 @@ void R_StoreWallRange(INT32 start, INT32 stop)
|
||||
|
||||
for (i = 0; i < numffloors; i++)
|
||||
{
|
||||
ds_p->ffloorplanes[i] = ffloor[i].plane =
|
||||
R_CheckPlane(ffloor[i].plane, rw_x, rw_stopx - 1);
|
||||
ds_p->ffloorplanes[i] = visffloor[i].plane =
|
||||
R_CheckPlane(visffloor[i].plane, rw_x, rw_stopx - 1);
|
||||
}
|
||||
|
||||
firstseg = ds_p;
|
||||
@@ -2871,7 +2871,7 @@ void R_StoreWallRange(INT32 start, INT32 stop)
|
||||
else
|
||||
{
|
||||
for (i = 0; i < numffloors; i++)
|
||||
R_ExpandPlane(ffloor[i].plane, rw_x, rw_stopx - 1);
|
||||
R_ExpandPlane(visffloor[i].plane, rw_x, rw_stopx - 1);
|
||||
}
|
||||
|
||||
// FIXME hack to fix planes disappearing when a seg goes behind the camera. This NEEDS to be changed to be done properly. -Red
|
||||
@@ -2879,13 +2879,14 @@ void R_StoreWallRange(INT32 start, INT32 stop)
|
||||
{
|
||||
for (i = 0; i < numffloors; i++)
|
||||
{
|
||||
if (!ffloor[i].polyobj || ffloor[i].polyobj != curline->polyseg)
|
||||
if (!visffloor[i].polyobj || visffloor[i].polyobj != curline->polyseg)
|
||||
continue;
|
||||
if (ffloor[i].plane->minx > rw_x)
|
||||
ffloor[i].plane->minx = rw_x;
|
||||
|
||||
if (ffloor[i].plane->maxx < rw_stopx - 1)
|
||||
ffloor[i].plane->maxx = rw_stopx - 1;
|
||||
if (visffloor[i].plane->minx > rw_x)
|
||||
visffloor[i].plane->minx = rw_x;
|
||||
|
||||
if (visffloor[i].plane->maxx < rw_stopx - 1)
|
||||
visffloor[i].plane->maxx = rw_stopx - 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user