curses splash/copyright screen, role prompt

Back out '#include "date.h"' so that cursinit.c won't be recompiled
every time any other file(s) need to be compiled.  It doesn't need
patchlevel.h either.  There is already a straightforward way to fetch
the copyright banner lines from version.c.

The splash screen (ascii art spelling "NetHack" preceding the normal
copyright lines) was invisible when showing white text on white-ish
background.  Make it honor !guicolor.

"Shall I pick a character's role, race, gender and alignment for you?
 [ynaq] (y) " was too wide to accept the answer on the same line on
an 80-column display so "(y) " was placed on the second line.  That's
constructed in the core; change the construction to omit " a" when
using "character" rather than a role name.  (tty shortens it by omitting
the default " (y)"; with " a" gone, it could revert to normal prompt.)

Also a bit of lint cleanup and some reformatting of cursinit.c....
This commit is contained in:
PatR
2018-12-29 18:38:30 -08:00
parent 9a9f76bf5c
commit d418008b31
5 changed files with 86 additions and 95 deletions

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 role.c $NHDT-Date: 1463561393 2016/05/18 08:49:53 $ $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.38 $ */
/* NetHack 3.6 role.c $NHDT-Date: 1546137492 2018/12/30 02:38:12 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.55 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985-1999. */
/*-Copyright (c) Robert Patrick Rankin, 2012. */
/* NetHack may be freely redistributed. See license for details. */
@@ -1631,13 +1631,16 @@ int buflen, rolenum, racenum, gendnum, alignnum;
Strcpy(tmpbuf, "Shall I pick ");
if (racenum != ROLE_NONE || validrole(rolenum))
Strcat(tmpbuf, "your ");
else {
else
Strcat(tmpbuf, "a ");
}
/* <your> */
(void) root_plselection_prompt(eos(tmpbuf), buflen - strlen(tmpbuf),
rolenum, racenum, gendnum, alignnum);
/* "Shall I pick a character's role, race, gender, and alignment for you?"
plus " [ynaq] (y)" is a little too long for a conventional 80 columns;
also, "pick a character's <anything>" sounds a bit stilted */
strsubst(tmpbuf, "pick a character", "pick character");
Sprintf(buf, "%s", s_suffix(tmpbuf));
/* don't bother splitting caveman/cavewoman or priest/priestess
in order to apply possessive suffix to both halves, but do

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 version.c $NHDT-Date: 1524693365 2018/04/25 21:56:05 $ $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.49 $ */
/* NetHack 3.6 version.c $NHDT-Date: 1546137502 2018/12/30 02:38:22 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.51 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Michael Allison, 2018. */
/* NetHack may be freely redistributed. See license for details. */
@@ -68,7 +68,8 @@ char *buf;
#if defined(NETHACK_GIT_BRANCH)
#if defined(BETA)
if (NetHack_git_branch)
Sprintf(eos(buf), "%sbranch:%s", c++ ? "," : "", NetHack_git_branch);
Sprintf(eos(buf), "%sbranch:%s",
c++ ? "," : "", NetHack_git_branch);
#endif
#endif
Sprintf(eos(buf), ")");