v0.2.3: further hourglass implementation

This commit is contained in:
Evan Debenham
2014-12-05 17:11:10 -05:00
parent 3d55729861
commit 15c4bd66b7
3 changed files with 80 additions and 14 deletions
@@ -898,7 +898,10 @@ public class Hero extends Char {
}
@Override
public void damage( int dmg, Object src ) {
public void damage( int dmg, Object src ) {
if (buff(TimekeepersHourglass.timeStasis.class) != null)
return;
restoreHealth = false;
if (!(src instanceof Hunger) && damageInterrupt)
@@ -1123,6 +1126,10 @@ public class Hero extends Char {
@Override
public void add( Buff buff ) {
//TODO: test this, may break some things
if (buff(TimekeepersHourglass.timeStasis.class) != null)
return;
super.add( buff );
if (sprite != null) {