From d9aab1034c4c9fe8b7689b94e90d3b1b80458d2e Mon Sep 17 00:00:00 2001 From: havoc Date: Sat, 8 Mar 2008 18:57:54 +0000 Subject: [PATCH] fix crash when q1bsp submodels are checked with PointSuperContents (oops) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8196 d7cf8633-e32d-0410-b094-e92efae38249 --- model_brush.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/model_brush.c b/model_brush.c index 53da2329..ab1146c0 100644 --- a/model_brush.c +++ b/model_brush.c @@ -885,9 +885,9 @@ static void Mod_Q1BSP_TraceBox(struct model_s *model, int frame, trace_t *trace, static int Mod_Q1BSP_PointSuperContents(struct model_s *model, int frame, const vec3_t point) { - int num = 0; + int num = model->brushq1.hulls[0].firstclipnode; mplane_t *plane; - mclipnode_t *nodes = model->brushq1.hulls[0].clipnodes + model->brushq1.hulls[0].firstclipnode; + mclipnode_t *nodes = model->brushq1.hulls[0].clipnodes; mplane_t *planes = model->brushq1.hulls[0].planes; while (num >= 0) { -- 2.39.2