Make terrain steepness independent of map size #159
Labels
No labels
assets
bug
duplicate
enhancement
help wanted
invalid
question
testing
ui
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
liamjd/UntitledColonyBuilder#159
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Milestone 2, item 3 (first half: "heights too rigid").
Problem
_sample_levels()normalises the raw noise over the window it sampled: it findsraw_min/raw_maxacross the grid and stretches that to −1..1. So every map, whatever its size, spans the fulldatum ± height_scale, which is 15 levels either way at the defaults.A bigger map samples more of the noise field, so it is a gentler landscape; a small one gets the same climb crammed into fewer tiles. Measured over 10 seeds:
Same preset, same parameters, roughly 7× the flat land at 128 as at 16. #158 makes map size a player choice, which turns this from a curiosity into a balance problem: TINY would be the hardest map to build on.
Proposal
Treat a small map as a crop of a landscape, not a squashed copy of a large one. Per-tile steepness should be a property of the preset, not of the grid size.
noise_frequencyis already in per-tile units, so with the fixed normalisation a hill is the same size in tiles on every map._shape_crater,_shape_canyon, the island falloff) are expressed in_radial()fractions of the map, so they do shrink with the map: a crater rim climbsrim_heightoverrim_radius × grid_size/2tiles. Decide per shape whether that is right. A crater on a TINY map is probably fine as a steeper crater, but the canyon'scanyon_widthas a fraction of the map gives a 3-tile canyon at 32. Record the decision in the code either way.Measurement
Commit a
tools/probe_terrain_stats.gd(the measurement above was taken with a scratch version). For each preset × size × N seeds it prints: walkable share, main-region share, flat 3×3 site count (min/avg, zero-site seeds), level range, and flat-tile share. A headless-sscript is fine:TerrainGriddoes not reach an autoload. The later milestone 2 tickets quote it for their before/after numbers.Acceptance criteria
test_terrain_seed.gdstays green.Depends on
Nothing hard. Worth landing before #160, which tunes the distribution on top of this range.