v0.9.2: implemented the enhanced combo talent

This commit is contained in:
Evan Debenham 2021-02-13 15:59:42 -05:00
parent c1dd816a36
commit 35e894ab54
4 changed files with 48 additions and 8 deletions

View File

@ -346,6 +346,8 @@ actors.hero.talent.cleave.title=cleave
actors.hero.talent.cleave.desc=_+1:_ When the Gladiator kills an enemy, the combo cooldown for his next hit is increased to _10 turns_.\n\n_+2:_ When the Gladiator kills an enemy, the combo cooldown for his next hit is increased to _20 turns_.\n\n_+3:_ When the Gladiator kills an enemy, the combo cooldown for his next hit is increased to _30 turns_. actors.hero.talent.cleave.desc=_+1:_ When the Gladiator kills an enemy, the combo cooldown for his next hit is increased to _10 turns_.\n\n_+2:_ When the Gladiator kills an enemy, the combo cooldown for his next hit is increased to _20 turns_.\n\n_+3:_ When the Gladiator kills an enemy, the combo cooldown for his next hit is increased to _30 turns_.
actors.hero.talent.lethal_defense.title=lethal defense actors.hero.talent.lethal_defense.title=lethal defense
actors.hero.talent.lethal_defense.desc=_+1:_ When the Gladiator kills an enemy with a combo move, he _regains 33%_ of the broken seal's shielding.\n\n_+1:_ When the Gladiator kills an enemy with a combo move, he _regains 67%_ of the broken seal's shielding.\n\n_+1:_ When the Gladiator kills an enemy with a combo move, he _regains 100%_ of the broken seal's shielding. actors.hero.talent.lethal_defense.desc=_+1:_ When the Gladiator kills an enemy with a combo move, he _regains 33%_ of the broken seal's shielding.\n\n_+1:_ When the Gladiator kills an enemy with a combo move, he _regains 67%_ of the broken seal's shielding.\n\n_+1:_ When the Gladiator kills an enemy with a combo move, he _regains 100%_ of the broken seal's shielding.
actors.hero.talent.enhanced_combo.title=enhanced combo
actors.hero.talent.enhanced_combo.desc=_+1:_ When the Gladiator's combo is 7 or higher, Clobber's knockback range increases to 3, it inflicts vertigo, and it can knock enemies into pits.\n\n_+2:_ In addition to the benefits of +1, when the Gladiator's combo is 9 or higher parry works on multiple attacks.\n\n_+3:_ In addition to the benefits of +1 and +2, the Gladiator can leap up to combo/3 tiles when using Slam, Crush, or Fury.
actors.hero.talent.empowering_meal.title=empowering meal actors.hero.talent.empowering_meal.title=empowering meal
actors.hero.talent.empowering_meal.desc=_+1:_ Eating food grants the Mage _2 bonus damage_ on his next 3 wand zaps.\n\n_+2:_ Eating food grants the Mage _3 bonus damage_ on his next 3 wand zaps. actors.hero.talent.empowering_meal.desc=_+1:_ Eating food grants the Mage _2 bonus damage_ on his next 3 wand zaps.\n\n_+2:_ Eating food grants the Mage _3 bonus damage_ on his next 3 wand zaps.

View File

@ -203,6 +203,10 @@ public class Combo extends Buff implements ActionIndicator.Action {
return best; return best;
} }
public int getComboCount(){
return count;
}
public boolean canUseMove(ComboMove move){ public boolean canUseMove(ComboMove move){
if (move == ComboMove.CLOBBER && clobberUsed) return false; if (move == ComboMove.CLOBBER && clobberUsed) return false;
if (move == ComboMove.PARRY && parryUsed) return false; if (move == ComboMove.PARRY && parryUsed) return false;
@ -309,8 +313,13 @@ public class Combo extends Buff implements ActionIndicator.Action {
trajectory = new Ballistica(trajectory.collisionPos, trajectory.path.get(trajectory.path.size() - 1), Ballistica.PROJECTILE); trajectory = new Ballistica(trajectory.collisionPos, trajectory.path.get(trajectory.path.size() - 1), Ballistica.PROJECTILE);
//knock them back along that ballistica, ensuring they don't fall into a pit //knock them back along that ballistica, ensuring they don't fall into a pit
int dist = 2; int dist = 2;
while (dist > 0 && Dungeon.level.pit[trajectory.path.get(dist)]){ if (count >= 7 && hero.pointsInTalent(Talent.ENHANCED_COMBO) >= 1){
dist--; dist ++;
Buff.prolong(enemy, Vertigo.class, 3);
} else {
while (dist > 0 && Dungeon.level.pit[trajectory.path.get(dist)]) {
dist--;
}
} }
WandOfBlastWave.throwChar(enemy, trajectory, dist, true, false); WandOfBlastWave.throwChar(enemy, trajectory, dist, true, false);
} }
@ -414,9 +423,36 @@ public class Combo extends Buff implements ActionIndicator.Action {
final Char enemy = Actor.findChar( cell ); final Char enemy = Actor.findChar( cell );
if (enemy == null if (enemy == null
|| !Dungeon.level.heroFOV[cell] || !Dungeon.level.heroFOV[cell]
|| !((Hero)target).canAttack(enemy) || target.isCharmedBy( enemy )) {
|| target.isCharmedBy( enemy )){ GLog.w(Messages.get(Combo.class, "bad_target"));
GLog.w( Messages.get(Combo.class, "bad_target") );
} else if (!((Hero)target).canAttack(enemy)){
if (((Hero) target).pointsInTalent(Talent.ENHANCED_COMBO) < 3
|| Dungeon.level.distance(target.pos, enemy.pos) > 1 + target.buff(Combo.class).count/3){
GLog.w(Messages.get(Combo.class, "bad_target"));
} else {
Ballistica c = new Ballistica(target.pos, enemy.pos, Ballistica.PROJECTILE);
if (c.collisionPos == enemy.pos){
target.sprite.jump(target.pos, c.path.get(c.dist-1), new Callback() {
@Override
public void call() {
target.move(c.path.get(c.dist-1));
Dungeon.level.occupyCell(target);
Dungeon.observe();
GameScene.updateFog();
target.sprite.attack(cell, new Callback() {
@Override
public void call() {
doAttack(enemy);
}
});
}
});
} else {
GLog.w(Messages.get(Combo.class, "bad_target"));
}
}
} else { } else {
target.sprite.attack(cell, new Callback() { target.sprite.attack(cell, new Callback() {
@Override @Override

View File

@ -440,7 +440,9 @@ public class Hero extends Char {
return super.defenseVerb(); return super.defenseVerb();
} else { } else {
parry.parried = true; parry.parried = true;
parry.detach(); if (buff(Combo.class).getComboCount() < 9 || pointsInTalent(Talent.ENHANCED_COMBO) < 2){
parry.detach();
}
return Messages.get(Monk.class, "parried"); return Messages.get(Monk.class, "parried");
} }
} }

View File

@ -75,7 +75,7 @@ public enum Talent {
//Berserker T3 //Berserker T3
ENDLESS_RAGE(11, 3), BERSERKING_STAMINA(12, 3), ENRAGED_CATALYST(13, 3), ENDLESS_RAGE(11, 3), BERSERKING_STAMINA(12, 3), ENRAGED_CATALYST(13, 3),
//Gladiator T3 //Gladiator T3
CLEAVE(14, 3), LETHAL_DEFENSE(15, 3), GLADIATOR_T3_3(16, 3), CLEAVE(14, 3), LETHAL_DEFENSE(15, 3), ENHANCED_COMBO(16, 3),
//Mage T1 //Mage T1
EMPOWERING_MEAL(32), SCHOLARS_INTUITION(33), TESTED_HYPOTHESIS(34), BACKUP_BARRIER(35), EMPOWERING_MEAL(32), SCHOLARS_INTUITION(33), TESTED_HYPOTHESIS(34), BACKUP_BARRIER(35),
@ -468,7 +468,7 @@ public enum Talent {
Collections.addAll(tierTalents, ENDLESS_RAGE, BERSERKING_STAMINA, ENRAGED_CATALYST); Collections.addAll(tierTalents, ENDLESS_RAGE, BERSERKING_STAMINA, ENRAGED_CATALYST);
break; break;
case GLADIATOR: case GLADIATOR:
Collections.addAll(tierTalents, CLEAVE, LETHAL_DEFENSE, GLADIATOR_T3_3); Collections.addAll(tierTalents, CLEAVE, LETHAL_DEFENSE, ENHANCED_COMBO);
break; break;
case BATTLEMAGE: case BATTLEMAGE:
Collections.addAll(tierTalents, EMPOWERED_STRIKE, MYSTICAL_CHARGE, BATTLEMAGE_T3_3); Collections.addAll(tierTalents, EMPOWERED_STRIKE, MYSTICAL_CHARGE, BATTLEMAGE_T3_3);