fix: review findings
- screen transitions snapshot the previous frame (ratatui swaps buffers after draw, so the old snapshot was always blank); frame loop extracted into a testable Runner - .city loading rejects structurally inconsistent files: Grid deserialize checks size vs data, load_city checks header vs body and runs City::validate (now also checks Net link endpoints) - saving from the map hands the live map screen back instead of a fresh explore screen - signage glyphs covered by the unicode-width test Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
@@ -152,6 +152,14 @@ impl City {
|
||||
}
|
||||
}
|
||||
|
||||
for link in &self.net.links {
|
||||
for id in [link.0, link.1] {
|
||||
if id.index() >= self.net.nodes.len() {
|
||||
out.push(Violation::NetAnchor(id));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
for d in &self.districts {
|
||||
let has_building = self.buildings.iter().any(|b| b.district == d.id);
|
||||
let has_public = self.connectors.iter().any(|c| {
|
||||
|
||||
Reference in New Issue
Block a user