v0.2.4: made potions susceptible to cold, refactored a bit of buff logic.

This commit is contained in:
Evan Debenham
2015-02-10 02:09:57 -05:00
parent ae2ba8be0e
commit 72975a49cc
9 changed files with 101 additions and 61 deletions
@@ -218,10 +218,12 @@ public class Potion extends Item {
shatter( hero.pos );
}
protected void shatter( int cell ) {
GLog.i( "The flask shatters and " + color() + " liquid splashes harmlessly" );
Sample.INSTANCE.play( Assets.SND_SHATTER );
splash( cell );
public void shatter( int cell ) {
if (Dungeon.visible[cell]) {
GLog.i( "The flask shatters and " + color() + " liquid splashes harmlessly" );
Sample.INSTANCE.play( Assets.SND_SHATTER );
splash( cell );
}
}
@Override