[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37535] branches/soc-2011-pepper/source/ gameengine/Converter/BL_ActionActuator.cpp: BGE Animations: Making sure the Action Actuator has a valid action before attempting to play .
Mitchell Stokes
mogurijin at gmail.com
Thu Jun 16 03:59:50 CEST 2011
Revision: 37535
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=37535
Author: moguri
Date: 2011-06-16 01:59:50 +0000 (Thu, 16 Jun 2011)
Log Message:
-----------
BGE Animations: Making sure the Action Actuator has a valid action before attempting to play.
Modified Paths:
--------------
branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp
Modified: branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp
===================================================================
--- branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp 2011-06-16 01:57:39 UTC (rev 37534)
+++ branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp 2011-06-16 01:59:50 UTC (rev 37535)
@@ -152,6 +152,10 @@
short play_mode = BL_Action::ACT_MODE_PLAY;
float start = m_startframe, end = m_endframe;
+ // If we don't have an action, we can't do anything
+ if (!m_action)
+ return false;
+
// Don't do anything if we're not "active"
if (!frame)
return true;
More information about the Bf-blender-cvs
mailing list