cleanup when exiting tutorial

When returning to play from within the tutorial, remove the level files
similar to how they're discarded for the rest of the dungeon when going
into the endgame.  It turned out to be a bit messier than anticipated.

The dungeon.c bit is sufficient for #overview, which now hides regular
level 1 while in the tutorial and hides all tutorial levels once exited.
Those will still appear in end-of-game disclosure.
This commit is contained in:
PatR
2023-07-17 14:27:28 -07:00
parent 536a4bd8b3
commit 8d60b92407
6 changed files with 39 additions and 15 deletions

View File

@@ -1,4 +1,4 @@
/* NetHack 3.7 save.c $NHDT-Date: 1686726259 2023/06/14 07:04:19 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.206 $ */
/* NetHack 3.7 save.c $NHDT-Date: 1689629246 2023/07/17 21:27:26 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.207 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Michael Allison, 2009. */
/* NetHack may be freely redistributed. See license for details. */
@@ -1142,7 +1142,7 @@ free_dungeons(void)
tnhfp.mode = FREEING;
savelevchn(&tnhfp);
save_dungeon(&tnhfp, FALSE, TRUE);
free_luathemes(TRUE);
free_luathemes(all_themes);
#endif
return;
}