Handle termbox2 errors

Signed-off-by: AnErrupTion <anerruption@disroot.org>
This commit is contained in:
AnErrupTion
2026-05-17 13:26:46 +02:00
parent 05c1d4bece
commit 4c066ce564
17 changed files with 114 additions and 90 deletions

View File

@@ -129,13 +129,13 @@ fn draw(self: *Doom) void {
// Send known fire levels to terminal buffer
const from_cell = self.fire[level_buf_from];
const to_cell = self.fire[level_buf_to];
from_cell.put(x, y);
to_cell.put(to_x, to_y);
from_cell.put(x, y) catch {};
to_cell.put(to_x, to_y) catch {};
}
// Draw bottom line (fire source)
const src_cell = self.fire[STEPS];
src_cell.put(x, self.terminal_buffer.height - 1);
src_cell.put(x, self.terminal_buffer.height - 1) catch {};
}
}