1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-06-07 17:04:06 +00:00

Stunning from the Orb of Chaos now destroys birds/shadows just like the other sources of stunning

This commit is contained in:
Zeno Rogue 2022-02-03 01:05:25 +01:00
parent ee246d4a93
commit 0c20fdeccb

View File

@ -576,6 +576,9 @@ void apply_chaos() {
if (cb->wall == waStone) destroyTrapsAround(cb); if (cb->wall == waStone) destroyTrapsAround(cb);
changes.ccell(ca); changes.ccell(ca);
changes.ccell(cb); 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 coa = *ca;
gcell cob = *cb; gcell cob = *cb;
if(ca->monst != cb->monst) if(ca->monst != cb->monst)
@ -588,10 +591,14 @@ void apply_chaos() {
copy_metadata(cb, &coa); copy_metadata(cb, &coa);
if(!switch_lhu_in(ca->land)) ca->LHU = coa.LHU; if(!switch_lhu_in(ca->land)) ca->LHU = coa.LHU;
if(!switch_lhu_in(cb->land)) cb->LHU = cob.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); 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); cb->stuntime = min(cb->stuntime + 3, 15), markOrb(itOrbChaos);
checkStunKill(cb);
}
ca->monmirror = !ca->monmirror; ca->monmirror = !ca->monmirror;
cb->monmirror = !cb->monmirror; cb->monmirror = !cb->monmirror;
ca->mondir = chaos_mirror_dir(ca->mondir, wb, wa); ca->mondir = chaos_mirror_dir(ca->mondir, wb, wa);