diff options
author | hubertf <hubertf@NetBSD.org> | 1999-01-03 17:13:51 +0000 |
---|---|---|
committer | hubertf <hubertf@NetBSD.org> | 1999-01-03 17:13:51 +0000 |
commit | f8df8c0281a2b93b58f947c4bc167c998f05e804 (patch) | |
tree | eea579958c7b97230bca854b4bc469209318c125 /tetris/tetris.c | |
parent | 69a9330f3a35ba66a49fad4835b5188fe59f2bbf (diff) | |
download | bsdgames-darwin-f8df8c0281a2b93b58f947c4bc167c998f05e804.tar.gz bsdgames-darwin-f8df8c0281a2b93b58f947c4bc167c998f05e804.tar.zst bsdgames-darwin-f8df8c0281a2b93b58f947c4bc167c998f05e804.zip |
only show preview if the -p option is given
Diffstat (limited to 'tetris/tetris.c')
-rw-r--r-- | tetris/tetris.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/tetris/tetris.c b/tetris/tetris.c index c5569c9b..f00fb7d7 100644 --- a/tetris/tetris.c +++ b/tetris/tetris.c @@ -1,4 +1,4 @@ -/* $NetBSD: tetris.c,v 1.6 1999/01/03 02:00:18 hubertf Exp $ */ +/* $NetBSD: tetris.c,v 1.7 1999/01/03 17:13:51 hubertf Exp $ */ /*- * Copyright (c) 1992, 1993 @@ -67,10 +67,6 @@ static void setup_board __P((void)); void onintr __P((int)) __attribute__((__noreturn__)); void usage __P((void)) __attribute__((__noreturn__)); -struct shape *curshape; -struct shape *nextshape; - - /* * Set up the initial board. The bottom display row is completely set, * along with another (hidden) row underneath that. Also, the left and @@ -132,7 +128,7 @@ main(argc, argv) keys = "jkl pq"; - while ((ch = getopt(argc, argv, "k:l:s")) != -1) + while ((ch = getopt(argc, argv, "k:l:ps")) != -1) switch(ch) { case 'k': if (strlen(keys = optarg) != 6) @@ -147,6 +143,9 @@ main(argc, argv) exit(1); } break; + case 'p': + showpreview = 1; + break; case 's': showscores(0); exit(0); @@ -319,6 +318,6 @@ onintr(signo) void usage() { - (void)fprintf(stderr, "usage: tetris [-s] [-l level] [-keys]\n"); + (void)fprintf(stderr, "usage: tetris [-ps] [-l level] [-keys]\n"); exit(1); } |