]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
allow disabling collision checking against other panels
authorFruitieX <rasse@rasse-lappy.localdomain>
Thu, 13 May 2010 07:53:46 +0000 (10:53 +0300)
committerFruitieX <rasse@rasse-lappy.localdomain>
Thu, 13 May 2010 07:53:46 +0000 (10:53 +0300)
defaultXonotic.cfg
qcsrc/client/hud.qc

index 979df639f2a87974a763aa3085cf23026852847e..51ebd115808a001bc67097b34ebc61515f803de4 100644 (file)
@@ -1333,10 +1333,12 @@ seta hud_progressbar_alpha "0.5" "alpha of progressbars"
 seta hud_bg "border" "sets the default background for the panels, file must exist in data/gfx/hud/. 0 = disable background by default"
 seta hud_bg_color "0 0.7 0.8" "sets the default background color for the panels"
 seta hud_bg_alpha 0.8 "alpha of the background"
-seta hud_configure_bg_minalpha 0.5 "minimum panel background alpha when in hud configure mode"
 seta hud_bg_border 10 "sets the default border size for the panels"
 seta hud_fg_alpha 1 "alpha of the foreground"
 
+seta hud_configure_checkcollisions 1 "check for collisions against other panels when in hud configure mode"
+seta hud_configure_bg_minalpha 0.5 "minimum panel background alpha when in hud configure mode"
+
 seta hud_dock 0 "overlay the whole screen with this dock background, 0 = disable"
 seta hud_dock_color "0 0.7 0.8" "dock color"
 seta hud_dock_alpha 0.8 "alpha of the dock"
index 8cd8794a9672d6be23c682cde9fee8f5aee57f45..5286b2c3072121e55c6b482fb5060ccba29a52b3 100644 (file)
@@ -752,7 +752,8 @@ float HUD_Panel_SetSize(float id, vector mySize)
        myPos = HUD_Panel_GetPos(id);
 
        // check for collisions
-       mySize = HUD_Panel_CheckResize(id, HUD_Panel_GetPos(id), mySize);
+       if(cvar("hud_configure_checkcollisions"))
+               mySize = HUD_Panel_CheckResize(id, HUD_Panel_GetPos(id), mySize);
 
        mySize_x = bound(0.025 * vid_conwidth, mySize_x, vid_conwidth - myPos_x);
        mySize_y = bound(0.025 * vid_conheight, mySize_y, vid_conheight - myPos_y);
@@ -864,7 +865,8 @@ void HUD_Panel_SetPos(float id, vector pos, float didntresize)
        vector mySize;
        mySize = HUD_Panel_GetSize(id);
 
-       pos = HUD_Panel_CheckMove(id, pos, mySize);
+       if(cvar("hud_configure_checkcollisions"))
+               pos = HUD_Panel_CheckMove(id, pos, mySize);
 
        pos_x = bound(0, pos_x, vid_conwidth - mySize_x);
        pos_y = bound(0, pos_y, vid_conheight - mySize_y);