Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/games/gomoku gomoku: allow saving a finished game without pr...



details:   https://anonhg.NetBSD.org/src/rev/7b3b74b7a229
branches:  trunk
changeset: 366476:7b3b74b7a229
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sat May 28 20:57:26 2022 +0000

description:
gomoku: allow saving a finished game without pressing Shift

diffstat:

 games/gomoku/main.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r cb5d93879c05 -r 7b3b74b7a229 games/gomoku/main.c
--- a/games/gomoku/main.c       Sat May 28 20:54:31 2022 +0000
+++ b/games/gomoku/main.c       Sat May 28 20:57:26 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: main.c,v 1.63 2022/05/28 20:54:31 rillig Exp $ */
+/*     $NetBSD: main.c,v 1.64 2022/05/28 20:57:26 rillig Exp $ */
 
 /*
  * Copyright (c) 1994
@@ -36,7 +36,7 @@
 __COPYRIGHT("@(#) Copyright (c) 1994\
  The Regents of the University of California.  All rights reserved.");
 /*     @(#)main.c      8.4 (Berkeley) 5/4/95   */
-__RCSID("$NetBSD: main.c,v 1.63 2022/05/28 20:54:31 rillig Exp $");
+__RCSID("$NetBSD: main.c,v 1.64 2022/05/28 20:57:26 rillig Exp $");
 
 #include <sys/stat.h>
 #include <curses.h>
@@ -389,7 +389,7 @@
                        int ch = get_key("YyNnQqSs");
                        if (ch == 'Y' || ch == 'y')
                                goto again;
-                       if (ch == 'S') {        /* TODO: add 's' */
+                       if (ch == 'S' || ch == 's') {
                                save_game();
                                goto replay;
                        }



Home | Main Index | Thread Index | Old Index