broken wand of striking vs door (trunk only)

<email deleted> wrote:
> * Doors absorb the blast of a broken wand of striking. What's more, the message
> reads "The door absorbs your bolt!" rather than "blast".

passes wand type to explode() as a negative value for the case
where the wand type isn't mapped to an AD_* explosion type.

Then explode() converts it to a positive and passes it to zap_over_floor().
This commit is contained in:
nethack.allison
2006-03-07 03:10:58 +00:00
parent 3e8725ed95
commit 71ed473cf6
5 changed files with 25 additions and 7 deletions

View File

@@ -2821,7 +2821,7 @@ do_break_wand(obj)
}
/* magical explosion and its visual effect occur before specific effects */
explode(obj->ox, obj->oy, 0, rnd(dmg), WAND_CLASS, EXPL_MAGICAL);
explode(obj->ox, obj->oy, -(obj->otyp), rnd(dmg), WAND_CLASS, EXPL_MAGICAL);
/* this makes it hit us last, so that we can see the action first */
for (i = 0; i <= 8; i++) {