From a59958312ffb1e2cb368b5acb57b3376276c39ea Mon Sep 17 00:00:00 2001 From: Mario Kilies Date: Fri, 14 Jan 2011 04:45:04 +0100 Subject: draw_cardstack() clears visible remains of old card stacks before drawing the new one. --- src/ui.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src') diff --git a/src/ui.c b/src/ui.c index e7b7657..c9409df 100644 --- a/src/ui.c +++ b/src/ui.c @@ -125,6 +125,13 @@ static void draw_card(WINDOW *w, const uint8_t row, const uint8_t col, const boo static void draw_cardstack(WINDOW *w, const uint8_t row, const uint8_t col, const bool highlight, const cardstack cs) { + // Clear old card stack first + mvwhline(w, row, col, ' ', 15); + mvwhline(w, row+1, col, ' ', 15); + mvwhline(w, row+2, col, ' ', 15); + mvwhline(w, row+3, col, ' ', 15); + mvwhline(w, row+4, col, ' ', 15); + for (uint8_t i = 0; i < MAX_CARDSTACK_SIZE; i++) { if (cs[i] != 0) -- cgit v1.2.3