From 94c069134dd018de8590aaa6debab384e86a4cad Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Wed, 3 Jun 2015 13:45:16 -0400 Subject: [PATCH] v0.3.0c: the warlock now restores significantly more wand charge from eating food --- .../shatteredpixeldungeon/actors/buffs/Hunger.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Hunger.java b/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Hunger.java index eb682fb0f..51098cc99 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Hunger.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/actors/buffs/Hunger.java @@ -26,6 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.HeroClass; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.HeroSubClass; import com.shatteredpixel.shatteredpixeldungeon.items.artifacts.Artifact; import com.shatteredpixel.shatteredpixeldungeon.items.artifacts.HornOfPlenty; +import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfRecharging; import com.shatteredpixel.shatteredpixeldungeon.ui.BuffIndicator; import com.shatteredpixel.shatteredpixeldungeon.utils.GLog; import com.watabou.utils.Bundle; @@ -48,7 +49,7 @@ public class Hunger extends Buff implements Hero.Doom { @Override public void storeInBundle( Bundle bundle ) { - super.storeInBundle( bundle ); + super.storeInBundle(bundle); bundle.put( LEVEL, level ); } @@ -116,8 +117,10 @@ public class Hunger extends Buff implements Hero.Doom { } public void satisfy( float energy ) { - if (((Hero) target).subClass == HeroSubClass.WARLOCK) + if (((Hero) target).subClass == HeroSubClass.WARLOCK){ + Buff.affect( target, ScrollOfRecharging.Recharging.class, energy/50f); return; + } Artifact.ArtifactBuff buff = target.buff( HornOfPlenty.hornRecharge.class ); if (buff != null && buff.isCursed()){