wizard mode level teleport (trunk only)

Responding with '?' to the "what level?" prompt when using ^V in
wizard mode brings up a menu of special level destinations that lets you
move across dungeon branches.  But getting in and out of Fort Ludios
didn't work, and jumping to the endgame forced you to arrive on the Plane
of Earth.  Now Fort Ludios will not be selectable in the menu until after
the portal ordinarily used to reach it has been created (so you'll need a
level between Bigroom and Medusa with a vault on it to be created before
you can bypass the magic portal and jump directly to the Fort), and you
can go directly to any of the elemental planes, including Astral, without
stopping at Earth first (the Wizard will be there to greet you, whichever
level you pick).  Also, this limits the menu to endgame entries once you
are in the endgame.  (Previously, picking a non-endgame level would yield
"you can't get there from here"; you can still get that, if you really
want to see it for some reason, by giving a destination level number
outside the range of -1 to -5 instead of using the menu.)

     I hadn't realized that this feature has been around since 3.4.2 until
I couldn't find any new feature entry for in the current fixes file....
This commit is contained in:
nethack.rankin
2006-03-25 05:16:24 +00:00
parent 8370782a13
commit 5e79d10377
5 changed files with 124 additions and 73 deletions

View File

@@ -1,4 +1,4 @@
/* SCCS Id: @(#)do.c 3.5 2006/02/15 */
/* SCCS Id: @(#)do.c 3.5 2006/03/20 */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/* NetHack may be freely redistributed. See license for details. */
@@ -995,9 +995,11 @@ boolean at_stairs, falling, portal;
if (dunlev(newlevel) > dunlevs_in_dungeon(newlevel))
newlevel->dlevel = dunlevs_in_dungeon(newlevel);
if (newdungeon && In_endgame(newlevel)) { /* 1st Endgame Level !!! */
if (u.uhave.amulet)
assign_level(newlevel, &earth_level);
else return;
if (!u.uhave.amulet) return; /* must have the Amulet */
#ifdef WIZARD
if (!wizard) /* wizard ^V can bypass Earth level */
#endif
assign_level(newlevel, &earth_level); /* (redundant) */
}
new_ledger = ledger_no(newlevel);
if (new_ledger <= 0)