v0.3.4: reworked rankings to store their cause instead of a result string

This commit is contained in:
Evan Debenham
2016-01-23 02:12:18 -05:00
committed by Evan Debenham
parent 0e2fbc05fb
commit ac967fad27
36 changed files with 79 additions and 65 deletions
@@ -250,7 +250,7 @@ public class CursedWand {
target.sprite.emitter().burst(Speck.factory(Speck.HEALING), 3);
Sample.INSTANCE.play(Assets.SND_CURSED);
if (!user.isAlive()) {
Dungeon.fail(Utils.format(ResultDescriptions.ITEM, wand.name()));
Dungeon.fail( wand.getClass() );
GLog.n(Messages.get(CursedWand.class, "ondeath", wand.name()));
}
break;
@@ -100,7 +100,7 @@ public class WandOfBlastWave extends Wand {
}
if (!curUser.isAlive()) {
Dungeon.fail( Utils.format(ResultDescriptions.ITEM, name) );
Dungeon.fail( getClass() );
GLog.n( Messages.get( this, "ondeath") );
}
}
@@ -73,7 +73,7 @@ public class WandOfLightning extends Wand {
}
if (!curUser.isAlive()) {
Dungeon.fail( Utils.format( ResultDescriptions.ITEM, name ) );
Dungeon.fail( getClass() );
GLog.n(Messages.get(this, "ondeath"));
}
}
@@ -173,7 +173,6 @@ public class WandOfTransfusion extends Wand {
}
}
//this wand costs health too
private void damageHero(){
// 15% of max hp
@@ -181,7 +180,7 @@ public class WandOfTransfusion extends Wand {
curUser.damage(damage, this);
if (!curUser.isAlive()){
Dungeon.fail( Utils.format(ResultDescriptions.ITEM, name) );
Dungeon.fail( getClass() );
GLog.n( Messages.get(this, "ondeath") );
}
}