| 250 | } |
| 251 | |
| 252 | bool ActionManager::removeAllActionsFromTarget( Node* target ) { |
| 253 | std::vector<Action*> removeList; |
| 254 | |
| 255 | { |
| 256 | Lock l( mMutex ); |
| 257 | for ( auto it = mActions.begin(); it != mActions.end(); ++it ) { |
| 258 | Action* action = *it; |
| 259 | |
| 260 | if ( action->getTarget() == target ) { |
| 261 | removeList.emplace_back( *it ); |
| 262 | } |
| 263 | } |
| 264 | } |
| 265 | |
| 266 | for ( auto it = removeList.begin(); it != removeList.end(); ++it ) |
| 267 | removeAction( *it ); |
| 268 | |
| 269 | return !removeList.empty(); |
| 270 | } |
| 271 | |
| 272 | }} // namespace EE::Scene |