From 8678a2f77f14685ff08bd4b60041a475cd448e6d Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Sat, 22 May 2021 01:22:03 +0200 Subject: [PATCH] Curse of Weakness allows to push stunned monsters as originally designed --- attack.cpp | 3 +-- pcmove.cpp | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/attack.cpp b/attack.cpp index 9e3ae1cb..879188b9 100644 --- a/attack.cpp +++ b/attack.cpp @@ -1045,8 +1045,7 @@ EX void killFriendlyIvy() { } EX bool monsterPushable(cell *c2) { - if(markOrb(itCurseWeakness) && attackJustStuns(c2, 0, moPlayer)) - return false; + if(markOrb(itCurseWeakness) && (c2->stuntime < 2 || attackJustStuns(c2, 0, moPlayer))) return false; return (c2->monst != moFatGuard && !(isMetalBeast(c2->monst) && c2->stuntime < 2) && c2->monst != moTortoise && c2->monst != moTerraWarrior && c2->monst != moVizier && c2->monst != moWorldTurtle); } diff --git a/pcmove.cpp b/pcmove.cpp index 223fa9e4..660811b3 100644 --- a/pcmove.cpp +++ b/pcmove.cpp @@ -926,7 +926,7 @@ bool pcmove::attack() { mip = movei(c2, nullptr, NO_SPACE); - if(isStunnable(c2->monst) && c2->hitpoints > 1) { + if(items[itCurseWeakness] || (isStunnable(c2->monst) && c2->hitpoints > 1)) { if(monsterPushable(c2)) mip = determinePush(cwt, subdir, [c2] (cell *c) { return passable(c, c2, P_BLOW); }); else