From: FruitieX Date: Sun, 20 Jun 2010 14:17:28 +0000 (+0300) Subject: yikes, ugly electro lg effects, also fail through warpzones :p X-Git-Tag: xonotic-v0.1.0preview~423^2~80 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=2b3c7b7313e089bb55895c94cd4029ce517592d8;p=xonotic%2Fxonotic-data.pk3dir.git yikes, ugly electro lg effects, also fail through warpzones :p --- diff --git a/balanceFruit.cfg b/balanceFruit.cfg index e19a65a44..9e0a86f0e 100644 --- a/balanceFruit.cfg +++ b/balanceFruit.cfg @@ -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 diff --git a/effectinfo.txt b/effectinfo.txt index 1d9cd3a05..9f98d6af5 100644 --- a/effectinfo.txt +++ b/effectinfo.txt @@ -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 diff --git a/qcsrc/server/w_electro.qc b/qcsrc/server/w_electro.qc index 0b35eae66..e7780624f 100644 --- a/qcsrc/server/w_electro.qc +++ b/qcsrc/server/w_electro.qc @@ -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"))) {