Fuzzer randomly teleports between dungeon branches
Previously the fuzzer usually stayed in the Dungeons of Doom, only very rarely going to other dungeon branches. Now, it will randomly choose a dungeon branch and a level in that branch to level teleport to.
This commit is contained in:
+10
-2
@@ -859,8 +859,16 @@ level_tele(void)
|
|||||||
char buf[BUFSZ];
|
char buf[BUFSZ];
|
||||||
boolean force_dest = FALSE;
|
boolean force_dest = FALSE;
|
||||||
|
|
||||||
if (iflags.debug_fuzzer)
|
if (iflags.debug_fuzzer) {
|
||||||
goto random_levtport;
|
do {
|
||||||
|
newlevel.dnum = rn2(gn.n_dgns);
|
||||||
|
} while (newlevel.dnum == astral_level.dnum
|
||||||
|
|| gd.dungeons[newlevel.dnum].flags.unconnected
|
||||||
|
|| !gd.dungeons[newlevel.dnum].num_dunlevs);
|
||||||
|
newlevel.dlevel = 1 + rn2(dunlevs_in_dungeon(&newlevel));
|
||||||
|
schedule_goto(&newlevel, UTOTYPE_NONE, (char *) 0, (char *) 0);
|
||||||
|
return;
|
||||||
|
}
|
||||||
if ((u.uhave.amulet || In_endgame(&u.uz) || In_sokoban(&u.uz))
|
if ((u.uhave.amulet || In_endgame(&u.uz) || In_sokoban(&u.uz))
|
||||||
&& !wizard) {
|
&& !wizard) {
|
||||||
You_feel("very disoriented for a moment.");
|
You_feel("very disoriented for a moment.");
|
||||||
|
|||||||
Reference in New Issue
Block a user