v0.7.0: bugfixes:
- mirror and prismatic images being able to dodge friendly darts - friendly darts not working on fading prismatic images - prismatic images always healing while a floor is locked
This commit is contained in:
parent
a413691884
commit
405bfeb77c
core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors
|
@ -178,7 +178,7 @@ public abstract class Char extends Actor {
|
|||
|
||||
public boolean attack( Char enemy ) {
|
||||
|
||||
if (enemy == null || !enemy.isAlive()) return false;
|
||||
if (enemy == null) return false;
|
||||
|
||||
boolean visibleFight = Dungeon.level.heroFOV[pos] || Dungeon.level.heroFOV[enemy.pos];
|
||||
|
||||
|
|
|
@ -85,7 +85,8 @@ public class PrismaticGuard extends Buff {
|
|||
spend(TICK);
|
||||
}
|
||||
|
||||
if (HP < maxHP()){
|
||||
LockedFloor lock = target.buff(LockedFloor.class);
|
||||
if (HP < maxHP() && (lock == null || lock.regenOn())){
|
||||
HP += 0.1f;
|
||||
}
|
||||
|
||||
|
|
|
@ -43,7 +43,7 @@ public class MirrorImage extends NPC {
|
|||
spriteClass = MirrorSprite.class;
|
||||
|
||||
HP = HT = 1;
|
||||
defenseSkill = 0;
|
||||
defenseSkill = 1;
|
||||
|
||||
alignment = Alignment.ALLY;
|
||||
state = HUNTING;
|
||||
|
@ -119,7 +119,7 @@ public class MirrorImage extends NPC {
|
|||
int heroEvasion = hero.defenseSkill(enemy);
|
||||
|
||||
//if the hero has more/less evasion, 50% of it is applied
|
||||
return (baseEvasion + heroEvasion) / 2;
|
||||
return super.defenseSkill(enemy) * (baseEvasion + heroEvasion) / 2;
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ public class PrismaticImage extends NPC {
|
|||
spriteClass = PrismaticSprite.class;
|
||||
|
||||
HP = HT = 8;
|
||||
defenseSkill = 0;
|
||||
defenseSkill = 1;
|
||||
|
||||
alignment = Alignment.ALLY;
|
||||
state = HUNTING;
|
||||
|
@ -151,7 +151,7 @@ public class PrismaticImage extends NPC {
|
|||
int heroEvasion = hero.defenseSkill(enemy);
|
||||
|
||||
//if the hero has more/less evasion, 50% of it is applied
|
||||
return (baseEvasion + heroEvasion) / 2;
|
||||
return super.defenseSkill(enemy) * (baseEvasion + heroEvasion) / 2;
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user