diff options
author | Mitchell Stokes <mogurijin@gmail.com> | 2011-06-16 05:59:50 +0400 |
---|---|---|
committer | Mitchell Stokes <mogurijin@gmail.com> | 2011-06-16 05:59:50 +0400 |
commit | 65af1dcecdb45eb1509f839c018b65acd6f23195 (patch) | |
tree | 495ebfda89b7bba274da8d08657ae77e23b28bf9 /source | |
parent | 47b061609d7a29116cdac9ba375408b5217683bd (diff) |
BGE Animations: Making sure the Action Actuator has a valid action before attempting to play.
Diffstat (limited to 'source')
-rw-r--r-- | source/gameengine/Converter/BL_ActionActuator.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/gameengine/Converter/BL_ActionActuator.cpp b/source/gameengine/Converter/BL_ActionActuator.cpp index b57eaadaea6..b318121c486 100644 --- a/source/gameengine/Converter/BL_ActionActuator.cpp +++ b/source/gameengine/Converter/BL_ActionActuator.cpp @@ -152,6 +152,10 @@ bool BL_ActionActuator::Update(double curtime, bool frame) 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; |