This commit is contained in:
2026-06-28 00:17:08 -05:00
parent 9de31d933b
commit 83409a5c25
6 changed files with 17 additions and 20 deletions
+2 -3
View File
@@ -103,11 +103,10 @@ impl Board {
/// Replace the solid (if any) at `(x, y)` with `Empty`
pub fn clear_solid(&mut self, x: usize, y: usize) {
if self.in_bounds((x as i64, y as i64)) {
if let Some(z) = self.solid_cell_layer(x, y) {
if self.in_bounds((x as i64, y as i64))
&& let Some(z) = self.solid_cell_layer(x, y) {
*self.get_mut(z, x, y) = (Archetype::Empty.default_glyph(), Archetype::Empty)
}
}
}
/// Returns the glyph to display at `(x, y)`, honoring layer draw order.