diff --git a/src/cs2_sdk/entity/ccsplayercontroller.h b/src/cs2_sdk/entity/ccsplayercontroller.h index bf5ce27f..914bba5b 100644 --- a/src/cs2_sdk/entity/ccsplayercontroller.h +++ b/src/cs2_sdk/entity/ccsplayercontroller.h @@ -29,6 +29,7 @@ class CCSPlayerController : public CBasePlayerController SCHEMA_FIELD(CCSPlayerController_InGameMoneyServices*, m_pInGameMoneyServices) SCHEMA_FIELD(CCSPlayerController_ActionTrackingServices*, m_pActionTrackingServices) + SCHEMA_FIELD(bool, m_bPawnIsAlive); static CCSPlayerController* FromPawn(CCSPlayerPawn* pawn) { return (CCSPlayerController*)pawn->m_hController().Get(); } }; \ No newline at end of file diff --git a/src/events.cpp b/src/events.cpp index 0801ae4b..6a74fe1c 100644 --- a/src/events.cpp +++ b/src/events.cpp @@ -175,7 +175,7 @@ GAME_EVENT_F(round_end) if(!pController) continue; - if (pController->m_iTeamNum == CS_TEAM_CT) + if (pController->m_iTeamNum == CS_TEAM_CT && pController->m_bPawnIsAlive) sortedPlayers.AddToTail(pPlayer); }