Skip to content

Commit

Permalink
Fix alien slave beams staying forever if they exist during a level ch…
Browse files Browse the repository at this point in the history
  • Loading branch information
SamVanheer committed Apr 2, 2023
1 parent 4fe7e6e commit ac808a8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Expand Up @@ -14,6 +14,7 @@
* Fixed pistol not playing empty sound when using secondary attack
* Fixed user interface coordinates and sizes being incorrectly adjusted for resolution (halflife issue [#3344](https://github.com/ValveSoftware/halflife/issues/3344))
* Fixed player weapons still receiving input when starting to use a func_tank (halflife issue [#3345](https://github.com/ValveSoftware/halflife/issues/3345)) (Thanks Oxofemple.)
* Fixed alien slave beams staying forever if they exist during a level change (halflife issue [#3104](https://github.com/ValveSoftware/halflife/issues/3104))

## Changes in V1.0.0 Beta 014

Expand Down
3 changes: 3 additions & 0 deletions dlls/islave.cpp
Expand Up @@ -744,6 +744,7 @@ void CISlave::ArmBeam(int side)
m_pBeam[m_iBeams]->SetColor(96, 128, 16);
m_pBeam[m_iBeams]->SetBrightness(64);
m_pBeam[m_iBeams]->SetNoise(80);
m_pBeam[m_iBeams]->pev->spawnflags |= SF_BEAM_TEMPORARY; // Flag these to be destroyed on save/restore or level transition
m_iBeams++;
}

Expand Down Expand Up @@ -790,6 +791,7 @@ void CISlave::WackBeam(int side, CBaseEntity* pEntity)
m_pBeam[m_iBeams]->SetColor(180, 255, 96);
m_pBeam[m_iBeams]->SetBrightness(255);
m_pBeam[m_iBeams]->SetNoise(80);
m_pBeam[m_iBeams]->pev->spawnflags |= SF_BEAM_TEMPORARY; // Flag these to be destroyed on save/restore or level transition
m_iBeams++;
}

Expand Down Expand Up @@ -820,6 +822,7 @@ void CISlave::ZapBeam(int side)
m_pBeam[m_iBeams]->SetColor(180, 255, 96);
m_pBeam[m_iBeams]->SetBrightness(255);
m_pBeam[m_iBeams]->SetNoise(20);
m_pBeam[m_iBeams]->pev->spawnflags |= SF_BEAM_TEMPORARY; // Flag these to be destroyed on save/restore or level transition
m_iBeams++;

pEntity = CBaseEntity::Instance(tr.pHit);
Expand Down

0 comments on commit ac808a8

Please sign in to comment.