v0.2.3: artifacts can now be cursed (couple rough edges to smooth out)

This commit is contained in:
Evan Debenham
2014-11-19 01:36:36 -05:00
parent 268435d390
commit 0ba2ca4302
12 changed files with 143 additions and 66 deletions
@@ -28,12 +28,13 @@ public class Regeneration extends Buff {
@Override
public boolean act() {
if (target.isAlive()) {
if (target.HP < target.HT && !((Hero)target).isStarving()) {
ChaliceOfBlood.chaliceRegen regenBuff = Dungeon.hero.buff( ChaliceOfBlood.chaliceRegen.class);
if (target.HP < target.HT && !((Hero)target).isStarving() && !(regenBuff != null && regenBuff.isCursed())) {
target.HP += 1;
}
ChaliceOfBlood.chaliceRegen regenBuff = Dungeon.hero.buff( ChaliceOfBlood.chaliceRegen.class);
if (regenBuff != null)
spend( Math.max(REGENERATION_DELAY - regenBuff.level(), 0.5f) );
else