]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/client/miscfunctions.qc
Merge branch 'master' into Mario/wepent_experimental
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / miscfunctions.qc
index 9b9833286cedf7dee5e001430804c5a61f2472cc..0e88cd5a51043107b2d2246e79351151dccc538e 100644 (file)
@@ -1,8 +1,8 @@
 #include "miscfunctions.qh"
 
-#include "hud/_all.qh"
+#include "hud/_mod.qh"
 
-#include <common/command/_all.qh>
+#include <common/command/_mod.qh>
 
 #include <common/teams.qh>
 
@@ -350,6 +350,13 @@ void drawcolorcodedstring_aspect_expanding(vector pos, string text, vector sz, f
        drawcolorcodedstring_expanding(pos, text, '1 1 0' * sz.y, theAlpha, drawflag, fadelerp);
 }
 
+void update_mousepos()
+{
+       mousepos += getmousepos() * autocvar_menu_mouse_speed;
+       mousepos.x = bound(0, mousepos.x, vid_conwidth);
+       mousepos.y = bound(0, mousepos.y, vid_conheight);
+}
+
 // this draws the triangles of a model DIRECTLY. Don't expect high performance, really...
 float PolyDrawModelSurface(entity e, float i_s)
 {