mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-12 23:54:17 +00:00
- fixed: Rendering 2-sided walls with 3D floor light effects had the 'is3dfloor' flag of GetLightLevel inverted.
This commit is contained in:
parent
fadc7de636
commit
7242a0ef94
2 changed files with 7 additions and 7 deletions
|
@ -978,7 +978,7 @@ struct side_t
|
||||||
BYTE Flags;
|
BYTE Flags;
|
||||||
int Index; // needed to access custom UDMF fields which are stored in loading order.
|
int Index; // needed to access custom UDMF fields which are stored in loading order.
|
||||||
|
|
||||||
int GetLightLevel (bool foggy, int baselight, bool noabsolute=false, int *pfakecontrast_usedbygzdoom=NULL) const;
|
int GetLightLevel (bool foggy, int baselight, bool is3dlight=false, int *pfakecontrast_usedbygzdoom=NULL) const;
|
||||||
|
|
||||||
void SetLight(SWORD l)
|
void SetLight(SWORD l)
|
||||||
{
|
{
|
||||||
|
|
|
@ -272,17 +272,17 @@ void R_RenderMaskedSegRange (drawseg_t *ds, int x1, int x2)
|
||||||
|
|
||||||
if (fixedlightlev < 0)
|
if (fixedlightlev < 0)
|
||||||
{
|
{
|
||||||
|
if (!(fake3D & FAKE3D_CLIPTOP))
|
||||||
|
{
|
||||||
|
sclipTop = sec->ceilingplane.ZatPoint(viewx, viewy);
|
||||||
|
}
|
||||||
for (i = frontsector->e->XFloor.lightlist.Size() - 1; i >= 0; i--)
|
for (i = frontsector->e->XFloor.lightlist.Size() - 1; i >= 0; i--)
|
||||||
{
|
{
|
||||||
if (!(fake3D & FAKE3D_CLIPTOP))
|
if (sclipTop <= frontsector->e->XFloor.lightlist[i].plane.Zat0())
|
||||||
{
|
|
||||||
sclipTop = sec->ceilingplane.ZatPoint(viewx, viewy);
|
|
||||||
}
|
|
||||||
if (sclipTop <= frontsector->e->XFloor.lightlist[i].plane.ZatPoint(viewx, viewy))
|
|
||||||
{
|
{
|
||||||
lightlist_t *lit = &frontsector->e->XFloor.lightlist[i];
|
lightlist_t *lit = &frontsector->e->XFloor.lightlist[i];
|
||||||
basecolormap = lit->extra_colormap;
|
basecolormap = lit->extra_colormap;
|
||||||
wallshade = LIGHT2SHADE(curline->sidedef->GetLightLevel(foggy, *lit->p_lightlevel, lit->lightsource == NULL) + r_actualextralight);
|
wallshade = LIGHT2SHADE(curline->sidedef->GetLightLevel(foggy, *lit->p_lightlevel, lit->lightsource != NULL) + r_actualextralight);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue