mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-13 23:09:40 +00:00
Filter events that do not belong to the current group
This commit is contained in:
parent
da4f17859e
commit
47c157303a
1 changed files with 7 additions and 1 deletions
|
@ -56,7 +56,7 @@ CharacterController::CharacterController(const MWWorld::Ptr &ptr, MWRender::Anim
|
||||||
|
|
||||||
CharacterController::CharacterController(const CharacterController &rhs)
|
CharacterController::CharacterController(const CharacterController &rhs)
|
||||||
: mPtr(rhs.mPtr), mAnimation(rhs.mAnimation), mAnimNames(rhs.mAnimNames)
|
: mPtr(rhs.mPtr), mAnimation(rhs.mAnimation), mAnimNames(rhs.mAnimNames)
|
||||||
, mState(rhs.mState), mSkipAnim(rhs.mSkipAnim)
|
, mCurrentGroup(rhs.mCurrentGroup), mState(rhs.mState), mSkipAnim(rhs.mSkipAnim)
|
||||||
{
|
{
|
||||||
if(mAnimNames.size() == 0)
|
if(mAnimNames.size() == 0)
|
||||||
return;
|
return;
|
||||||
|
@ -79,6 +79,12 @@ void CharacterController::markerEvent(const std::string &evt)
|
||||||
// to this actor type
|
// to this actor type
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if(evt.length() <= mCurrentGroup.length()+2 || evt.compare(0, mCurrentGroup.length(), mCurrentGroup) != 0 ||
|
||||||
|
evt.compare(mCurrentGroup.length(), 2, ": ") != 0)
|
||||||
|
{
|
||||||
|
std::cerr<< "Event \""<<evt<<"\" does not belong to group \""<<mCurrentGroup<<"\"" <<std::endl;
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue