v2.1.0: fixed speedy stealth +1 requiring existing momentum

This commit is contained in:
Evan Debenham
2023-04-21 13:58:39 -04:00
parent 0236abb505
commit c68210e1f4

View File

@@ -70,7 +70,8 @@ public class Momentum extends Buff implements ActionIndicator.Action {
if (freerunCooldown == 0 && !freerunning() && target.invisible > 0 && Dungeon.hero.pointsInTalent(Talent.SPEEDY_STEALTH) >= 1){
momentumStacks = Math.min(momentumStacks + 2, 10);
movedLastTurn = true;
ActionIndicator.refresh();
ActionIndicator.setAction(this);
BuffIndicator.refreshHero();
}
if (freerunTurns > 0){
@@ -81,7 +82,7 @@ public class Momentum extends Buff implements ActionIndicator.Action {
momentumStacks = (int)GameMath.gate(0, momentumStacks-1, Math.round(momentumStacks * 0.667f));
if (momentumStacks <= 0) {
ActionIndicator.clearAction(this);
if (freerunCooldown <= 0) detach();
BuffIndicator.refreshHero();
} else {
ActionIndicator.refresh();
}
@@ -98,6 +99,7 @@ public class Momentum extends Buff implements ActionIndicator.Action {
postpone(target.cooldown()+(1/target.speed()));
momentumStacks = Math.min(momentumStacks + 1, 10);
ActionIndicator.setAction(this);
BuffIndicator.refreshHero();
}
}
@@ -125,7 +127,8 @@ public class Momentum extends Buff implements ActionIndicator.Action {
@Override
public int icon() {
return BuffIndicator.MOMENTUM;
if (momentumStacks > 0 || freerunCooldown > 0) return BuffIndicator.MOMENTUM;
else return BuffIndicator.NONE;
}
@Override