diff --git a/PlayerRankings/scripting/PlayerRankings.sp b/PlayerRankings/scripting/PlayerRankings.sp index 992ed0b6..743458bf 100644 --- a/PlayerRankings/scripting/PlayerRankings.sp +++ b/PlayerRankings/scripting/PlayerRankings.sp @@ -26,6 +26,7 @@ ConVar g_hCVar_Protection; ConVar g_hCVar_ProtectionMinimal1; ConVar g_hCVar_ProtectionMinimal2; ConVar g_hCVar_ProtectionMinimal3; +ConVar g_hCVar_Grenade; /* INTERGERS */ int g_iDialogLevel = 100000; @@ -44,7 +45,7 @@ public Plugin myinfo = name = "Player Rankings", author = "Neon & zaCade", description = "Show Top Defenders & Infections after each round", - version = "1.1.1" + version = "1.1.2" }; //---------------------------------------------------------------------------------------------------- @@ -71,6 +72,8 @@ public void OnPluginStart() g_hCVar_ProtectionMinimal1 = CreateConVar("sm_topdefenders_minimal_1", "15", "", FCVAR_NONE, true, 1.0, true, 64.0); g_hCVar_ProtectionMinimal2 = CreateConVar("sm_topdefenders_minimal_2", "30", "", FCVAR_NONE, true, 1.0, true, 64.0); g_hCVar_ProtectionMinimal3 = CreateConVar("sm_topdefenders_minimal_3", "45", "", FCVAR_NONE, true, 1.0, true, 64.0); + g_hCVar_Grenade = CreateConVar("sm_topdefenders_grenade", "1", "", FCVAR_NONE, true, 0.0, true, 1.0); + AutoExecConfig(true); g_hCookie_HideCrown = RegClientCookie("topdefenders_hidecrown", "", CookieAccess_Private); g_hCookie_HideDialog = RegClientCookie("topdefenders_hidedialog", "", CookieAccess_Private); @@ -596,6 +599,9 @@ public void OnClientSpawn(Event hEvent, const char[] sEvent, bool bDontBroadcast CreateTimer(7.0, OnClientSpawnPostSkull, GetClientSerial(client), TIMER_FLAG_NO_MAPCHANGE); } + if(!g_hCVar_Grenade.BoolValue) + return; + for (int i = 0; i < sizeof(g_iPlayerWinner); i++) { if (g_iPlayerWinner[i] == steamAccountID)