set g_balance_crylink_primary_bouncedamagefactor 0.5
set g_balance_crylink_primary_joindelay 0
set g_balance_crylink_primary_joinspread 0
-set g_balance_crylink_primary_jointime 0
set g_balance_crylink_primary_joinexplode 0
set g_balance_crylink_primary_joinexplode_damage 0
set g_balance_crylink_primary_joinexplode_edgedamage 0
set g_balance_crylink_secondary_bouncedamagefactor 0.5
set g_balance_crylink_secondary_joindelay 0
set g_balance_crylink_secondary_joinspread 0
-set g_balance_crylink_secondary_jointime 0
set g_balance_crylink_secondary_joinexplode 0
set g_balance_crylink_secondary_joinexplode_damage 0
set g_balance_crylink_secondary_joinexplode_edgedamage 0
set g_balance_crylink_primary_bouncedamagefactor 0.2
set g_balance_crylink_primary_joindelay 0
set g_balance_crylink_primary_joinspread 0.2
-set g_balance_crylink_primary_jointime 0.1
set g_balance_crylink_primary_joinexplode 0
set g_balance_crylink_primary_joinexplode_damage 0
set g_balance_crylink_primary_joinexplode_edgedamage 0
set g_balance_crylink_secondary_bouncedamagefactor 0.4 // LOG: 0.2 -> 0.4
set g_balance_crylink_secondary_joindelay 0
set g_balance_crylink_secondary_joinspread 0.2
-set g_balance_crylink_secondary_jointime 0.1
set g_balance_crylink_secondary_joinexplode 0
set g_balance_crylink_secondary_joinexplode_damage 0
set g_balance_crylink_secondary_joinexplode_edgedamage 0
set g_balance_crylink_primary_bouncedamagefactor 0.5
set g_balance_crylink_primary_joindelay 0.1
set g_balance_crylink_primary_joinspread 0.2
-set g_balance_crylink_primary_jointime 0
set g_balance_crylink_primary_joinexplode 1
set g_balance_crylink_primary_joinexplode_damage 0
set g_balance_crylink_primary_joinexplode_edgedamage 0
set g_balance_crylink_secondary_bouncedamagefactor 0.5
set g_balance_crylink_secondary_joindelay 0
set g_balance_crylink_secondary_joinspread 0
-set g_balance_crylink_secondary_jointime 0
set g_balance_crylink_secondary_joinexplode 0
set g_balance_crylink_secondary_joinexplode_damage 0
set g_balance_crylink_secondary_joinexplode_edgedamage 0
set g_balance_crylink_primary_bouncedamagefactor 0.5
set g_balance_crylink_primary_joindelay 0.1
set g_balance_crylink_primary_joinspread 0.2
-set g_balance_crylink_primary_jointime 0
set g_balance_crylink_primary_joinexplode 1
set g_balance_crylink_primary_joinexplode_damage 0
set g_balance_crylink_primary_joinexplode_edgedamage 0
set g_balance_crylink_secondary_bouncedamagefactor 0.5
set g_balance_crylink_secondary_joindelay 0
set g_balance_crylink_secondary_joinspread 0
-set g_balance_crylink_secondary_jointime 0
set g_balance_crylink_secondary_joinexplode 0
set g_balance_crylink_secondary_joinexplode_damage 0
set g_balance_crylink_secondary_joinexplode_edgedamage 0
set g_balance_crylink_primary_bouncedamagefactor 0.5
set g_balance_crylink_primary_joindelay 0.1
set g_balance_crylink_primary_joinspread 0.2
-set g_balance_crylink_primary_jointime 0
set g_balance_crylink_primary_joinexplode 1
set g_balance_crylink_primary_joinexplode_damage 0
set g_balance_crylink_primary_joinexplode_edgedamage 0
set g_balance_crylink_secondary_bouncedamagefactor 0.5
set g_balance_crylink_secondary_joindelay 0
set g_balance_crylink_secondary_joinspread 0
-set g_balance_crylink_secondary_jointime 0
set g_balance_crylink_secondary_joinexplode 0
set g_balance_crylink_secondary_joinexplode_damage 0
set g_balance_crylink_secondary_joinexplode_edgedamage 0
float autocvar_g_balance_crylink_primary_joinexplode_force;
float autocvar_g_balance_crylink_primary_joinexplode_radius;
float autocvar_g_balance_crylink_primary_joinspread;
-float autocvar_g_balance_crylink_primary_jointime;
float autocvar_g_balance_crylink_primary_linkexplode;
float autocvar_g_balance_crylink_primary_middle_fadetime;
float autocvar_g_balance_crylink_primary_middle_lifetime;
float autocvar_g_balance_crylink_secondary_joinexplode_force;
float autocvar_g_balance_crylink_secondary_joinexplode_radius;
float autocvar_g_balance_crylink_secondary_joinspread;
-float autocvar_g_balance_crylink_secondary_jointime;
float autocvar_g_balance_crylink_secondary_line_fadetime;
float autocvar_g_balance_crylink_secondary_line_lifetime;
float autocvar_g_balance_crylink_secondary_linkexplode;
// stored in w_crylink_linkjoin_time.
// could possibly network this origin and time, and display a special particle
// effect when projectiles meet there :P
-// jspeed: MINIMUM jing speed
-// jtime: MAXIMUM jing time (0: none)
+// jspeed: joining speed (calculate this as join spread * initial speed)
float w_crylink_linkjoin_time;
-vector W_Crylink_LinkJoin(entity e, float jspeed, float jtime)
+vector W_Crylink_LinkJoin(entity e, float jspeed)
{
vector avg_origin, avg_velocity;
vector targ_origin;
if(avg_dist == 0)
return avg_origin; // no change needed
- if(jspeed == 0 && jtime == 0)
+ if(jspeed == 0)
{
e.velocity = avg_velocity;
UpdateCSQCProjectile(e);
}
else
{
- if(jtime)
- {
- if(jspeed)
- w_crylink_linkjoin_time = min(jtime, avg_dist / jspeed);
- else
- w_crylink_linkjoin_time = jtime;
- }
- else
w_crylink_linkjoin_time = avg_dist / jspeed;
targ_origin = avg_origin + w_crylink_linkjoin_time * avg_velocity;
other = proj; MUTATOR_CALLHOOK(EditProjectile);
}
- if(autocvar_g_balance_crylink_primary_joinspread != 0 || autocvar_g_balance_crylink_primary_jointime != 0)
+ if(autocvar_g_balance_crylink_primary_joinspread != 0)
{
self.crylink_lastgroup = proj;
W_Crylink_CheckLinks(proj);
other = proj; MUTATOR_CALLHOOK(EditProjectile);
}
- if(autocvar_g_balance_crylink_secondary_joinspread != 0 || autocvar_g_balance_crylink_secondary_jointime != 0)
+ if(autocvar_g_balance_crylink_secondary_joinspread != 0)
{
self.crylink_lastgroup = proj;
W_Crylink_CheckLinks(proj);
if(self.crylink_waitrelease == 1)
{
- pos = W_Crylink_LinkJoin(self.crylink_lastgroup, autocvar_g_balance_crylink_primary_joinspread * autocvar_g_balance_crylink_primary_speed, autocvar_g_balance_crylink_primary_jointime);
+ pos = W_Crylink_LinkJoin(self.crylink_lastgroup, autocvar_g_balance_crylink_primary_joinspread * autocvar_g_balance_crylink_primary_speed);
}
else
{
- pos = W_Crylink_LinkJoin(self.crylink_lastgroup, autocvar_g_balance_crylink_secondary_joinspread * autocvar_g_balance_crylink_secondary_speed, autocvar_g_balance_crylink_secondary_jointime);
+ pos = W_Crylink_LinkJoin(self.crylink_lastgroup, autocvar_g_balance_crylink_secondary_joinspread * autocvar_g_balance_crylink_secondary_speed);
}
linkjoineffect = spawn();