Skip to content

Commit

Permalink
Fix #216
Browse files Browse the repository at this point in the history
  • Loading branch information
Alienmario committed Jan 15, 2025
1 parent 87abc7c commit aa69ae0
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions scripting/include/srccoop/playerpatch.inc
Original file line number Diff line number Diff line change
Expand Up @@ -1096,6 +1096,14 @@ static void ClearNpcMemoryForPlayer(const CBasePlayer pPlayer)
CBaseEntity pEntity = CBaseEntity(iEntIndex);
if (pEntity.IsNPC())
{
#if defined SRCCOOP_BLACKMESA
if (pEntity.IsClassname("npc_abrams"))
{
// causes a crash in CNPC_Abrams::AimMiniTurret2
continue;
}
#endif

CAI_BaseNPC pNPC = view_as<CAI_BaseNPC>(pEntity);
pNPC.ForgetEntity(pPlayer);
}
Expand Down

0 comments on commit aa69ae0

Please sign in to comment.