/* Flags to control dotrap() in trap.c */
#define NOWEBMSG 0x01 /* suppress stumble into web message */
+#define FORCEBUNGLE 0x02 /* adjustments appropriate for bungling */
/* Flags to control test_move in hack.c */
#define DO_MOVE 0 /* really doing the move */
You("finish arming %s.",
the(defsyms[trap_to_defsym(what_trap(ttyp))].explanation));
if (((otmp->cursed || Fumbling) && (rnl(10) > 5)) || trapinfo.force_bungle)
- dotrap(ttmp, 0);
+ dotrap(ttmp, trapinfo.force_bungle ? FORCEBUNGLE : 0);
} else {
/* this shouldn't happen */
Your("trap setting attempt fails.");
register struct obj *otmp;
boolean already_seen = trap->tseen;
boolean webmsgok = (!(trflags & NOWEBMSG));
-
+ boolean forcebungle = (trflags & FORCEBUNGLE);
+
nomul(0);
/* KMH -- You can't escape the Sokoban level traps */
defsyms[trap_to_defsym(ttype)].explanation);
return;
}
- if(!Fumbling && ttype != MAGIC_PORTAL && ttype != ANTI_MAGIC &&
+ if(!Fumbling && ttype != MAGIC_PORTAL &&
+ ttype != ANTI_MAGIC && !forcebungle &&
(!rn2(5) ||
((ttype == PIT || ttype == SPIKED_PIT) && is_clinger(youmonst.data)))) {
You("escape %s %s.",
trap->madeby_u ? "the trigger of your mine" :
"a trigger");
if (already_seen && rn2(3)) break;
- pline("KAABLAMM!!! The air currents set %s%s off!",
+ pline("KAABLAMM!!! %s %s%s off!",
+ forcebungle ? "Your inept attempt sets" :
+ "The air currents set",
already_seen ? a_your[trap->madeby_u] : "",
already_seen ? " land mine" : "it");
} else {