diff options
author | Tofu Linden <tofu.linden@lindenlab.com> | 2010-04-12 11:03:16 +0100 |
---|---|---|
committer | Tofu Linden <tofu.linden@lindenlab.com> | 2010-04-12 11:03:16 +0100 |
commit | 9fbe736774b1049265fd017bfe2413d436d35706 (patch) | |
tree | 2077c5ced76eed3d14c3340a9645306e99434bbb /indra/llcharacter/llkeyframemotion.cpp | |
parent | 103083b52def07c140dfc8f28989b5f4a93d288a (diff) | |
parent | 0a80627bca63ee05ce07df510ebe2072399dd01d (diff) |
(slightly hairy) merge from viewer-hotfix
Diffstat (limited to 'indra/llcharacter/llkeyframemotion.cpp')
-rw-r--r-- | indra/llcharacter/llkeyframemotion.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/indra/llcharacter/llkeyframemotion.cpp b/indra/llcharacter/llkeyframemotion.cpp index 5a2e3f73f9..f4dc3b927b 100644 --- a/indra/llcharacter/llkeyframemotion.cpp +++ b/indra/llcharacter/llkeyframemotion.cpp @@ -658,7 +658,12 @@ BOOL LLKeyframeMotion::onActivate() // If the keyframe anim has an associated emote, trigger it. if( mJointMotionList->mEmoteName.length() > 0 ) { - mCharacter->startMotion( gAnimLibrary.stringToAnimState(mJointMotionList->mEmoteName) ); + LLUUID emote_anim_id = gAnimLibrary.stringToAnimState(mJointMotionList->mEmoteName); + // don't start emote if already active to avoid recursion + if (!mCharacter->isMotionActive(emote_anim_id)) + { + mCharacter->startMotion( emote_anim_id ); + } } mLastLoopedTime = 0.f; |