From bb5b493c1b3aafc9173e870ce63632bb85c4a6c4 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Sun, 24 Jun 2018 22:20:57 -0400 Subject: [PATCH] v0.7.0: fixed blacksmith sound errors caused by timekeeper's hourglass --- .../shatteredpixeldungeon/sprites/BlacksmithSprite.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/BlacksmithSprite.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/BlacksmithSprite.java index 15de5f179..1b1d995f7 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/BlacksmithSprite.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/BlacksmithSprite.java @@ -75,7 +75,8 @@ public class BlacksmithSprite extends MobSprite { public void onComplete( Animation anim ) { super.onComplete( anim ); - if (visible && emitter != null && anim == idle) { + //FIXME should figure out why onComplete is called constantly when an animation is paused + if (visible && emitter != null && anim == idle && !paused) { emitter.burst( Speck.factory( Speck.FORGE ), 3 ); float volume = 0.2f / (Dungeon.level.distance( ch.pos, Dungeon.hero.pos )); Sample.INSTANCE.play( Assets.SND_EVOKE, volume, volume, 0.8f );