set g_balance_electro_combo_comboradius 0
set g_balance_electro_combo_speed 2000
// }}}
+// {{{ lightning
+set g_balance_lightning_primary_ammo 5
+set g_balance_lightning_primary_animtime 0.2
+set g_balance_lightning_primary_damage 100
+set g_balance_lightning_primary_edgedamage 0
+set g_balance_lightning_primary_falloff_mindist 0
+set g_balance_lightning_primary_falloff_maxdist 0
+set g_balance_lightning_primary_falloff_halflifedist 0
+set g_balance_lightning_primary_force 425
+set g_balance_lightning_primary_lifetime 0
+set g_balance_lightning_primary_radius 850
+set g_balance_lightning_primary_range 800
+set g_balance_lightning_primary_refire 0.4
+set g_balance_lightning_primary_speed 0
+set g_balance_lightning_primary_spread 0
+set g_balance_lightning_secondary_ammo 5
+set g_balance_lightning_secondary_animtime 0.5
+set g_balance_lightning_secondary_damage 100
+set g_balance_lightning_secondary_damageforcescale 4
+set g_balance_lightning_secondary_edgedamage 80
+set g_balance_lightning_secondary_flyingdamage 1
+set g_balance_lightning_secondary_flyingforce -80
+set g_balance_lightning_secondary_flyingradius 200
+set g_balance_lightning_secondary_force -200
+set g_balance_lightning_secondary_health 1
+set g_balance_lightning_secondary_lifetime 30
+set g_balance_lightning_secondary_radius 300
+set g_balance_lightning_secondary_refire 5
+set g_balance_lightning_secondary_speed 600
+// }}}
// {{{ crylink
set g_balance_crylink_primary_damage 18
set g_balance_crylink_primary_edgedamage 0
set g_balance_electro_combo_comboradius 70
set g_balance_electro_combo_speed 400
// }}}
+// {{{ lightning
+set g_balance_lightning_primary_ammo 5
+set g_balance_lightning_primary_animtime 0.2
+set g_balance_lightning_primary_damage 100
+set g_balance_lightning_primary_edgedamage 0
+set g_balance_lightning_primary_falloff_mindist 0
+set g_balance_lightning_primary_falloff_maxdist 0
+set g_balance_lightning_primary_falloff_halflifedist 0
+set g_balance_lightning_primary_force 425
+set g_balance_lightning_primary_lifetime 0
+set g_balance_lightning_primary_radius 850
+set g_balance_lightning_primary_range 800
+set g_balance_lightning_primary_refire 0.4
+set g_balance_lightning_primary_speed 0
+set g_balance_lightning_primary_spread 0
+set g_balance_lightning_secondary_ammo 5
+set g_balance_lightning_secondary_animtime 0.5
+set g_balance_lightning_secondary_damage 100
+set g_balance_lightning_secondary_damageforcescale 4
+set g_balance_lightning_secondary_edgedamage 80
+set g_balance_lightning_secondary_flyingdamage 1
+set g_balance_lightning_secondary_flyingforce -80
+set g_balance_lightning_secondary_flyingradius 200
+set g_balance_lightning_secondary_force -200
+set g_balance_lightning_secondary_health 1
+set g_balance_lightning_secondary_lifetime 30
+set g_balance_lightning_secondary_radius 300
+set g_balance_lightning_secondary_refire 5
+set g_balance_lightning_secondary_speed 600
+// }}}
// {{{ crylink
set g_balance_crylink_primary_damage 23
set g_balance_crylink_primary_edgedamage 0
set g_balance_electro_combo_comboradius 0
set g_balance_electro_combo_speed 2000
// }}}
+// {{{ lightning
+set g_balance_lightning_primary_ammo 5
+set g_balance_lightning_primary_animtime 0.2
+set g_balance_lightning_primary_damage 100
+set g_balance_lightning_primary_edgedamage 0
+set g_balance_lightning_primary_falloff_mindist 0
+set g_balance_lightning_primary_falloff_maxdist 0
+set g_balance_lightning_primary_falloff_halflifedist 0
+set g_balance_lightning_primary_force 425
+set g_balance_lightning_primary_lifetime 0
+set g_balance_lightning_primary_radius 850
+set g_balance_lightning_primary_range 800
+set g_balance_lightning_primary_refire 0.4
+set g_balance_lightning_primary_speed 0
+set g_balance_lightning_primary_spread 0
+set g_balance_lightning_secondary_ammo 5
+set g_balance_lightning_secondary_animtime 0.5
+set g_balance_lightning_secondary_damage 100
+set g_balance_lightning_secondary_damageforcescale 4
+set g_balance_lightning_secondary_edgedamage 80
+set g_balance_lightning_secondary_flyingdamage 1
+set g_balance_lightning_secondary_flyingforce -80
+set g_balance_lightning_secondary_flyingradius 200
+set g_balance_lightning_secondary_force -200
+set g_balance_lightning_secondary_health 1
+set g_balance_lightning_secondary_lifetime 30
+set g_balance_lightning_secondary_radius 300
+set g_balance_lightning_secondary_refire 5
+set g_balance_lightning_secondary_speed 600
+// }}}
// {{{ crylink
set g_balance_crylink_primary_damage 10
set g_balance_crylink_primary_edgedamage 5
set g_balance_electro_combo_comboradius 0
set g_balance_electro_combo_speed 400
// }}}
+// {{{ lightning
+set g_balance_lightning_primary_ammo 5
+set g_balance_lightning_primary_animtime 0.2
+set g_balance_lightning_primary_damage 100
+set g_balance_lightning_primary_edgedamage 0
+set g_balance_lightning_primary_falloff_mindist 0
+set g_balance_lightning_primary_falloff_maxdist 0
+set g_balance_lightning_primary_falloff_halflifedist 0
+set g_balance_lightning_primary_force 425
+set g_balance_lightning_primary_lifetime 0
+set g_balance_lightning_primary_radius 850
+set g_balance_lightning_primary_range 800
+set g_balance_lightning_primary_refire 0.4
+set g_balance_lightning_primary_speed 0
+set g_balance_lightning_primary_spread 0
+set g_balance_lightning_secondary_ammo 5
+set g_balance_lightning_secondary_animtime 0.5
+set g_balance_lightning_secondary_damage 100
+set g_balance_lightning_secondary_damageforcescale 4
+set g_balance_lightning_secondary_edgedamage 80
+set g_balance_lightning_secondary_flyingdamage 1
+set g_balance_lightning_secondary_flyingforce -80
+set g_balance_lightning_secondary_flyingradius 200
+set g_balance_lightning_secondary_force -200
+set g_balance_lightning_secondary_health 1
+set g_balance_lightning_secondary_lifetime 30
+set g_balance_lightning_secondary_radius 300
+set g_balance_lightning_secondary_refire 5
+set g_balance_lightning_secondary_speed 600
+// }}}
// {{{ crylink
set g_balance_crylink_primary_damage 7 // LOG: 10 -> 7
set g_balance_crylink_primary_edgedamage 4 // LOG: 6 -> 4
set g_balance_electro_combo_comboradius 0
set g_balance_electro_combo_speed 1000
// }}}
+// {{{ lightning
+set g_balance_lightning_primary_ammo 5
+set g_balance_lightning_primary_animtime 0.2
+set g_balance_lightning_primary_damage 100
+set g_balance_lightning_primary_edgedamage 0
+set g_balance_lightning_primary_falloff_mindist 0
+set g_balance_lightning_primary_falloff_maxdist 0
+set g_balance_lightning_primary_falloff_halflifedist 0
+set g_balance_lightning_primary_force 425
+set g_balance_lightning_primary_lifetime 0
+set g_balance_lightning_primary_radius 850
+set g_balance_lightning_primary_range 800
+set g_balance_lightning_primary_refire 0.4
+set g_balance_lightning_primary_speed 0
+set g_balance_lightning_primary_spread 0
+set g_balance_lightning_secondary_ammo 5
+set g_balance_lightning_secondary_animtime 0.5
+set g_balance_lightning_secondary_damage 100
+set g_balance_lightning_secondary_damageforcescale 4
+set g_balance_lightning_secondary_edgedamage 80
+set g_balance_lightning_secondary_flyingdamage 1
+set g_balance_lightning_secondary_flyingforce -80
+set g_balance_lightning_secondary_flyingradius 200
+set g_balance_lightning_secondary_force -200
+set g_balance_lightning_secondary_health 1
+set g_balance_lightning_secondary_lifetime 30
+set g_balance_lightning_secondary_radius 300
+set g_balance_lightning_secondary_refire 5
+set g_balance_lightning_secondary_speed 600
+// }}}
// {{{ crylink
set g_balance_crylink_primary_damage 5
set g_balance_crylink_primary_edgedamage 3
float autocvar_g_balance_laser_secondary_lifetime;
float autocvar_g_balance_laser_secondary_radius;
float autocvar_g_balance_laser_secondary_speed;
+float autocvar_g_balance_lightning_primary_ammo;
+float autocvar_g_balance_lightning_primary_animtime;
+float autocvar_g_balance_lightning_primary_damage;
+float autocvar_g_balance_lightning_primary_edgedamage;
+float autocvar_g_balance_lightning_primary_falloff_halflifedist;
+float autocvar_g_balance_lightning_primary_falloff_maxdist;
+float autocvar_g_balance_lightning_primary_falloff_mindist;
+float autocvar_g_balance_lightning_primary_force;
+float autocvar_g_balance_lightning_primary_lifetime;
+float autocvar_g_balance_lightning_primary_radius;
+float autocvar_g_balance_lightning_primary_range;
+float autocvar_g_balance_lightning_primary_refire;
+float autocvar_g_balance_lightning_primary_speed;
+float autocvar_g_balance_lightning_secondary_ammo;
+float autocvar_g_balance_lightning_secondary_animtime;
+float autocvar_g_balance_lightning_secondary_damage;
+float autocvar_g_balance_lightning_secondary_damageforcescale;
+float autocvar_g_balance_lightning_secondary_edgedamage;
+float autocvar_g_balance_lightning_secondary_flyingdamage;
+float autocvar_g_balance_lightning_secondary_flyingforce;
+float autocvar_g_balance_lightning_secondary_flyingradius;
+float autocvar_g_balance_lightning_secondary_force;
+float autocvar_g_balance_lightning_secondary_health;
+float autocvar_g_balance_lightning_secondary_lifetime;
+float autocvar_g_balance_lightning_secondary_radius;
+float autocvar_g_balance_lightning_secondary_refire;
+float autocvar_g_balance_lightning_secondary_speed;
float autocvar_g_balance_minelayer_ammo;
float autocvar_g_balance_minelayer_animtime;
float autocvar_g_balance_minelayer_damage;
if(sf & 1)
{
WriteByte(MSG_ENTITY, num_for_edict(self.owner));
- WriteCoord(MSG_ENTITY, autocvar_g_balance_electro_primary_range);
+ WriteCoord(MSG_ENTITY, autocvar_g_balance_lightning_primary_range);
}
if(sf & 2)
{
dt = frametime;
if not(self.owner.items & IT_UNLIMITED_WEAPON_AMMO)
{
- if(autocvar_g_balance_electro_primary_ammo)
+ if(autocvar_g_balance_lightning_primary_ammo)
{
- dt = min(dt, self.owner.ammo_cells / autocvar_g_balance_electro_primary_ammo);
- self.owner.ammo_cells = max(0, self.owner.ammo_cells - autocvar_g_balance_electro_primary_ammo * frametime);
+ dt = min(dt, self.owner.ammo_cells / autocvar_g_balance_lightning_primary_ammo);
+ self.owner.ammo_cells = max(0, self.owner.ammo_cells - autocvar_g_balance_lightning_primary_ammo * frametime);
}
}
- W_SetupShot_Range(self.owner, TRUE, 0, "", 0, autocvar_g_balance_electro_primary_damage * dt, autocvar_g_balance_electro_primary_range);
+ W_SetupShot_Range(self.owner, TRUE, 0, "", 0, autocvar_g_balance_lightning_primary_damage * dt, autocvar_g_balance_lightning_primary_range);
WarpZone_traceline_antilag(self.owner, w_shotorg, w_shotend, MOVE_NORMAL, self.owner, ANTILAG_LATENCY(self.owner));
// apply the damage
if(trace_ent)
{
vector force;
- force = w_shotdir * autocvar_g_balance_electro_primary_force + '0 0 1' * autocvar_g_balance_electro_primary_force_up;
+ force = w_shotdir * autocvar_g_balance_lightning_primary_force;
- f = ExponentialFalloff(autocvar_g_balance_electro_primary_falloff_mindist, autocvar_g_balance_electro_primary_falloff_maxdist, autocvar_g_balance_electro_primary_falloff_halflifedist, vlen(WarpZone_UnTransformOrigin(WarpZone_trace_transform, trace_endpos) - w_shotorg));
+ f = ExponentialFalloff(autocvar_g_balance_lightning_primary_falloff_mindist, autocvar_g_balance_lightning_primary_falloff_maxdist, autocvar_g_balance_lightning_primary_falloff_halflifedist, vlen(WarpZone_UnTransformOrigin(WarpZone_trace_transform, trace_endpos) - w_shotorg));
if(accuracy_isgooddamage(self.owner, trace_ent))
- accuracy_add(self.owner, WEP_LIGHTNING, 0, autocvar_g_balance_electro_primary_damage * dt * f);
- Damage (trace_ent, self.owner, self.owner, autocvar_g_balance_electro_primary_damage * dt * f, WEP_LIGHTNING, trace_endpos, force * dt);
+ accuracy_add(self.owner, WEP_LIGHTNING, 0, autocvar_g_balance_lightning_primary_damage * dt * f);
+ Damage (trace_ent, self.owner, self.owner, autocvar_g_balance_lightning_primary_damage * dt * f, WEP_LIGHTNING, trace_endpos, force * dt);
}
// draw effect
beam.think = W_Lightning_Beam_Think;
beam.owner = self;
beam.movetype = MOVETYPE_NONE;
- beam.shot_spread = 0;
+ beam.shot_spread = 1;
beam.bot_dodge = TRUE;
- beam.bot_dodgerating = autocvar_g_balance_electro_primary_damage;
+ beam.bot_dodgerating = autocvar_g_balance_lightning_primary_damage;
Net_LinkEntity(beam, FALSE, 0, W_Lightning_Beam_Send);
oldself = self;
{
float shoot;
- if(autocvar_g_balance_electro_primary_speed)
- shoot = bot_aim(autocvar_g_balance_electro_primary_speed, 0, autocvar_g_balance_electro_primary_lifetime, FALSE);
+ if(autocvar_g_balance_lightning_primary_speed)
+ shoot = bot_aim(autocvar_g_balance_lightning_primary_speed, 0, autocvar_g_balance_lightning_primary_lifetime, FALSE);
else
shoot = bot_aim(1000000, 0, 0.001, FALSE);
}
else // todo
{
- //if(bot_aim(autocvar_g_balance_electro_secondary_speed, autocvar_g_balance_grenadelauncher_secondary_speed_up, autocvar_g_balance_electro_secondary_lifetime, TRUE))
+ //if(bot_aim(autocvar_g_balance_lightning_secondary_speed, autocvar_g_balance_grenadelauncher_secondary_speed_up, autocvar_g_balance_lightning_secondary_lifetime, TRUE))
//{
// self.BUTTON_ATCK2 = TRUE;
// if(random() < 0.03) self.bot_aim_whichfiretype = 0;
{
if(self.BUTTON_ATCK_prev)
if(self.animstate_startframe == self.anim_shoot_x && self.animstate_numframes == self.anim_shoot_y)
- weapon_thinkf(WFRAME_DONTCHANGE, autocvar_g_balance_electro_primary_animtime, w_ready);
+ weapon_thinkf(WFRAME_DONTCHANGE, autocvar_g_balance_lightning_primary_animtime, w_ready);
else
- weapon_thinkf(WFRAME_FIRE1, autocvar_g_balance_electro_primary_animtime, w_ready);
+ weapon_thinkf(WFRAME_FIRE1, autocvar_g_balance_lightning_primary_animtime, w_ready);
if (weapon_prepareattack(0, 0))
{
if(!self.BUTTON_ATCK_prev)
{
- weapon_thinkf(WFRAME_FIRE1, autocvar_g_balance_electro_primary_animtime, w_ready);
+ weapon_thinkf(WFRAME_FIRE1, autocvar_g_balance_lightning_primary_animtime, w_ready);
self.BUTTON_ATCK_prev = 1;
}
}
{
if (self.BUTTON_ATCK_prev != 0)
{
- weapon_thinkf(WFRAME_FIRE1, autocvar_g_balance_electro_primary_animtime, w_ready);
- ATTACK_FINISHED(self) = time + autocvar_g_balance_electro_primary_refire * W_WeaponRateFactor();
+ weapon_thinkf(WFRAME_FIRE1, autocvar_g_balance_lightning_primary_animtime, w_ready);
+ ATTACK_FINISHED(self) = time + autocvar_g_balance_lightning_primary_refire * W_WeaponRateFactor();
}
self.BUTTON_ATCK_prev = 0;
}
//if (self.BUTTON_ATCK2)
- //if (weapon_prepareattack(1, autocvar_g_balance_electro_secondary_refire))
+ //if (weapon_prepareattack(1, autocvar_g_balance_lightning_secondary_refire))
//{
// W_Lightning_Attack2();
- // self.lightning_count = autocvar_g_balance_electro_secondary_count;
- // weapon_thinkf(WFRAME_FIRE2, autocvar_g_balance_electro_secondary_animtime, w_lightning_checkattack);
- // self.lightning_secondarytime = time + autocvar_g_balance_electro_secondary_refire2 * W_WeaponRateFactor();
+ // self.lightning_count = autocvar_g_balance_lightning_secondary_count;
+ // weapon_thinkf(WFRAME_FIRE2, autocvar_g_balance_lightning_secondary_animtime, w_lightning_checkattack);
+ // self.lightning_secondarytime = time + autocvar_g_balance_lightning_secondary_refire2 * W_WeaponRateFactor();
//}
}
else if (req == WR_PRECACHE)
weapon_setup(WEP_LIGHTNING);
else if (req == WR_CHECKAMMO1)
{
- return !autocvar_g_balance_electro_primary_ammo || (self.ammo_cells > 0);
+ return !autocvar_g_balance_lightning_primary_ammo || (self.ammo_cells > 0);
}
else if (req == WR_CHECKAMMO2)
- return self.ammo_cells >= autocvar_g_balance_electro_secondary_ammo;
+ return self.ammo_cells >= autocvar_g_balance_lightning_secondary_ammo;
else if (req == WR_RESETPLAYER)
{
//self.lightning_secondarytime = time;