mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-29 19:40:35 +00:00
Orb of Air now kills Red Raiders if separating them, instead of crashing
This commit is contained in:
parent
f34205ca6b
commit
ae65a1dd5f
19
attack.cpp
19
attack.cpp
@ -1005,7 +1005,24 @@ EX bool attackMonster(cell *c, flagtype flags, eMonster killer) {
|
||||
}
|
||||
|
||||
EX void pushMonster(const movei& mi) {
|
||||
moveMonster(mi);
|
||||
if(mi.s->monst == moPair || isMagneticPole(mi.s)) {
|
||||
cell *other = mi.s->move(mi.s->mondir);
|
||||
int id = neighborId(mi.t, other);
|
||||
if(id == -1) {
|
||||
killMonster(mi.s, moPlayer);
|
||||
killMonster(other, moPlayer);
|
||||
return;
|
||||
}
|
||||
else {
|
||||
moveMonster(mi);
|
||||
if(mi.t->monst) {
|
||||
mi.t->mondir = id;
|
||||
other->mondir = mi.t->c.spin(id);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
moveMonster(mi);
|
||||
auto& cf = mi.s;
|
||||
auto& ct = mi.t;
|
||||
if(ct->monst == moBrownBug) {
|
||||
|
Loading…
Reference in New Issue
Block a user