Fix basecomm failing to load on games without sv_alltalk (#1212)
This commit is contained in:
parent
6465bd83a4
commit
ece447182f
@ -94,7 +94,10 @@ public void OnPluginStart()
|
|||||||
RegAdminCmd("sm_unsilence", Command_Unsilence, ADMFLAG_CHAT, "sm_unsilence <player> - Restores a player's ability to use voice and chat.");
|
RegAdminCmd("sm_unsilence", Command_Unsilence, ADMFLAG_CHAT, "sm_unsilence <player> - Restores a player's ability to use voice and chat.");
|
||||||
|
|
||||||
g_Cvar_Deadtalk.AddChangeHook(ConVarChange_Deadtalk);
|
g_Cvar_Deadtalk.AddChangeHook(ConVarChange_Deadtalk);
|
||||||
|
|
||||||
|
if (g_Cvar_Alltalk) {
|
||||||
g_Cvar_Alltalk.AddChangeHook(ConVarChange_Alltalk);
|
g_Cvar_Alltalk.AddChangeHook(ConVarChange_Alltalk);
|
||||||
|
}
|
||||||
|
|
||||||
/* Account for late loading */
|
/* Account for late loading */
|
||||||
TopMenu topmenu;
|
TopMenu topmenu;
|
||||||
@ -227,7 +230,7 @@ public void Event_PlayerDeath(Event event, const char[] name, bool dontBroadcast
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (g_Cvar_Alltalk.BoolValue)
|
if (g_Cvar_Alltalk && g_Cvar_Alltalk.BoolValue)
|
||||||
{
|
{
|
||||||
SetClientListeningFlags(client, VOICE_NORMAL);
|
SetClientListeningFlags(client, VOICE_NORMAL);
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user