From 304f700ebc2837534f108cf2051d3f6224fec8af Mon Sep 17 00:00:00 2001 From: tomaz Date: Wed, 18 Aug 2004 22:22:29 +0000 Subject: [PATCH] Fixed collision: client getting fraction out of bounds errors when in a map the client does not have git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4336 d7cf8633-e32d-0410-b094-e92efae38249 --- cl_collision.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cl_collision.c b/cl_collision.c index 486e8751..3ade5bcf 100644 --- a/cl_collision.c +++ b/cl_collision.c @@ -41,6 +41,11 @@ float CL_TraceLine(const vec3_t start, const vec3_t end, vec3_t impact, vec3_t n matrix4x4_t matrix, imatrix; float tempnormal[3], starttransformed[3], endtransformed[3]; + memset (&trace, 0 , sizeof(trace_t)); + trace.fraction = 1; + trace.realfraction = 1; + VectorCopy (end, trace.endpos); + if (hitent) *hitent = &cl_entities[0].render; Mod_CheckLoaded(cl.worldmodel); -- 2.39.2