From 13086d3b5d7ab24b246160237ebc03bcc3ad0669 Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Thu, 17 Oct 2024 20:08:11 +0300 Subject: [PATCH] server: fix infinite loop while trying to look for spawn spot for deathmatch Fixes: 253a3cb8d487 ("Better spawn spot randomization from HL25 update.") --- dlls/player.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/player.cpp b/dlls/player.cpp index fe348abf..f2714d08 100644 --- a/dlls/player.cpp +++ b/dlls/player.cpp @@ -2815,7 +2815,7 @@ edict_t *EntSelectSpawnPoint( CBaseEntity *pPlayer ) nNumRandomSpawnsToTry = 0; CBaseEntity* pEnt = 0; - while( ( pEnt = UTIL_FindEntityByClassname( 0, "info_player_deathmatch" ))) + while( ( pEnt = UTIL_FindEntityByClassname( pEnt, "info_player_deathmatch" ))) nNumRandomSpawnsToTry++; }