kicker kicking

Reported in Dec'04 by <email deleted>, an
unpoly'd hero or a hero poly'd into monster form which lacks a kick
attack both get bonus from rings of increase damage when kicking, but
a hero poly'd into monster form which has a kick attack did not.
This commit is contained in:
nethack.rankin
2007-04-16 03:03:08 +00:00
parent 9c593b6d14
commit 18a467617b
2 changed files with 13 additions and 1 deletions

View File

@@ -1,4 +1,4 @@
/* SCCS Id: @(#)uhitm.c 3.5 2006/12/02 */
/* SCCS Id: @(#)uhitm.c 3.5 2007/04/13 */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/* NetHack may be freely redistributed. See license for details. */
@@ -1369,6 +1369,16 @@ register struct attack *mattk;
} else
tmp = rnd(4); /* bless damage */
}
/* add ring(s) of increase damage */
if (u.udaminc > 0) {
/* applies even if damage was 0 */
tmp += u.udaminc;
} else if (tmp > 0) {
/* ring(s) might be negative; avoid converting
0 to non-0 or positive to non-positive */
tmp += u.udaminc;
if (tmp < 1) tmp = 1;
}
}
break;
case AD_FIRE: