v0.6.1: fixed well of health unintentionally not healing instantly
This commit is contained in:
committed by
Evan Debenham
parent
49b81e0b86
commit
babc3f4dc8
+5
-2
@@ -44,8 +44,11 @@ public class WaterOfHealth extends WellWater {
|
||||
protected boolean affectHero( Hero hero ) {
|
||||
|
||||
Sample.INSTANCE.play( Assets.SND_DRINK );
|
||||
|
||||
PotionOfHealing.heal( hero );
|
||||
|
||||
hero.HP = hero.HT;
|
||||
hero.sprite.emitter().start( Speck.factory( Speck.HEALING ), 0.4f, 4 );
|
||||
|
||||
PotionOfHealing.cure( hero );
|
||||
hero.belongings.uncurseEquipped();
|
||||
((Hunger)hero.buff( Hunger.class )).satisfy( Hunger.STARVING );
|
||||
|
||||
|
||||
+4
-5
@@ -43,14 +43,13 @@ public class PotionOfHealing extends Potion {
|
||||
@Override
|
||||
public void apply( Hero hero ) {
|
||||
setKnown();
|
||||
heal( Dungeon.hero );
|
||||
//starts out healing 30 hp, equalizes with hero health total at level 11
|
||||
Buff.affect( hero, Healing.class ).setHeal((int)(0.8f*hero.HT + 14), 0.333f, 0);
|
||||
cure( hero );
|
||||
GLog.p( Messages.get(this, "heal") );
|
||||
}
|
||||
|
||||
public static void heal( Hero hero ) {
|
||||
|
||||
//starts out healing 30 hp, equalizes with hero health total at level 11
|
||||
Buff.affect( hero, Healing.class ).setHeal((int)(0.8f*hero.HT + 14), 0.333f, 0);
|
||||
public static void cure( Hero hero ) {
|
||||
Buff.detach( hero, Poison.class );
|
||||
Buff.detach( hero, Cripple.class );
|
||||
Buff.detach( hero, Weakness.class );
|
||||
|
||||
Reference in New Issue
Block a user