From: Rudolf Polzer Date: Mon, 19 Jul 2010 10:54:30 +0000 (+0200) Subject: try predicting beam end X-Git-Tag: xonotic-v0.1.0preview~423^2~32 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=baa7cac0bbc84ac152d92be97014e6574b8155d8;p=xonotic%2Fxonotic-data.pk3dir.git try predicting beam end --- diff --git a/qcsrc/client/hook.qc b/qcsrc/client/hook.qc index f67da87fe..d15e34b44 100644 --- a/qcsrc/client/hook.qc +++ b/qcsrc/client/hook.qc @@ -115,17 +115,22 @@ void Draw_GrapplingHook() vs = electro_shotorigin[s]; if(self.sv_entnum == player_localentnum - 1) + { a = view_origin + view_forward * vs_x + view_right * -vs_y + view_up * vs_z; + b = a + view_forward * MAX_SHOT_DISTANCE; + } else + { a = self.LGBeamStart; - b = self.LGBeamEnd; + b = self.LGBeamEnd; + } tex = "particles/lgbeam"; rgb = '1 1 1'; Draw_GrapplingHook_trace_callback_tex = tex; Draw_GrapplingHook_trace_callback_rnd = random(); - WarpZone_TraceBox_ThroughZone(a, '0 0 0', '0 0 0', b, MOVE_NOMONSTERS, world, world, Draw_GrapplingHook_trace_callback); + WarpZone_TraceBox_ThroughZone(a, '0 0 0', '0 0 0', b, MOVE_NORMAL, world, world, Draw_GrapplingHook_trace_callback); Draw_GrapplingHook_trace_callback_tex = string_null; // helps the sound