]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/client/view.qc
Add a help for quickmenu command
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / view.qc
index e846a662b17996bd89b92854f6867aa22b22f240..5a6b2fe15fb0f9081cb612478d4823bfce8c1880 100644 (file)
@@ -5,10 +5,8 @@
 #include "hud.qh"
 #include "hud_config.qh"
 #include "mapvoting.qh"
-#include "noise.qh"
 #include "scoreboard.qh"
 #include "shownames.qh"
-#include "waypointsprites.qh"
 
 #include "mutators/events.qh"
 
@@ -26,7 +24,6 @@
 
 #include "../warpzonelib/client.qh"
 #include "../warpzonelib/common.qh"
-#include "../warpzonelib/mathlib.qh"
 
 entity porto;
 vector polyline[16];
@@ -562,7 +559,9 @@ void UpdateCrosshair()
                        CSQC_common_hud();
 
        // crosshair goes VERY LAST
-       if(!scoreboard_active && !camera_active && intermission != 2 && spectatee_status != -1 && hud == HUD_NORMAL && !csqcplayer.viewloc)
+       if(!scoreboard_active && !camera_active && intermission != 2 && 
+               spectatee_status != -1 && hud == HUD_NORMAL && !csqcplayer.viewloc &&
+               !HUD_MinigameMenu_IsOpened() )
        {
                if (!autocvar_crosshair_enabled) // main toggle for crosshair rendering
                        return;
@@ -1012,6 +1011,7 @@ float cl_notice_run();
 float prev_myteam;
 int lasthud;
 float vh_notice_time;
+void WaypointSprite_Load();
 void CSQC_UpdateView(float w, float h)
 {
        entity e;
@@ -1199,7 +1199,7 @@ void CSQC_UpdateView(float w, float h)
        }
 
        // do lockview after event chase camera so that it still applies whenever necessary.
-       if(autocvar_cl_lockview || (!autocvar_hud_cursormode && (autocvar__hud_configure && spectatee_status <= 0 || intermission > 1)))
+       if(autocvar_cl_lockview || (!autocvar_hud_cursormode && (autocvar__hud_configure && spectatee_status <= 0 || intermission > 1 || QuickMenu_IsOpened())))
        {
                setproperty(VF_ORIGIN, freeze_org);
                setproperty(VF_ANGLES, freeze_ang);
@@ -1835,6 +1835,10 @@ void CSQC_UpdateView(float w, float h)
 
        if(autocvar__hud_configure)
                HUD_Panel_Mouse();
+       else if ( HUD_MinigameMenu_IsOpened() || minigame_isactive() )
+               HUD_Minigame_Mouse();
+       else if(QuickMenu_IsOpened())
+               QuickMenu_Mouse();
        else
                HUD_Radar_Mouse();