Large monster can knock back smaller ones
When a monster at least two sizes larger hits another one, there's a chance the smaller defender will be knocked back. This applies also to hero, attacking when polymorphed to a large monster, or defending from a large monster. Most of the monsters that can knock back are giants and dragons. Idea and some of the code from EvilHack.
This commit is contained in:
@@ -1032,6 +1032,9 @@ hitmu(register struct monst *mtmp, register struct attack *mattk)
|
||||
mhm.damage += d((int) mattk->damn, (int) mattk->damd); /* extra dmg */
|
||||
|
||||
mhitm_adtyping(mtmp, mattk, &g.youmonst, &mhm);
|
||||
|
||||
(void) mhitm_knockback(mtmp, &g.youmonst, mattk, &mhm.hitflags, (MON_WEP(mtmp) != 0));
|
||||
|
||||
if (mhm.done)
|
||||
return mhm.hitflags;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user