From 71c4e21385aebba3b7ede33e8540f44923aa11ca Mon Sep 17 00:00:00 2001 From: s1lentq Date: Fri, 29 Sep 2023 01:19:31 +0700 Subject: [PATCH] Fixed a crash when killer is worldspawn --- regamedll/dlls/multiplay_gamerules.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/regamedll/dlls/multiplay_gamerules.cpp b/regamedll/dlls/multiplay_gamerules.cpp index fb78706fa..3b920abee 100644 --- a/regamedll/dlls/multiplay_gamerules.cpp +++ b/regamedll/dlls/multiplay_gamerules.cpp @@ -5355,7 +5355,7 @@ void EXT_FUNC CHalfLifeMultiplay::__API_HOOK(SendDeathMessage)(CBaseEntity *pKil } // An recipient a client is a victim that involved in this kill - if (pPlayer == pVictim && pVictim != pKillerPlayer) + if (pKillerPlayer && pPlayer == pVictim && pVictim != pKillerPlayer) { // Sets a domination kill for recipient of the victim once until revenge int iKillsUnanswered = pVictim->CSPlayer()->m_iNumKilledByUnanswered[pKillerPlayer->entindex() - 1];