From 0c20fdeccb5115797634da3119df5adf5f08c7ed Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Thu, 3 Feb 2022 01:05:25 +0100 Subject: [PATCH] Stunning from the Orb of Chaos now destroys birds/shadows just like the other sources of stunning --- pcmove.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/pcmove.cpp b/pcmove.cpp index 4a61912c..a2a69d71 100644 --- a/pcmove.cpp +++ b/pcmove.cpp @@ -576,6 +576,9 @@ void apply_chaos() { if (cb->wall == waStone) destroyTrapsAround(cb); changes.ccell(ca); changes.ccell(cb); + /* needs to be called separately for Shadows */ + if(ca->monst == moShadow) checkStunKill(ca); + if(cb->monst == moShadow) checkStunKill(cb); gcell coa = *ca; gcell cob = *cb; if(ca->monst != cb->monst) @@ -588,10 +591,14 @@ void apply_chaos() { copy_metadata(cb, &coa); if(!switch_lhu_in(ca->land)) ca->LHU = coa.LHU; if(!switch_lhu_in(cb->land)) cb->LHU = cob.LHU; - if(ca->monst && !(isFriendly(ca) && markOrb(itOrbEmpathy))) + if(ca->monst && !(isFriendly(ca) && markOrb(itOrbEmpathy))) { ca->stuntime = min(ca->stuntime + 3, 15), markOrb(itOrbChaos); - if(cb->monst && !(isFriendly(cb) && markOrb(itOrbEmpathy))) + checkStunKill(ca); + } + if(cb->monst && !(isFriendly(cb) && markOrb(itOrbEmpathy))) { cb->stuntime = min(cb->stuntime + 3, 15), markOrb(itOrbChaos); + checkStunKill(cb); + } ca->monmirror = !ca->monmirror; cb->monmirror = !cb->monmirror; ca->mondir = chaos_mirror_dir(ca->mondir, wb, wa);