summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2011-12-13 02:37:15 (EST)
committer P. J. McDermott <pjm@nac.net>2011-12-13 02:37:15 (EST)
commit1bd516fda441eb832a1b8b3eb7ad808e2896d1fc (patch)
treec3a596ee2d42d666f0f942dba3c8df6b5b0e1e3f
parent67c046e4471ea322cc8ec91b680e222e74bc1f71 (diff)
downloadcgol-1bd516fda441eb832a1b8b3eb7ad808e2896d1fc.zip
cgol-1bd516fda441eb832a1b8b3eb7ad808e2896d1fc.tar.gz
cgol-1bd516fda441eb832a1b8b3eb7ad808e2896d1fc.tar.bz2
Fix a compiler warning and add TODO tags.cgol-0.1.0
-rw-r--r--src/cgol.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cgol.c b/src/cgol.c
index 6add490..b779961 100644
--- a/src/cgol.c
+++ b/src/cgol.c
@@ -84,6 +84,7 @@ main(int argc, char **argv)
init_curses();
init_game();
+ /* TODO: Write a better main event loop with a good controller and timer. */
timeout(1000);
for (;;) {
c = getch();
@@ -178,7 +179,6 @@ void
tick()
{
int i, j, n;
- bool *grid_tmp;
for (i = 0; i < height; ++i) {
for (j = 0; j < width; ++j) {
@@ -233,6 +233,7 @@ set_cell(int i, int j, bool s)
void
print_cell(int i, int j, bool next)
{
+ /* TODO: Center this. */
if (next) {
mvprintw(1 + i, 1 + j * 2, "%c", grid_next[i * width + j] ? 'o' : ' ');
} else {