v2.1.0: fixed magical misses not interrupting the hero
This commit is contained in:
@@ -324,10 +324,6 @@ public abstract class Char extends Actor {
|
||||
|
||||
boolean visibleFight = Dungeon.level.heroFOV[pos] || Dungeon.level.heroFOV[enemy.pos];
|
||||
|
||||
if (enemy == Dungeon.hero && Dungeon.hero.damageInterrupt){
|
||||
Dungeon.hero.interrupt();
|
||||
}
|
||||
|
||||
if (enemy.isInvulnerable(getClass())) {
|
||||
|
||||
if (visibleFight) {
|
||||
@@ -521,6 +517,10 @@ public abstract class Char extends Actor {
|
||||
float acuStat = attacker.attackSkill( defender );
|
||||
float defStat = defender.defenseSkill( attacker );
|
||||
|
||||
if (defender instanceof Hero && ((Hero) defender).damageInterrupt){
|
||||
((Hero) defender).interrupt();
|
||||
}
|
||||
|
||||
//invisible chars always hit (for the hero this is surprise attacking)
|
||||
if (attacker.invisible > 0 && attacker.canSurpriseAttack()){
|
||||
acuStat = INFINITE_ACCURACY;
|
||||
|
||||
Reference in New Issue
Block a user