diff options
author | P. J. McDermott <pjm@nac.net> | 2013-05-20 16:43:59 (EDT) |
---|---|---|
committer | P. J. McDermott <pjm@nac.net> | 2013-05-20 16:43:59 (EDT) |
commit | 96fd8d93c8b5cc62f4a62dd18ec9ae39e3075666 (patch) | |
tree | 7e86afa2f04a3a72ce6d591979668c58cb8154bb /src | |
parent | 090b6d62acbe03c139f4dcb96d86402c03d25fc3 (diff) | |
download | cursespong-96fd8d93c8b5cc62f4a62dd18ec9ae39e3075666.zip cursespong-96fd8d93c8b5cc62f4a62dd18ec9ae39e3075666.tar.gz cursespong-96fd8d93c8b5cc62f4a62dd18ec9ae39e3075666.tar.bz2 |
Clear paddle artifacts.
Diffstat (limited to 'src')
-rw-r--r-- | src/game.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -93,6 +93,9 @@ draw_paddles(struct game *g) int pos; /* Player 1 horizontal paddle */ + for (pos = 0; pos < 79; ++pos) { + mvprintw(23, pos, " "); + } off = g->players[0]->paddle_h.pos; off -= g->players[0]->paddle_h.size / 2; for (pos = 0; pos < g->players[0]->paddle_h.size; ++pos) { @@ -102,6 +105,9 @@ draw_paddles(struct game *g) } /* Player 1 vertical paddle */ + for (pos = 0; pos < 24; ++pos) { + mvprintw(pos, 1, " "); + } off = g->players[0]->paddle_v.pos; off -= g->players[0]->paddle_v.size / 2; for (pos = 0; pos < g->players[0]->paddle_v.size; ++pos) { @@ -111,6 +117,9 @@ draw_paddles(struct game *g) } /* Player 2 horizontal paddle */ + for (pos = 0; pos < 79; ++pos) { + mvprintw(1, pos, " "); + } off = g->players[1]->paddle_h.pos; off -= g->players[1]->paddle_h.size / 2; for (pos = 0; pos < g->players[1]->paddle_h.size; ++pos) { @@ -120,6 +129,9 @@ draw_paddles(struct game *g) } /* Player 2 vertical paddle */ + for (pos = 0; pos < 24; ++pos) { + mvprintw(pos, 78, " "); + } off = g->players[1]->paddle_v.pos; off -= g->players[1]->paddle_v.size / 2; for (pos = 0; pos < g->players[1]->paddle_v.size; ++pos) { |