From c84d25b755c655ff4542e8f4b442d03ea419f9b9 Mon Sep 17 00:00:00 2001 From: "rem..om" Date: Thu, 18 Oct 2012 20:57:36 +0000 Subject: [PATCH] EffectTrack now correctly stops when loopMode is DontLoop git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9870 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- engine/src/core/com/jme3/animation/EffectTrack.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/engine/src/core/com/jme3/animation/EffectTrack.java b/engine/src/core/com/jme3/animation/EffectTrack.java index c99b67ee3..fe79bf1bf 100644 --- a/engine/src/core/com/jme3/animation/EffectTrack.java +++ b/engine/src/core/com/jme3/animation/EffectTrack.java @@ -192,6 +192,9 @@ public class EffectTrack implements ClonableTrack { */ public void setTime(float time, float weight, AnimControl control, AnimChannel channel, TempVars vars) { + if (time == length) { + return; + } //first time adding the Animation listener to stop the track at the end of the animation if (!initialized) { control.addListener(new OnEndListener());