Also, split getReactions() API into two calls * getTriggerReactions() - lists all reactions that can be triggered with MyAvatar.triggerReaction(). * getBeginReactions() - lists all reactions that can be used with MyAvatar.beginReaction() and MyAvatar.endReaction().
Showing the changes to libraries/animation/src/AnimStateMachine.cpp (1 of 7 files). Show all
Unified · Split
| @@ -95,6 +95,15 @@ const AnimPoseVec& AnimStateMachine::evaluate(const AnimVariantMap& animVars, co · 94 unmodified lines | |||
| 95 | return _poses; | 95 | return _poses; |
| 96 | } | 96 | } |
| 97 | 97 | ||
| 98 | const QString& AnimStateMachine::getCurrentStateID() const { | ||
| 99 | if (_currentState) { | ||
| 100 | return _currentState->getID(); | ||
| 101 | } else { | ||
| 102 | static QString emptyString; | ||
| 103 | return emptyString; | ||
| 104 | } | ||
| 105 | } | ||
| 106 | |||
| 98 | void AnimStateMachine::setCurrentState(State::Pointer state) { | 107 | void AnimStateMachine::setCurrentState(State::Pointer state) { |
| 99 | _previousState = _currentState ? _currentState : state; | 108 | _previousState = _currentState ? _currentState : state; |
| 100 | _currentState = state; | 109 | _currentState = state; |