From 697035476bc3c37cff9cf75ca4a5211a1875eadd Mon Sep 17 00:00:00 2001 From: Marco Cawthorne Date: Wed, 20 Nov 2024 14:14:32 -0800 Subject: [PATCH] HL2: VBSP prop_statics cast no dynamic shadow, fix dxlevel check when 0 --- plugins/hl2/mod_vbsp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/hl2/mod_vbsp.c b/plugins/hl2/mod_vbsp.c index c8d1bd894..1b13475ef 100644 --- a/plugins/hl2/mod_vbsp.c +++ b/plugins/hl2/mod_vbsp.c @@ -2179,6 +2179,7 @@ static qboolean VBSP_LoadStaticProps(model_t *mod, qbyte *offset, size_t size, i ent->topcolour = TOP_DEFAULT; ent->bottomcolour = BOTTOM_DEFAULT; ent->scale = 1; + ent->flags = RF_NOSHADOW; ent->shaderRGBAf[0] = 1; ent->shaderRGBAf[1] = 1; ent->shaderRGBAf[2] = 1; @@ -2218,7 +2219,7 @@ static qboolean VBSP_LoadStaticProps(model_t *mod, qbyte *offset, size_t size, i unsigned short minlev, maxlev; minlev = LittleShort(*(unsigned short*)prop); prop += sizeof(unsigned short); maxlev = LittleShort(*(unsigned short*)prop); prop += sizeof(unsigned short); - skip |= (minlev > dxlevel || dxlevel > maxlev); + skip |= (minlev > 0) && ((minlev > dxlevel) || (dxlevel > maxlev)); } if (version >= 7) {