From: Pasi Kallinen Date: Sat, 4 Mar 2023 09:02:06 +0000 (+0200) Subject: Untrap tip X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=10df3882453426615abaab1ea8933ae54504b30a;p=nethack Untrap tip --- diff --git a/include/context.h b/include/context.h index 662165dda..382a607aa 100644 --- a/include/context.h +++ b/include/context.h @@ -14,6 +14,7 @@ enum nh_tips { TIP_ENHANCE = 0, /* #enhance */ TIP_SWIM, /* walking into water */ + TIP_UNTRAP_MON, /* walking into trapped peaceful */ TIP_GETPOS, /* getpos/farlook */ NUM_TIPS diff --git a/include/patchlevel.h b/include/patchlevel.h index 05d9cc8dd..b2635426d 100644 --- a/include/patchlevel.h +++ b/include/patchlevel.h @@ -17,7 +17,7 @@ * Incrementing EDITLEVEL can be used to force invalidation of old bones * and save files. */ -#define EDITLEVEL 76 +#define EDITLEVEL 77 /* * Development status possibilities. diff --git a/src/hack.c b/src/hack.c index 60cf2fc72..f96a41424 100644 --- a/src/hack.c +++ b/src/hack.c @@ -1658,6 +1658,9 @@ handle_tip(int tip) pline("(Use '%s' prefix to step in if you really want to.)", visctrl(cmd_from_func(do_reqmenu))); break; + case TIP_UNTRAP_MON: + pline("(Perhaps #untrap would help?)"); + break; case TIP_GETPOS: l_nhcore_call(NHCORE_GETPOS_TIP); break; @@ -1871,6 +1874,7 @@ domove_swap_with_pet(struct monst *mtmp, coordxy x, coordxy y) /* all mtame are also mpeaceful, so this affects pets too */ You("stop. %s can't move out of that trap.", upstart(y_monnam(mtmp))); + handle_tip(TIP_UNTRAP_MON); didnt_move = TRUE; } else if (mtmp->mpeaceful && (!goodpos(u.ux0, u.uy0, mtmp, 0)