]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Give the electro orb some transparency to be less obstrusive
authorMario <mario.mario@y7mail.com>
Sat, 2 Nov 2024 22:41:29 +0000 (08:41 +1000)
committerMario <mario.mario@y7mail.com>
Sat, 2 Nov 2024 22:41:29 +0000 (08:41 +1000)
qcsrc/common/weapons/weapon/electro.qc

index a77f2a1597a899afe463183a6378fd9df1e4d37c..cf67708f4bdf971eb43fc73023fc8e7f92f64b43 100644 (file)
@@ -12,8 +12,8 @@ void electro_orb_draw(entity this)
        if(dt <= 0)
                return;
 
-       this.alpha = bound(0, (this.ltime - time) * 4, 1);
-       this.scale = (WEP_CVAR(WEP_ELECTRO, combo_radius) * 0.05) * this.alpha;
+       float myscale = bound(0, (this.ltime - time) * 4, 1);
+       this.scale = (WEP_CVAR(WEP_ELECTRO, combo_radius) * 0.05) * myscale;
        this.angles = this.angles + dt * this.avelocity;
 }
 
@@ -31,6 +31,7 @@ void electro_orb_setup(entity e)
        e.solid = SOLID_NOT;
        e.avelocity = '7 0 11';
        e.drawmask = MASK_NORMAL;
+       e.alpha = 0.7;
 }
 #endif