]> git.rm.cloudns.org Git - voretournament/voretournament.git/commitdiff
Invert minus and plus for Y axis to represent correct direction
authorMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Wed, 16 May 2012 20:23:39 +0000 (23:23 +0300)
committerMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Wed, 16 May 2012 20:23:39 +0000 (23:23 +0300)
data/qcsrc/client/hud.qc

index 3b2e0b9972da5c30be290f4708e0060c95f098e9..ab126e5a09b7d06b68d627c564b32c8c3e03fb6e 100644 (file)
@@ -79,7 +79,7 @@ void Sbar_DrawPic(string pic, vector position, vector dimensions, float backgrou
        sz_y = vid_conheight * dimensions_y;\r
        pos_x = (vid_conwidth / 2) * bound(0, 1 + position_x, 2);\r
        pos_x -= sz_x / 2;\r
-       pos_y = (vid_conheight / 2) * bound(0, 1 + position_y, 2);\r
+       pos_y = (vid_conheight / 2) * bound(0, 1 - position_y, 2);\r
        pos_y -= sz_y / 2;\r
 \r
        if(background)\r
@@ -99,7 +99,7 @@ void Sbar_DrawString(string text, vector position, float lettersize)
        sz_x = sz_y = lettersize;\r
        pos_x = (vid_conwidth / 2) * bound(0, 1 + position_x, 2);\r
        pos_x -= stringwidth(text, FALSE, sz) * 0.5;\r
-       pos_y = (vid_conheight / 2) * bound(0, 1 + position_y, 2);\r
+       pos_y = (vid_conheight / 2) * bound(0, 1 - position_y, 2);\r
        pos_y -= sz_y / 2;\r
 \r
        drawstring(pos, text, sz, '1 1 1', sbar_alpha_fg, DRAWFLAG_NORMAL);\r
@@ -155,7 +155,7 @@ void Sbar_DrawXNum (vector position, float num, float digits, float showminusplu
        sz_x = sz_y = lettersize;\r
        pos_x = (vid_conwidth / 2) * bound(0, 1 + position_x, 2);\r
        pos_x -= stringwidth(final_num, FALSE, sz) * 0.5;\r
-       pos_y = (vid_conheight / 2) * bound(0, 1 + position_y, 2);\r
+       pos_y = (vid_conheight / 2) * bound(0, 1 - position_y, 2);\r
        pos_y -= sz_y / 2;\r
 \r
        drawstring(pos, final_num, sz, rgb, alpha, dflags);\r