v0.3.0: adjusted some logic for pressing tiles, fixing issues where mobs press tiles and reveal traps (e.g. in wand of blast wave)
This commit is contained in:
parent
f1f68163ad
commit
a4facdf950
|
@ -707,8 +707,12 @@ public abstract class Level implements Bundlable {
|
||||||
|
|
||||||
public void press( int cell, Char ch ) {
|
public void press( int cell, Char ch ) {
|
||||||
|
|
||||||
if (pit[cell] && ch == Dungeon.hero) {
|
if (ch != null && pit[cell] && !ch.flying) {
|
||||||
Chasm.heroFall( cell );
|
if (ch == Dungeon.hero) {
|
||||||
|
Chasm.heroFall(cell);
|
||||||
|
} else if (ch instanceof Mob) {
|
||||||
|
Chasm.mobFall( (Mob)ch );
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user