- Added a new UDMF sidedef flag: lightfog.

SVN r3933 (trunk)
This commit is contained in:
Randy Heit 2012-11-03 02:02:42 +00:00
parent d0c3c924d4
commit 0f0dcc08a2
5 changed files with 13 additions and 4 deletions

View file

@ -141,6 +141,9 @@ Note: All <bool> fields default to false unless mentioned otherwise.
light = <integer>; // This side's light level. Default is 0.
lightabsolute = <bool>; // true = 'light' is an absolute value. Default is
// relative to the owning sector's light level.
lightfog = <bool>; // true = This side's relative lighting is used even in
// foggy sectors. Default is to disable relative
// lighting in foggy sectors.
nofakecontrast = <bool>; // Disables use of fake contrast on this sidedef.
smoothlighting = <bool>; // Use smooth fake contrast.
clipmidtex = <bool>; // Side's mid textures are clipped to floor and ceiling.

View file

@ -448,6 +448,7 @@ xx(scalex_bottom)
xx(scaley_bottom)
xx(light)
xx(lightabsolute)
xx(lightfog)
xx(nofakecontrast)
xx(smoothlighting)
xx(blockprojectiles)

View file

@ -996,11 +996,11 @@ int side_t::GetLightLevel (bool foggy, int baselight, bool noabsolute, int *pfak
baselight += rel;
}
}
if (!(Flags & WALLF_ABSLIGHTING))
}
if (!(Flags & WALLF_ABSLIGHTING) && (!foggy || (Flags & WALLF_LIGHT_FOG)))
{
baselight += this->Light;
}
}
return baselight;
}

View file

@ -1053,6 +1053,10 @@ public:
Flag(sd->Flags, WALLF_ABSLIGHTING, key);
continue;
case NAME_lightfog:
Flag(sd->Flags, WALLF_LIGHT_FOG, key);
continue;
case NAME_nofakecontrast:
Flag(sd->Flags, WALLF_NOFAKECONTRAST, key);
continue;

View file

@ -744,6 +744,7 @@ enum
WALLF_CLIP_MIDTEX = 16, // Like the line counterpart, but only for this side.
WALLF_WRAP_MIDTEX = 32, // Like the line counterpart, but only for this side.
WALLF_POLYOBJ = 64, // This wall belongs to a polyobject.
WALLF_LIGHT_FOG = 128, // This wall's Light is used even in fog.
};
struct side_t