Revision: 48218
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=48218
Author:   moguri
Date:     2012-06-23 03:39:03 +0000 (Sat, 23 Jun 2012)
Log Message:
-----------
Fix for [#29412] "Priority 0 cause problems with pulse mode" reported by 
Guillaume C?\195?\180t?\195?\169.

Right now this is being fixed by not allowing the exact same action (action, 
start/end frames, speed, etc) to be played if it's already playing. Hopefully 
this will not cause more issues than it solves.

Modified Paths:
--------------
    trunk/blender/source/gameengine/Ketsji/BL_Action.cpp

Modified: trunk/blender/source/gameengine/Ketsji/BL_Action.cpp
===================================================================
--- trunk/blender/source/gameengine/Ketsji/BL_Action.cpp        2012-06-23 
02:10:54 UTC (rev 48217)
+++ trunk/blender/source/gameengine/Ketsji/BL_Action.cpp        2012-06-23 
03:39:03 UTC (rev 48218)
@@ -141,6 +141,16 @@
                return false;
        }
 
+       // If we have the same settings, don't play again
+       // This is to resolve potential issues with pulses on sensors such as 
the ones
+       // reported in bug #29412. The fix is here so it works for both logic 
bricks and Python.
+       // However, this may eventually lead to issues where a user wants to 
override an already
+       // playing action with the same action and settings. If this becomes an 
issue,
+       // then this fix may have to be re-evaluated.
+       if (!IsDone() && m_action == prev_action && m_startframe == start && 
m_endframe == end
+                       && m_priority == priority && m_speed == playback_speed)
+               return false;
+
        if (prev_action != m_action)
        {
                // First get rid of any old controllers

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to