From 20b59a372d3e2c98a52f658653c2efbcfc9f29e9 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Mon, 8 Sep 2014 01:12:36 -0400 Subject: [PATCH] V0.2.0: ...further corrected Chalice Logic & artifact logic --- .../shatteredpixeldungeon/items/artifacts/Artifact.java | 2 ++ .../shatteredpixeldungeon/items/artifacts/ChaliceOfBlood.java | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java index 62b0b5c86..01c4609d6 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/Artifact.java @@ -167,6 +167,7 @@ public class Artifact extends KindofMisc { @Override public void storeInBundle( Bundle bundle ) { + super.storeInBundle(bundle); bundle.put( "exp", exp ); bundle.put( "charge", charge ); bundle.put( "partialcharge", partialCharge); @@ -174,6 +175,7 @@ public class Artifact extends KindofMisc { @Override public void restoreFromBundle( Bundle bundle ) { + super.restoreFromBundle(bundle); exp = bundle.getInt("exp"); charge = bundle.getInt("charge"); partialCharge = bundle.getFloat("partialcharge"); diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/ChaliceOfBlood.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/ChaliceOfBlood.java index 0357ef660..fc9938775 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/ChaliceOfBlood.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/ChaliceOfBlood.java @@ -89,7 +89,6 @@ public class ChaliceOfBlood extends Artifact { //TODO: make sure this look good if (damage <= 0){ GLog.i("You prick yourself, that hardly hurt at all!"); - return; } else if (damage < 25){ GLog.w("You prick yourself and the chalice feeds on you."); Sample.INSTANCE.play(Assets.SND_CURSED); @@ -104,7 +103,8 @@ public class ChaliceOfBlood extends Artifact { hero.sprite.emitter().burst( ShadowParticle.CURSE, 6 ); } - hero.damage(damage, this); + if (damage > 0) + hero.damage(damage, this);