#define _REGISTER_HUD_PANEL(id, draw_func, export_func, configflags, showflags) \
void draw_func(); \
- void export_func(entity panel, int fh); \
+ void export_func(int fh); \
REGISTER(hud_panels, HUD_PANEL, id, m_id, new_pure(hud_panel)) { \
this.panel_id = this.m_id; \
this.panel_draw = draw_func; \
string panel_bg_padding_str;
classfield(HUDPanel) .void() panel_draw;
-classfield(HUDPanel) .void(entity panel, int fh) panel_export;
+classfield(HUDPanel) .void(int fh) panel_export;
// chat panel can be reduced / moved while the mapvote is active
// let know the mapvote panel about chat pos and size
HUD_Write_PanelCvar("_bg_alpha");
HUD_Write_PanelCvar("_bg_border");
HUD_Write_PanelCvar("_bg_padding");
- panel.panel_export(panel, fh);
+ panel.panel_export(fh);
HUD_Write("\n");
}
- MUTATOR_CALLHOOK(HUD_WriteCvars, fh);
HUD_Write("menu_sync\n"); // force the menu to reread the cvars, so that the dialogs are updated
// Ammo (#1)
-void HUD_Ammo_Export(entity panel, int fh)
+void HUD_Ammo_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_ammo_onlycurrent");
// CenterPrint (#16)
-void HUD_CenterPrint_Export(entity panel, int fh)
+void HUD_CenterPrint_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_centerprint_align");
// Chat (#12)
-void HUD_Chat_Export(entity panel, int fh)
+void HUD_Chat_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
}
// Engine info (#13)
-void HUD_EngineInfo_Export(entity panel, int fh)
+void HUD_EngineInfo_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_engineinfo_framecounter_time");
// Health/armor (#3)
-void HUD_HealthArmor_Export(entity panel, int fh)
+void HUD_HealthArmor_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_healtharmor_combined");
// Info messages (#14)
-void HUD_InfoMessages_Export(entity panel, int fh)
+void HUD_InfoMessages_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_infomessages_flip");
// Mod icons (#10)
-void HUD_ModIcons_Export(entity panel, int fh)
+void HUD_ModIcons_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_modicons_ca_layout");
// Notifications (#4)
-void HUD_Notify_Export(entity panel, int fh)
+void HUD_Notify_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_notify_flip");
// Physics (#15)
-void HUD_Physics_Export(entity panel, int fh)
+void HUD_Physics_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_physics_speed_unit_show");
// Powerups (#2)
-void HUD_Powerups_Export(entity panel, int fh)
+void HUD_Powerups_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_powerups_iconalign");
// Pressed keys (#11)
-void HUD_PressedKeys_Export(entity panel, int fh)
+void HUD_PressedKeys_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_pressedkeys_aspect");
// QuickMenu (#23)
-void HUD_QuickMenu_Export(entity panel, int fh)
+void HUD_QuickMenu_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_quickmenu_align");
// Race timer (#8)
-void HUD_RaceTimer_Export(entity panel, int fh)
+void HUD_RaceTimer_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
}
// Radar (#6)
-void HUD_Radar_Export(entity panel, int fh)
+void HUD_Radar_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_radar_foreground_alpha");
// Score (#7)
-void HUD_Score_Export(entity panel, int fh)
+void HUD_Score_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_score_rankings");
// Scoreboard (#24)
-void Scoreboard_Draw_Export(entity panel, int fh)
+void Scoreboard_Draw_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_scoreboard_fadeinspeed");
// Timer (#5)
-void HUD_Timer_Export(entity panel, int fh)
+void HUD_Timer_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
}
// Vote (#9)
-void HUD_Vote_Export(entity panel, int fh)
+void HUD_Vote_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_vote_alreadyvoted_alpha");
// Weapons (#0)
-void HUD_Weapons_Export(entity panel, int fh)
+void HUD_Weapons_Export(int fh)
{
HUD_Write_Cvar("hud_panel_weapons_accuracy");
HUD_Write_Cvar("hud_panel_weapons_label");
// MapVote (#21)
-void MapVote_Draw_Export(entity panel, int fh)
+void MapVote_Draw_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_mapvote_highlight_border");
/**/
MUTATOR_HOOKABLE(DrawInfoMessages, EV_DrawInfoMessages);
-/** Called when drawing info messages, allows adding new info messages */
-#define EV_HUD_WriteCvars(i, o) \
- /** file */ i(float, MUTATOR_ARGV_0_float) \
- /**/
-MUTATOR_HOOKABLE(HUD_WriteCvars, EV_HUD_WriteCvars);
-
/** Called when the view model is being animated (setorigin is called after the hook, so you only need to modify origin here if desired) */
#define EV_DrawViewModel(i, o) \
/** entity id */ i(entity, MUTATOR_ARGV_0_entity) \
#include <client/hud/hud_config.qh>
#include <client/mapvoting.qh>
-void HUD_MinigameBoard_Export(entity panel, int fh)
+void HUD_MinigameBoard_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
}
-void HUD_MinigameStatus_Export(entity panel, int fh)
+void HUD_MinigameStatus_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
}
-void HUD_MinigameHelp_Export(entity panel, int fh)
+void HUD_MinigameHelp_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
}
-void HUD_MinigameMenu_Export(entity panel, int fh)
+void HUD_MinigameMenu_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
}
// ItemsTime (#22)
-void HUD_ItemsTime_Export(entity panel, int fh)
+void HUD_ItemsTime_Export(int fh)
{
// allow saving cvars that aesthetically change the panel into hud skin files
HUD_Write_Cvar("hud_panel_itemstime_iconalign");