feat(citygen): generator state machine, pathing helpers, terrain stage

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
Jeffrey Wilcke
2026-10-12 16:46:34 +02:00
parent c8d8deeb0f
commit 7c9928214f
5 changed files with 739 additions and 2 deletions

View File

@@ -111,13 +111,13 @@ impl GenParams {
format!("{} is outside 4..=12", self.districts),
));
}
if (w as u64) * (h as u64) < self.districts as u64 * 1000 {
if (w as u64) * (h as u64) < self.districts as u64 * 800 {
return Err(bad(
"districts",
format!(
"too many districts for map size ({} districts need at least {} tiles, map has {})",
self.districts,
self.districts as u64 * 1000,
self.districts as u64 * 800,
w as u64 * h as u64
),
));