From: Jakob MG Date: Sun, 20 Mar 2011 21:56:34 +0000 (+0100) Subject: Fix raptor hud warn spam. X-Git-Tag: xonotic-v0.5.0~199^2~11^2~116 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=9ad632da32c6b848012185b9c48dd107144f58de;p=xonotic%2Fxonotic-data.pk3dir.git Fix raptor hud warn spam. --- diff --git a/qcsrc/client/vehicles/vehicles.qc b/qcsrc/client/vehicles/vehicles.qc index 577f23f36..f54156d47 100644 --- a/qcsrc/client/vehicles/vehicles.qc +++ b/qcsrc/client/vehicles/vehicles.qc @@ -174,9 +174,7 @@ void CSQC_SPIDER_HUD() picsize_y *= autocvar_cl_vehicle_spiderbot_cross_size; drawpic('0.5 0 0' * (vid_conwidth - picsize_x) + '0 0.5 0' * (vid_conheight - picsize_y), SPIDER_CROSS, picsize, '1 1 1', autocvar_cl_vehicle_spiderbot_cross_alpha, DRAWFLAG_ADDITIVE); - } - } @@ -197,9 +195,12 @@ void CSQC_RAPTOR_HUD() } movedt = time - dropmark.move_time; - dropmark.move_time = time; - vel = (view_origin - lastpos) * (1 / movedt); - lastpos = view_origin; + if(movedt) + { + dropmark.move_time = time; + vel = (view_origin - lastpos) * (1 / movedt); + lastpos = view_origin; + } // Fetch health & ammo stats hp = bound(0,getstatf(STAT_VEHICLESTAT_HEALTH), 1); @@ -268,7 +269,7 @@ void CSQC_RAPTOR_HUD() where_z = 0; drawpic(where, raptor_d, picsize, '0 2 0', 1, DRAWFLAG_ADDITIVE); } - dropmark.cnt = time + 2; + dropmark.cnt = time + 5; } else {