Skip to content

Commit

Permalink
server: fixed env_dynlight "Start Off" spawnflag working
Browse files Browse the repository at this point in the history
  • Loading branch information
SNMetamorph committed Jan 4, 2024
1 parent 4f944e1 commit 018739c
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions server/lights.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -568,8 +568,6 @@ class CDynamicLight : public CPointEntity
void SetStyle(string_t iszPattern);
void UpdatePVSPoint(void);
void UpdateState();
void Activate();
void Deactivate();
void EXPORT CineThink(void);
void EXPORT PVSThink(void);

Expand Down Expand Up @@ -634,6 +632,7 @@ void CDynamicLight::Spawn()
if (pev->spawnflags & SF_DYNLIGHT_STARTOFF)
{
pev->effects |= EF_NODRAW;
DontThink();
}
else if (pev->sequence)
{
Expand Down Expand Up @@ -773,16 +772,6 @@ void CDynamicLight::UpdateState()
pev->skin = m_iStyle & 0x3F; // store lightstyle index in first 6 bits
}

void CDynamicLight::Activate()
{
pev->effects &= ~EF_NODRAW;
}

void CDynamicLight::Deactivate()
{
pev->effects |= EF_NODRAW;
}

void EXPORT CDynamicLight::CineThink(void)
{
UpdatePVSPoint();
Expand Down

0 comments on commit 018739c

Please sign in to comment.