]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/client/View.qc
Merge branch 'master' into Mario/weapons_new
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / View.qc
index f68ea32e53ec7781f05ed2f5e46c8d449ef1eb3e..8a5fff1714c7f81ffd529432a6263ec288fb58ad 100644 (file)
@@ -1458,6 +1458,8 @@ void CSQC_UpdateView(float w, float h)
                                        vortex_charge = getstatf(STAT_VORTEX_CHARGE);
                                        vortex_chargepool = getstatf(STAT_VORTEX_CHARGEPOOL);
 
+                                       float arc_heat = getstatf(STAT_ARC_HEAT);
+
                                        if(vortex_charge_movingavg == 0) // this should only happen if we have just loaded up the game
                                                vortex_charge_movingavg = vortex_charge;
 
@@ -1512,6 +1514,14 @@ void CSQC_UpdateView(float w, float h)
                                                else
                                                        ring_image = "gfx/crosshair_ring.tga";
                                        }
+                                       else if ( autocvar_crosshair_ring && autocvar_crosshair_ring_arc && arc_heat && activeweapon == WEP_ARC )
+                                       {
+                                               ring_value = arc_heat;
+                                               ring_alpha = (1-arc_heat)*autocvar_crosshair_ring_arc_cold_alpha +
+                                                       arc_heat*autocvar_crosshair_ring_arc_hot_alpha;
+                                               ring_rgb = (1-arc_heat)*wcross_color + arc_heat*autocvar_crosshair_ring_arc_hot_color;
+                                               ring_image = "gfx/crosshair_ring.tga";
+                                       }
 
                                        // if in weapon switch animation, fade ring out/in
                                        if(autocvar_crosshair_effect_time > 0)