From 0145a3df453bdf5a6818caa18b4ff3d30d8eebd6 Mon Sep 17 00:00:00 2001 From: Garux Date: Thu, 7 Nov 2024 05:17:17 +0500 Subject: [PATCH] apply bevel surfaceflags unconditionally seemingly does not add extra bsp shaders useful in Urban Terror to prevent walljumps by slick surfaceparm --- tools/quake3/q3map2/map.cpp | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/tools/quake3/q3map2/map.cpp b/tools/quake3/q3map2/map.cpp index 485b0dd6..7fd2e48d 100644 --- a/tools/quake3/q3map2/map.cpp +++ b/tools/quake3/q3map2/map.cpp @@ -634,14 +634,12 @@ void AddBrushBevels(){ s.planenum = FindFloatPlane( plane, 0, NULL ); s.contentFlags = sides[ 0 ].contentFlags; - /* handle bevel surfaceflags for topmost one only: assuming that only walkable ones are meaningful */ - if( axis == 2 && dir == 1 ){ - for ( const side_t& side : sides ) { - for ( const Vector3& point : side.winding ) { - if ( fabs( plane.dist() - point[axis] ) < .1f ) { - s.surfaceFlags |= ( side.surfaceFlags & surfaceFlagsMask ); - break; - } + /* handle bevel surfaceflags */ + for ( const side_t& side : sides ) { + for ( const Vector3& point : side.winding ) { + if ( fabs( plane.dist() - point[axis] ) < .1f ) { + s.surfaceFlags |= ( side.surfaceFlags & surfaceFlagsMask ); + break; } } }