summaryrefslogtreecommitdiffstats
path: root/tetris/tetris.c
diff options
context:
space:
mode:
authorpgoyette <pgoyette@NetBSD.org>2014-07-13 16:23:55 +0000
committerpgoyette <pgoyette@NetBSD.org>2014-07-13 16:23:55 +0000
commitc1575446b4355046bd6cf7f905cab749762c5306 (patch)
treeea23e632dcea07b44f53789c1b8572cab84fa207 /tetris/tetris.c
parentd50718e53412f5ea2897755a7841ac38a58256f5 (diff)
downloadbsdgames-darwin-c1575446b4355046bd6cf7f905cab749762c5306.tar.gz
bsdgames-darwin-c1575446b4355046bd6cf7f905cab749762c5306.tar.zst
bsdgames-darwin-c1575446b4355046bd6cf7f905cab749762c5306.zip
Provide an option to restore traditional black-and-white mode.
Diffstat (limited to 'tetris/tetris.c')
-rw-r--r--tetris/tetris.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/tetris/tetris.c b/tetris/tetris.c
index 9ccaa2f4..3c0d6afe 100644
--- a/tetris/tetris.c
+++ b/tetris/tetris.c
@@ -1,4 +1,4 @@
-/* $NetBSD: tetris.c,v 1.25 2014/06/11 16:47:39 christos Exp $ */
+/* $NetBSD: tetris.c,v 1.26 2014/07/13 16:23:55 pgoyette Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -73,6 +73,7 @@ gid_t gid, egid;
char key_msg[100];
int showpreview;
+int nocolor;
static void elide(void);
static void setup_board(void);
@@ -144,8 +145,11 @@ main(int argc, char *argv[])
keys = "jkl pq";
- while ((ch = getopt(argc, argv, "k:l:ps")) != -1)
+ while ((ch = getopt(argc, argv, "ck:l:ps")) != -1)
switch(ch) {
+ case 'c':
+ nocolor = 1;
+ break;
case 'k':
if (strlen(keys = optarg) != 6)
usage();