v0.9.2: fixed succubus vfx/sfx triggering even if they aren't visible
This commit is contained in:
parent
e714c7860e
commit
0131feb0b9
|
@ -83,14 +83,18 @@ public class Succubus extends Mob {
|
|||
} else {
|
||||
HP += 5 + damage;
|
||||
}
|
||||
sprite.emitter().burst( Speck.factory( Speck.HEALING ), 2 );
|
||||
Sample.INSTANCE.play( Assets.Sounds.CHARMS );
|
||||
if (Dungeon.level.heroFOV[pos]) {
|
||||
sprite.emitter().burst( Speck.factory( Speck.HEALING ), 2 );
|
||||
Sample.INSTANCE.play( Assets.Sounds.CHARMS );
|
||||
}
|
||||
} else if (Random.Int( 3 ) == 0) {
|
||||
Charm c = Buff.affect( enemy, Charm.class, Charm.DURATION/2f );
|
||||
c.object = id();
|
||||
c.ignoreNextHit = true; //so that the -5 duration from succubus hit is ignored
|
||||
enemy.sprite.centerEmitter().start( Speck.factory( Speck.HEART ), 0.2f, 5 );
|
||||
Sample.INSTANCE.play( Assets.Sounds.CHARMS );
|
||||
if (Dungeon.level.heroFOV[enemy.pos]) {
|
||||
enemy.sprite.centerEmitter().start(Speck.factory(Speck.HEART), 0.2f, 5);
|
||||
Sample.INSTANCE.play(Assets.Sounds.CHARMS);
|
||||
}
|
||||
}
|
||||
|
||||
return damage;
|
||||
|
|
Loading…
Reference in New Issue
Block a user