v0.8.0: final tweaks and adjustments:
- it's no longer possible to trigger on-hit effects on invuln enemies - rippers now have a 1 turn delay when summoned by demon spawners
This commit is contained in:
parent
91373fdda1
commit
f24901740d
|
@ -239,7 +239,17 @@ public abstract class Char extends Actor {
|
|||
|
||||
boolean visibleFight = Dungeon.level.heroFOV[pos] || Dungeon.level.heroFOV[enemy.pos];
|
||||
|
||||
if (hit( this, enemy, false )) {
|
||||
if (enemy.isInvulnerable(getClass())) {
|
||||
|
||||
if (visibleFight) {
|
||||
enemy.sprite.showStatus( CharSprite.POSITIVE, Messages.get(this, "invulnerable") );
|
||||
|
||||
Sample.INSTANCE.play(Assets.SND_MISS);
|
||||
}
|
||||
|
||||
return false;
|
||||
|
||||
} else if (hit( this, enemy, false )) {
|
||||
|
||||
int dr = enemy.drRoll();
|
||||
|
||||
|
|
|
@ -74,8 +74,7 @@ public class Combo extends Buff implements ActionIndicator.Action {
|
|||
|
||||
public void hit( Char enemy ) {
|
||||
|
||||
//doesn't increment combo count if enemy invulnerable
|
||||
if (!enemy.isInvulnerable(target.getClass())) count++;
|
||||
count++;
|
||||
comboTime = 4f;
|
||||
misses = 0;
|
||||
BuffIndicator.refreshHero();
|
||||
|
@ -216,6 +215,13 @@ public class Combo extends Buff implements ActionIndicator.Action {
|
|||
ActionIndicator.clearAction(Combo.this);
|
||||
((Hero)target).spendAndNext(((Hero)target).attackDelay());
|
||||
return;
|
||||
} else if (enemy.isInvulnerable(target.getClass())){
|
||||
enemy.sprite.showStatus( CharSprite.POSITIVE, Messages.get(Char.class, "invulnerable") );
|
||||
Sample.INSTANCE.play(Assets.SND_MISS);
|
||||
detach();
|
||||
ActionIndicator.clearAction(Combo.this);
|
||||
((Hero)target).spendAndNext(((Hero)target).attackDelay());
|
||||
return;
|
||||
}
|
||||
|
||||
int dmg = target.damageRoll();
|
||||
|
|
|
@ -105,7 +105,7 @@ public class DemonSpawner extends Mob {
|
|||
|
||||
Dungeon.level.occupyCell(spawn);
|
||||
|
||||
GameScene.add( spawn );
|
||||
GameScene.add( spawn, 1 );
|
||||
if (sprite.visible) {
|
||||
Actor.addDelayed(new Pushing(spawn, pos, spawn.pos), -1);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user