Merge branch 'NetHack-3.6'

This commit is contained in:
nhmall
2019-07-07 07:14:45 -04:00
7 changed files with 43 additions and 14 deletions

View File

@@ -5944,8 +5944,8 @@ char def;
res = (*windowprocs.win_yn_function)(query, resp, def);
#ifdef DUMPLOG
if (idx == g.saved_pline_index) {
/* when idx is still the same as saved_pline_index, the interface
didn't put the prompt into saved_plines[]; we put a simplified
/* when idx is still the same as g.saved_pline_index, the interface
didn't put the prompt into g.saved_plines[]; we put a simplified
version in there now (without response choices or default) */
Sprintf(dumplog_buf, "%s ", query);
(void) key2txt((uchar) res, eos(dumplog_buf));

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 dokick.c $NHDT-Date: 1551920353 2019/03/07 00:59:13 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.131 $ */
/* NetHack 3.6 dokick.c $NHDT-Date: 1562462061 2019/07/07 01:14:21 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.133 $ */
/* Copyright (c) Izchak Miller, Mike Stephenson, Steve Linhart, 1989. */
/* NetHack may be freely redistributed. See license for details. */
@@ -1053,9 +1053,9 @@ dokick()
if (Levitation)
goto dumb;
You("kick %s.", (Blind ? something : "the altar"));
altar_wrath(x, y);
if (!rn2(3))
goto ouch;
altar_wrath(x, y);
exercise(A_DEX, TRUE);
return 1;
}

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 mklev.c $NHDT-Date: 1560304468 2019/06/12 01:54:28 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.61 $ */
/* NetHack 3.6 mklev.c $NHDT-Date: 1562455089 2019/07/06 23:18:09 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.63 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Alex Smith, 2017. */
/* NetHack may be freely redistributed. See license for details. */
@@ -581,6 +581,10 @@ clear_level_structures()
register int x, y;
register struct rm *lev;
/* note: normally we'd start at x=1 because map column #0 isn't used
(except for placing vault guard at <0,0> when removed from the map
but not from the level); explicitly reset column #0 along with the
rest so that we start the new level with a completely clean slate */
for (x = 0; x < COLNO; x++) {
lev = &levl[x][0];
for (y = 0; y < ROWNO; y++) {
@@ -635,6 +639,7 @@ clear_level_structures()
xdnstair = ydnstair = xupstair = yupstair = 0;
g.sstairs.sx = g.sstairs.sy = 0;
xdnladder = ydnladder = xupladder = yupladder = 0;
g.dnstairs_room = g.upstairs_room = g.sstairs_room = (struct mkroom *) 0;
g.made_branch = FALSE;
clear_regions();
}
@@ -1014,6 +1019,13 @@ mklev()
for (ridx = 0; ridx < SIZE(g.rooms); ridx++)
g.rooms[ridx].orig_rtype = g.rooms[ridx].rtype;
/* something like this usually belongs in clear_level_structures()
but these aren't saved and restored so might not retain their
values for the life of the current level; reset them to default
now so that they never do and no one will be tempted to introduce
a new use of them for anything on this level */
g.dnstairs_room = g.upstairs_room = g.sstairs_room = (struct mkroom *) 0;
reseed_random(rn2);
reseed_random(rn2_on_display_rng);
}

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 pray.c $NHDT-Date: 1561061321 2019/06/20 20:08:41 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.115 $ */
/* NetHack 3.6 pray.c $NHDT-Date: 1562462064 2019/07/07 01:14:24 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.116 $ */
/* Copyright (c) Benson I. Margulies, Mike Stephenson, Steve Linhart, 1989. */
/* NetHack may be freely redistributed. See license for details. */
@@ -2222,13 +2222,21 @@ register int x, y;
{
aligntyp altaralign = a_align(x, y);
if (!strcmp(align_gname(altaralign), u_gname())) {
if (u.ualign.type == altaralign && u.ualign.record > -rn2(4)) {
godvoice(altaralign, "How darest thou desecrate my altar!");
(void) adjattrib(A_WIS, -1, FALSE);
u.ualign.record--;
} else {
pline("A voice (could it be %s?) whispers:", align_gname(altaralign));
pline("%s %s%s:",
!Deaf ? "A voice (could it be"
: "Despite your deafness, you seem to hear",
align_gname(altaralign),
!Deaf ? "?) whispers" : " say");
verbalize("Thou shalt pay, infidel!");
change_luck(-1);
/* higher luck is more likely to be reduced; as it approaches -5
the chance to lose another point drops down, eventually to 0 */
if (Luck > -5 && rn2(Luck + 6))
change_luck(rn2(20) ? -1 : -2);
}
}