diff -Nbaur nethack-3.4.3/src/zap.c nethack-cancel-traps/src/zap.c --- nethack-3.4.3/src/zap.c 2003-12-08 10:39:13.000000000 +1100 +++ nethack-cancel-traps/src/zap.c 2005-07-15 19:07:50.000000000 +1000 @@ -2401,6 +2401,29 @@ /* zapping downward */ (void) bhitpile(obj, bhito, x, y); + if (ttmp) { + switch (obj->otyp) { + case WAN_CANCELLATION: + case SPE_CANCELLATION: + /* MRKR: Disarm magical traps (including portals!) */ + /* from an idea posted to rgrn by Haakon Studebaker */ + if (ttmp->ttyp == MAGIC_TRAP || + ttmp->ttyp == TELEP_TRAP || + ttmp->ttyp == LEVEL_TELEP || + ttmp->ttyp == MAGIC_PORTAL || + ttmp->ttyp == POLY_TRAP) { + + if (ttmp->tseen) { + You("disarm a %s.", + defsyms[trap_to_defsym(ttmp->ttyp)].explanation); + } + deltrap(ttmp); + } + break; + default: + break; + } + } /* subset of engraving effects; none sets `disclose' */ if ((e = engr_at(x, y)) != 0 && e->engr_type != HEADSTONE) { switch (obj->otyp) {