]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
yikes, ugly electro lg effects, also fail through warpzones :p
authorFruitieX <rasse@rasse-lappy.localdomain>
Sun, 20 Jun 2010 14:17:28 +0000 (17:17 +0300)
committerFruitieX <rasse@rasse-lappy.localdomain>
Sun, 20 Jun 2010 14:17:28 +0000 (17:17 +0300)
balanceFruit.cfg
effectinfo.txt
qcsrc/server/w_electro.qc

index e19a65a441e7b33597af65e85779a51c134a1ce2..9e0a86f0eade8a0e73e0d9f9293acb39c86055be 100644 (file)
@@ -302,18 +302,18 @@ set g_balance_grenadelauncher_secondary_bouncefactor 0.5
 set g_balance_grenadelauncher_secondary_bouncestop 0.075
 // }}}
 // {{{ electro // TODO
-set g_balance_electro_lightning 0
-set g_balance_electro_primary_damage 65
+set g_balance_electro_lightning 1
+set g_balance_electro_primary_damage 5
 set g_balance_electro_primary_edgedamage 0
-set g_balance_electro_primary_force 200
-set g_balance_electro_primary_radius 150
+set g_balance_electro_primary_force 60 // todo: probaby needs movement nerfing code when hit?
+set g_balance_electro_primary_radius 850
 set g_balance_electro_primary_comboradius 0
-set g_balance_electro_primary_speed 2000
+set g_balance_electro_primary_speed 0
 set g_balance_electro_primary_spread 0
-set g_balance_electro_primary_lifetime 30
-set g_balance_electro_primary_refire 0.6
-set g_balance_electro_primary_animtime 0.3
-set g_balance_electro_primary_ammo 2
+set g_balance_electro_primary_lifetime 0
+set g_balance_electro_primary_refire 0.066
+set g_balance_electro_primary_animtime 0.066
+set g_balance_electro_primary_ammo 0.66
 set g_balance_electro_secondary_damage 50
 set g_balance_electro_secondary_spread 0.05
 set g_balance_electro_secondary_edgedamage 0
index 1d9cd3a0581e54f28fd2a22579ed943b84356c57..9f98d6af50f9585ea538cbafaac59c6db2dc53f8 100644 (file)
@@ -4970,3 +4970,46 @@ bounce 1.5
 airfriction 5
 liquidfriction 10
 velocityjitter 156 156 156
+
+
+
+// used in qcsrc/server/w_electro.qc:  pointparticles(particleeffectnum("electro_muzzleflash"), w_shotorg, w_shotdir * 1000, 1)
+// used in qcsrc/server/w_electro.qc:  pointparticles(particleeffectnum("electro_muzzleflash"), w_shotorg, w_shotdir * 1000, 1)
+effect electro_lightning
+countabsolute 1
+type smoke
+color 0x283880 0x283880 // 0x202020 0x404040
+tex 65 65
+size 10 10
+alpha 256 256 1500
+originjitter 1.5 1.5 1.5
+velocityjitter 6 6 6
+sizeincrease -20
+velocitymultiplier 0.01
+
+effect electro_lightning
+count 3
+type spark
+tex 8 15
+color 0xD9FDFF 0xD9FDFF
+size 3 7
+alpha 110 228 2024
+originjitter 1 1 1
+velocityjitter 150 150 150
+velocitymultiplier 0.5
+airfriction 2
+stretchfactor 1.5
+
+effect electro_lightning
+count 5
+type spark
+tex 41 41
+color 0xD9FDFF 0xD9FDFF
+size 3 4
+alpha 110 228 1500
+originjitter 1 1 1
+velocityjitter 350 350 350
+velocitymultiplier 2.5
+airfriction 8
+gravity 1.3
+stretchfactor 0.1
index 0b35eae662de8cc2848cb04ebe8d9e52a88f428a..e7780624ff14e2220e9cb838d6459ac37d5f9d13 100644 (file)
@@ -187,16 +187,20 @@ void W_Electro_Attack2()
 // experimental lightning gun
 void W_Electro_Attack3 (void)
 {
-       if not(self.items & IT_UNLIMITED_WEAPON_AMMO)
-               self.ammo_cells = self.ammo_cells - cvar("g_balance_electro_primary_ammo");
-       W_SetupShot (self, TRUE, 0, "weapons/crylink_fire2.wav", cvar("g_balance_electro_primary_damage"));
+       if not(self.items & IT_UNLIMITED_WEAPON_AMMO)
+               self.ammo_cells = self.ammo_cells - cvar("g_balance_electro_primary_ammo");
+       W_SetupShot (self, TRUE, 0, "weapons/crylink_fire2.wav", cvar("g_balance_electro_primary_damage"));
 
-       traceline_antilag(self, w_shotorg, w_shotorg + w_shotdir * cvar("g_balance_electro_primary_radius"), FALSE, self, ANTILAG_LATENCY(self));
+       WarpZone_traceline_antilag(self, w_shotorg, w_shotorg + w_shotdir * cvar("g_balance_electro_primary_radius"), FALSE, self, ANTILAG_LATENCY(self));
 
-       te_lightning1(self, w_shotorg, trace_endpos);
+       float i;
+       for (i = 0; i < vlen(trace_endpos - w_shotorg)/25; ++i)
+       {
+               pointparticles(particleeffectnum("electro_lightning"), w_shotorg + (i / floor(vlen(w_shotorg - trace_endpos)/25)) * (trace_endpos - w_shotorg), w_shotdir * 1000, 1);
+       }
 
-       if (trace_fraction < 1)
-               Damage(trace_ent, self, self, cvar("g_balance_electro_primary_damage"), WEP_ELECTRO | HITTYPE_SECONDARY, trace_endpos, cvar("g_balance_electro_primary_force") * w_shotdir);
+       if (trace_fraction < 1)
+               Damage(trace_ent, self, self, cvar("g_balance_electro_primary_damage"), WEP_ELECTRO | HITTYPE_SECONDARY, trace_endpos, cvar("g_balance_electro_primary_force") * w_shotdir);
 }
 
 void spawnfunc_weapon_electro (void)
@@ -256,7 +260,7 @@ float w_electro(float req)
                                W_Electro_Attack();
                        weapon_thinkf(WFRAME_FIRE1, cvar("g_balance_electro_primary_animtime"), w_ready);
                }
-               if (self.BUTTON_ATCK2 && !cvar("g_balance_electro_lightning"))
+               if (self.BUTTON_ATCK2)
                if (time >= self.electro_secondarytime)
                if (weapon_prepareattack(1, cvar("g_balance_electro_secondary_refire")))
                {