From 94e0df832c83bc7b9ead0824cfbc41f166869c68 Mon Sep 17 00:00:00 2001 From: kasull Date: Thu, 26 Feb 2026 04:31:08 -0500 Subject: add wall shape dropdown and drag-based polygon creation with height controls fix wall Z bounds calculation and key index masking in input handling preserve 2D view/cursor stability when map bounds update --- src/game/world/map.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/game/world/map.cpp') diff --git a/src/game/world/map.cpp b/src/game/world/map.cpp index 53cfe22..ba6bb00 100644 --- a/src/game/world/map.cpp +++ b/src/game/world/map.cpp @@ -404,11 +404,11 @@ void map_calc_bounds( WORLD_MAP* m ) { m->walls.each( fn( MAP_WALL* l ) { m->mins.x = min( min( l->start.x, l->end.x ), m->mins.x ); m->mins.y = min( min( l->start.y, l->end.y ), m->mins.y ); - m->mins.z = min( min( l->start.z, l->start.x + l->end.z ), m->mins.z ); + m->mins.z = min( min( l->start.z, l->start.z + l->end.z ), m->mins.z ); m->maxs.x = max( max( l->start.x, l->end.x ), m->maxs.x ); m->maxs.y = max( max( l->start.y, l->end.y ), m->maxs.y ); - m->maxs.z = max( max( l->start.z, l->start.x + l->end.z ), m->maxs.z ); + m->maxs.z = max( max( l->start.z, l->start.z + l->end.z ), m->maxs.z ); } ); m->polygons.each( fn( MAP_POLYGON* p ) { @@ -428,11 +428,11 @@ void map_check_bounds( WORLD_MAP* m ) { m->walls.each( fn( MAP_WALL* l ) { mins.x = min( min( l->start.x, l->end.x ), mins.x ); mins.y = min( min( l->start.y, l->end.y ), mins.y ); - mins.z = min( min( l->start.z, l->start.x + l->end.z ), mins.z ); + mins.z = min( min( l->start.z, l->start.z + l->end.z ), mins.z ); maxs.x = max( max( l->start.x, l->end.x ), maxs.x ); maxs.y = max( max( l->start.y, l->end.y ), maxs.y ); - maxs.z = max( max( l->start.z, l->start.x + l->end.z ), maxs.z ); + maxs.z = max( max( l->start.z, l->start.z + l->end.z ), maxs.z ); } ); m->polygons.each( fn( MAP_POLYGON* p ) { -- cgit v1.2.3