]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/client/View.qc
Make the reticle fade in based on zoom speed. Fix some silly typos as well. Imo this...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / View.qc
index 0557db1160be5c4a8d0e7d4ae9339e9b72837aae..86e96d2f54807480563d0ddda5f17c19504dd128 100644 (file)
@@ -356,6 +356,8 @@ void CSQC_UpdateView(float w, float h)
        float f, i, j;
        vector v, vo;
 
+       vector reticle_pos, reticle_size;
+
        WaypointSprite_Load();
 
        if(spectatee_status)
@@ -577,6 +579,16 @@ void CSQC_UpdateView(float w, float h)
                        self.draw2d();
        self = e;
 
+       // draw the aiming reticle for weapons that use it (eg. Nex)
+       reticle_pos_x = 0;
+       reticle_pos_y = 0;
+       reticle_size_x = vid_conwidth;
+       reticle_size_y = vid_conheight;
+
+       if(cvar("cl_reticle_nex"))
+       if(button_attack2 && activeweapon == WEP_NEX)
+               drawpic(reticle_pos, "textures/reticle_nex", reticle_size, '1 1 1', current_zoomfraction * cvar("cl_reticle_nex"), DRAWFLAG_NORMAL);
+
        // draw radar
        if(
                        ons_showmap