fix electro beam aim; fix animtime (must not be zero or network spam)
authorRudolf Polzer <divverent@alientrap.org>
Sun, 18 Jul 2010 16:39:02 +0000 (18:39 +0200)
committerRudolf Polzer <divverent@alientrap.org>
Sun, 18 Jul 2010 16:39:02 +0000 (18:39 +0200)
balanceFruit.cfg
balanceXPM.cfg
qcsrc/server/w_electro.qc

index 8c7b4b6..ac93a59 100644 (file)
@@ -313,7 +313,7 @@ set g_balance_electro_primary_speed 0
 set g_balance_electro_primary_spread 0
 set g_balance_electro_primary_lifetime 0
 set g_balance_electro_primary_refire 0
-set g_balance_electro_primary_animtime 0
+set g_balance_electro_primary_animtime 0.05
 set g_balance_electro_primary_ammo 40
 set g_balance_electro_primary_range 800
 set g_balance_electro_primary_velocityfactor 45
index fad804a..ede9c06 100644 (file)
@@ -313,7 +313,7 @@ set g_balance_electro_primary_speed 0
 set g_balance_electro_primary_spread 0
 set g_balance_electro_primary_lifetime 0
 set g_balance_electro_primary_refire 0
-set g_balance_electro_primary_animtime 0
+set g_balance_electro_primary_animtime 0.05
 set g_balance_electro_primary_ammo 40
 set g_balance_electro_primary_range 800
 set g_balance_electro_primary_velocityfactor 45
index eca589c..330adee 100644 (file)
@@ -202,7 +202,7 @@ void lgbeam_think()
        vector force;
        force = angle * cvar("g_balance_electro_primary_force");
 
-       traceline_antilag(self.owner, self.owner.origin, self.owner.origin + angle * cvar("g_balance_electro_primary_range"), FALSE, self.owner, ANTILAG_LATENCY(self.owner));
+       traceline_antilag(self.owner, self.owner.origin + self.owner.view_ofs, self.owner.origin + self.owner.view_ofs + angle * cvar("g_balance_electro_primary_range"), FALSE, self.owner, ANTILAG_LATENCY(self.owner));
 
        self.scale = vlen(self.owner.origin - trace_endpos) / 256 * (0.75 + 0.75 * random());
 }
@@ -231,7 +231,7 @@ void exteriorlgbeam_think()
        vector angle;
        angle = v_forward;
 
-       traceline_antilag(self.owner, self.owner.origin, self.owner.origin + angle * cvar("g_balance_electro_primary_range"), FALSE, self.owner, ANTILAG_LATENCY(self.owner));
+       traceline_antilag(self.owner, self.owner.origin + self.owner.view_ofs, self.owner.origin + self.owner.view_ofs + angle * cvar("g_balance_electro_primary_range"), FALSE, self.owner, ANTILAG_LATENCY(self.owner));
 
        // apply the damage
        if(trace_fraction < 1)