From b72aefe2fa8b2d93f8645a3f1797854eeb3f8dc8 Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Wed, 13 May 2026 13:54:40 +0200 Subject: [PATCH] Update terrain grid commitment logic and refine UI descriptions for grid settings --- src/app/App.tsx | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/app/App.tsx b/src/app/App.tsx index 2626365f..911564c2 100644 --- a/src/app/App.tsx +++ b/src/app/App.tsx @@ -10298,12 +10298,18 @@ export function App({ }); const terrainLabel = getTerrainLabelById(selectedTerrain.id, terrainList); - commitTerrainChange( + const committed = commitTerrainChange( selectedTerrain, nextTerrain, "Resize terrain grid", - `Resampled ${terrainLabel} to ${nextTerrain.sampleCountX} x ${nextTerrain.sampleCountZ} samples with ${nextTerrain.cellSize}m square cells.` + `Updated ${terrainLabel} to ${nextTerrain.sampleCountX} x ${nextTerrain.sampleCountZ} samples with ${nextTerrain.cellSize}m square cells.` ); + + if (committed) { + setTerrainSampleCountXDraft(String(nextTerrain.sampleCountX)); + setTerrainSampleCountZDraft(String(nextTerrain.sampleCountZ)); + setTerrainCellSizeDraft(String(nextTerrain.cellSize)); + } } catch (error) { setStatusMessage(getErrorMessage(error)); } @@ -21242,8 +21248,8 @@ export function App({
Grid Settings
- Resizing keeps the terrain centered and resamples heights - and paint across the new grid. + Cell Size changes resolution while preserving footprint. + Samples X/Z extend or crop terrain size.