fix some uninitialized variables that qfcc has so far detected

This commit is contained in:
Bill Currie 2001-10-18 20:10:39 +00:00
parent 09bf5a80dc
commit 23d81b1e8c
3 changed files with 4 additions and 2 deletions

View file

@ -1738,7 +1738,7 @@ void () GruntyPayThink =
// Consider buying a health pack
if (self.health < self.max_health && self.money >= GRUNTY_COST_HEALTHPACK)
{
local float loops, bought;
local float loops = 0, bought;
bought=0;
while (loops < (0.75+(self.has_sensor/4)) && self.money >= GRUNTY_COST_HEALTHPACK && self.max_health > self.health)

View file

@ -66,7 +66,7 @@ void () TeamFortress_CheckForSpeed =
local vector tempvec;
local float dist;
#endif
local float max, check, immune;
local float max, check, immune = 0;
local string nospeed;
local float off;

View file

@ -1344,6 +1344,8 @@ void() W_FireSniperRifle =
src = self.origin + v_forward * 10;
src_z = self.absmin_z + self.size_z * 0.7;
dir = v_forward; //XXX is this correct?
use_this = FALSE;
traceline (src, src + dir*8092, FALSE, self);
if (trace_fraction != 1.0)