From 491556ae8663fb14efed17c3a2b50770f7760afc Mon Sep 17 00:00:00 2001 From: havoc Date: Mon, 29 Aug 2005 05:44:23 +0000 Subject: [PATCH] forgot one part of the shadowmesh fix git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5668 d7cf8633-e32d-0410-b094-e92efae38249 --- model_brush.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/model_brush.c b/model_brush.c index 0c4598e8..411a52fd 100644 --- a/model_brush.c +++ b/model_brush.c @@ -3008,8 +3008,11 @@ void Mod_Q1BSP_Load(model_t *mod, void *buffer, void *bufferend) numshadowmeshtriangles = 0; for (j = 0, surface = loadmodel->data_surfaces;j < loadmodel->num_surfaces;j++, surface++) { - surface->num_firstshadowmeshtriangle = numshadowmeshtriangles; - numshadowmeshtriangles += surface->num_triangles; + if (surface->texture->basematerialflags & MATERIALFLAG_SOLID) + { + surface->num_firstshadowmeshtriangle = numshadowmeshtriangles; + numshadowmeshtriangles += surface->num_triangles; + } } loadmodel->brush.shadowmesh = Mod_ShadowMesh_Begin(loadmodel->mempool, numshadowmeshtriangles * 3, numshadowmeshtriangles, NULL, NULL, NULL, false, false, true); for (j = 0, surface = loadmodel->data_surfaces;j < loadmodel->num_surfaces;j++, surface++) -- 2.39.2