fix github issue #687 - logging of major events
Reported by k21971, the dumplog section labeled "major events" showed all logged events rather than just the ones classified as major. Filter out the non-major ones when writing dumplog. At the moment only a couple of ones other than achievements are major. Probably various other types should be too. The #chronicle command still lists all logged events unless they're flagged as 'spoiler'. So far the mines' end luckstone is the only one flagged that way. Unfortunately a player with access to live logging could still learn whether or not the gray stone that has just been picked up on the last mines level is the target luckstone by viewing the log from outside of the game. The #chronicle command would be more useful if it gathered all the categories of events present and put up a menu allowing the player to choose which ones to view. I haven't attempted to implement that. Closes #687
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.7 allmain.c $NHDT-Date: 1645223894 2022/02/18 22:38:14 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.177 $ */
|
||||
/* NetHack 3.7 allmain.c $NHDT-Date: 1646136934 2022/03/01 12:15:34 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.178 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/*-Copyright (c) Robert Patrick Rankin, 2012. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -761,8 +761,8 @@ welcome(boolean new_game) /* false => restoring an old game */
|
||||
Hello((struct monst *) 0), g.plname, buf);
|
||||
|
||||
l_nhcore_call(new_game ? NHCORE_START_NEW_GAME : NHCORE_RESTORE_OLD_GAME);
|
||||
if (new_game)
|
||||
livelog_printf(LL_MINORAC, "%s the%s entered the dungeon",
|
||||
if (new_game) /* guarantee that 'major' event category is never empty */
|
||||
livelog_printf(LL_ACHIEVE, "%s the%s entered the dungeon",
|
||||
g.plname, buf);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user