1010ConVar g_hCvar_DisplayEnabled ,
1111 g_hCvar_DisplayCooldowns ,
1212 g_hCvar_Admins_See ,
13- g_hCvar_HUD_Channel ,
1413 g_hCvar_ZM_pry ,
1514 g_hCvar_MaxHudItemsCount ,
1615 g_hCvar_HudRotationDefault ;
@@ -26,11 +25,8 @@ bool g_bDispEnabled = true,
2625 g_bDispCooldowns = true ,
2726 g_bAdminsSee = true ,
2827 g_bZombieNoItemPry = false ;
29- bPluginDynamic = false ,
30- bNative_Dynamic = false ,
3128 bNative_MsgTypeProtobuf = false ;
3229
33- int g_iHUDChannel = 5 ;
3430int g_iDefaultRotationTime = 3 ;
3531int g_iMaxItemsCount = 10 ;
3632
@@ -47,15 +43,13 @@ stock void EWM_Hud_OnPluginStart()
4743 g_hCvar_DisplayEnabled = CreateConVar (" entwatch_display_enable" , " 1" , " Enable/Disable the display." , _ , true , 0.0 , true , 1.0 );
4844 g_hCvar_DisplayCooldowns = CreateConVar (" entwatch_display_cooldowns" , " 1" , " Show/Hide the cooldowns on the display." , _ , true , 0.0 , true , 1.0 );
4945 g_hCvar_Admins_See = CreateConVar (" entwatch_admins_see" , " 1" , " Enable/Disable admins see everything Items" , _ , true , 0.0 , true , 1.0 );
50- g_hCvar_HUD_Channel = CreateConVar (" entwatch_hud_channel" , " 5" , " Change HUD Channel/Group Dynamic channel." , _ , true , 0.0 , true , 5.0 );
5146 g_hCvar_ZM_pry = CreateConVar (" entwatch_zm_noitem_pry" , " 0" , " Enable/Disable zm pry human Items if zms without items" , _ , true , 0.0 , true , 1.0 );
5247 g_hCvar_MaxHudItemsCount = CreateConVar (" entwatch_hud_items_count" , " 10" , " Max/Default Items Count in hud to display." , _ , true , 1.0 , true , 10.0 );
5348 g_hCvar_HudRotationDefault = CreateConVar (" entwatch_hud_rotation_time_default" , " 3" , " Default Rotation time in seconds for hud." , _ , true , 1.0 , true , 5.0 );
5449
5550 g_bDispEnabled = GetConVarBool (g_hCvar_DisplayEnabled );
5651 g_bDispCooldowns = GetConVarBool (g_hCvar_DisplayCooldowns );
5752 g_bAdminsSee = GetConVarBool (g_hCvar_Admins_See );
58- g_iHUDChannel = GetConVarInt (g_hCvar_HUD_Channel );
5953 g_bZombieNoItemPry = GetConVarBool (g_hCvar_ZM_pry );
6054
6155 RegConsoleCmd (" sm_hud" , EWM_Hud_Command_ToggleHUD );
@@ -66,7 +60,6 @@ stock void EWM_Hud_OnPluginStart()
6660 HookConVarChange (g_hCvar_DisplayEnabled , Cvar_HUD_Changed );
6761 HookConVarChange (g_hCvar_DisplayCooldowns , Cvar_HUD_Changed );
6862 HookConVarChange (g_hCvar_Admins_See , Cvar_HUD_Changed );
69- HookConVarChange (g_hCvar_HUD_Channel , Cvar_HUD_Changed );
7063 HookConVarChange (g_hCvar_ZM_pry , Cvar_HUD_Changed );
7164 HookConVarChange (g_hCvar_MaxHudItemsCount , Cvar_HUD_Changed );
7265 HookConVarChange (g_hCvar_HudRotationDefault , Cvar_HUD_Changed );
@@ -89,8 +82,6 @@ public void Cvar_HUD_Changed(ConVar convar, const char[] oldValue, const char[]
8982 g_bDispCooldowns = GetConVarBool (convar );
9083 else if (convar == g_hCvar_Admins_See )
9184 g_bAdminsSee = GetConVarBool (convar );
92- else if (convar == g_hCvar_HUD_Channel )
93- g_iHUDChannel = GetConVarInt (convar );
9485 else if (convar == g_hCvar_ZM_pry )
9586 g_bZombieNoItemPry = GetConVarBool (convar );
9687 else if (convar == g_hCvar_MaxHudItemsCount )
@@ -113,33 +104,19 @@ public void EWM_Hud_OnAllPluginsLoaded()
113104
114105public void EWM_Hud_OnLibraryRemoved (const char [] name )
115106{
116- if (strcmp (name , " DynamicChannels" , false ) == 0 )
117- {
118- bPluginDynamic = false ;
119- VerifyNatives_DynamicChannels ();
120- }
107+ // Nothing yet
121108}
122109
123110public void EWM_Hud_OnLibraryAdded (const char [] name )
124111{
125- if (strcmp (name , " DynamicChannels" , false ) == 0 )
126- {
127- bPluginDynamic = true ;
128- VerifyNatives_DynamicChannels ();
129- }
112+ // Nothing yet
130113}
131114
132115stock VerifyNatives ()
133116{
134- VerifyNatives_DynamicChannels ();
135117 VerifyNative_MessageTypeProtobuf ();
136118}
137119
138- stock void VerifyNatives_DynamicChannels ()
139- {
140- bNative_Dynamic = bPluginDynamic && CanTestFeatures () && GetFeatureStatus (FeatureType_Native , " GetDynamicChannel" ) == FeatureStatus_Available ;
141- }
142-
143120stock void VerifyNative_MessageTypeProtobuf ()
144121{
145122 bNative_MsgTypeProtobuf = CanTestFeatures () && GetFeatureStatus (FeatureType_Native , " GetUserMessageType" ) == FeatureStatus_Available && GetUserMessageType () == UM_Protobuf ;
@@ -232,13 +209,8 @@ public void EWM_Hud_OnMapStart()
232209 }
233210}
234211
235- public void EWM_Hud_DisplayCustomHUD (int client , int iHUDChannel , const char [] sMes_Names , const char [] sMes_NoNames )
212+ public void EWM_Hud_DisplayCustomHUD (int client , const char [] sMes_Names , const char [] sMes_NoNames )
236213{
237- #if defined _DynamicChannels_included_
238- if (bNative_Dynamic )
239- iHUDChannel = GetDynamicChannel (iHUDChannel );
240- #endif
241-
242214 char msg [MAX_KeyHintText ];
243215 if (g_CSettings_Hud [client ].Name )
244216 Format (msg , sizeof (msg ), " %s " , sMes_Names );
@@ -334,13 +306,13 @@ public Action EWM_Hud_Timer_DisplayHUD(Handle timer, int client)
334306 bool bShowZombiesHUD = (iCountZMItems > 0 ) && (g_bTeamOnly && iTeam == CS_TEAM_T );
335307
336308 if (bIsAdmin )
337- EWM_Hud_DisplayCustomHUD (i , g_iHUDChannel , sMes_Admins , sMes_Admins_woname );
309+ EWM_Hud_DisplayCustomHUD (i , sMes_Admins , sMes_Admins_woname );
338310 else if (bShowHumansHUD )
339- EWM_Hud_DisplayCustomHUD (i , g_iHUDChannel , sMes_Humans , sMes_Humans_woname );
311+ EWM_Hud_DisplayCustomHUD (i , sMes_Humans , sMes_Humans_woname );
340312 else if (bShowZombiesHUD )
341- EWM_Hud_DisplayCustomHUD (i , g_iHUDChannel , sMes_Zombies , sMes_Zombies_woname );
313+ EWM_Hud_DisplayCustomHUD (i , sMes_Zombies , sMes_Zombies_woname );
342314 else
343- EWM_Hud_DisplayCustomHUD (i , g_iHUDChannel , sMes_Admins , sMes_Admins_woname );
315+ EWM_Hud_DisplayCustomHUD (i , sMes_Admins , sMes_Admins_woname );
344316 }
345317 }
346318
0 commit comments