From 1999b5a8147129ac7b82a5e57420ab8e5d7734a2 Mon Sep 17 00:00:00 2001 From: Mitchell Stokes Date: Wed, 10 Dec 2014 21:20:19 -0800 Subject: [PATCH] Fix ping-pong actions when using the Action Actuator. --- source/gameengine/Converter/BL_ActionActuator.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/source/gameengine/Converter/BL_ActionActuator.cpp b/source/gameengine/Converter/BL_ActionActuator.cpp index f1a7287c0fe..c756d8695e6 100644 --- a/source/gameengine/Converter/BL_ActionActuator.cpp +++ b/source/gameengine/Converter/BL_ActionActuator.cpp @@ -256,12 +256,14 @@ bool BL_ActionActuator::Update(double curtime, bool frame) if ((m_flag & ACT_FLAG_PLAY_END) && (m_flag & ACT_FLAG_ACTIVE) && obj->IsActionDone(m_layer)) { m_flag &= ~ACT_FLAG_ACTIVE; - m_flag &= ~ACT_FLAG_ATTEMPT_PLAY; - if (m_playtype == ACT_ACTION_PINGPONG) + if (m_playtype == ACT_ACTION_PINGPONG) { m_flag ^= ACT_FLAG_REVERSE; - else + } + else { + m_flag &= ~ACT_FLAG_ATTEMPT_PLAY; return false; + } } // If a different action is playing, we've been overruled and are no longer active