From: PatR Date: Wed, 25 May 2022 19:38:07 +0000 (-0700) Subject: github pull request #772 - displaying new glob X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e7923bafe9d2a4514f7340d7ce3b34f0c0a8d56b;p=nethack github pull request #772 - displaying new glob If a monster killed a pudding, the resulting glob was dropped on the map but might now be shown depending upon interaction--or lack of such--with nearby globs. The commit also changed the indentation of a label; I've reversed that. Having labels always be indented one space means there's no need to look into nested blocks to find them. But having no indentation at all interferes with GNU diff (which is used for git diff) showing the function that a band of changes occurs in (done by augmenting the change bars in front of the band). That is based on the most recent preceding line having a letter in the leftmost column. Back when we had K&R-style function definitions which didn't indent their arguments, that diff feature wasn't useful. But after switching to ANSI-style definitions it is--except when an unindented label interferes. --- diff --git a/doc/fixes3-7-0.txt b/doc/fixes3-7-0.txt index ce2f635eb..9f885d4cb 100644 --- a/doc/fixes3-7-0.txt +++ b/doc/fixes3-7-0.txt @@ -909,6 +909,8 @@ fix a pair of off-by-one bugs when doling out initial characteristics points, effect across a large set of games using a marker to write "novel" or "paperback book" on a known blank spellbook was producing a randomly chosen Pratchett novel; make it fail instead +when a monster killed a pudding and it left a glob, that glob might not be + displayed on the map (wasn't an issue for killed-by-hero case) Fixes to 3.7.0-x Problems that Were Exposed Via git Repository diff --git a/src/mon.c b/src/mon.c index 1ebb84964..4f53b0c50 100644 --- a/src/mon.c +++ b/src/mon.c @@ -654,7 +654,7 @@ make_corpse(struct monst *mtmp, unsigned int corpseflags) newsym(x, y); return obj; default: -default_1: + default_1: if (g.mvitals[mndx].mvflags & G_NOCORPSE) { return (struct obj *) 0; } else {