diff options
author | andreykproductengine <akleshchev@productengine.com> | 2014-09-30 20:02:33 +0300 |
---|---|---|
committer | andreykproductengine <akleshchev@productengine.com> | 2014-09-30 20:02:33 +0300 |
commit | caaa711c6a4e56795b1fd08f0585cedba3e4212c (patch) | |
tree | ba48d037229553daf1a8f065788d7cdf1cc48bad /indra/newview/llviewerregion.cpp | |
parent | 1edf45f33b52b2f7e86d0e9b58fa7373e4870f5a (diff) |
MAINT-4448 FIXED Avatar often stops animating when being animated by an intan solo dance ball on Interesting based viewers only.
Diffstat (limited to 'indra/newview/llviewerregion.cpp')
-rwxr-xr-x | indra/newview/llviewerregion.cpp | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp index 7a6637c0a1..7d82ecf565 100755 --- a/indra/newview/llviewerregion.cpp +++ b/indra/newview/llviewerregion.cpp @@ -66,6 +66,7 @@ #include "llviewerstatsrecorder.h" #include "llvlmanager.h" #include "llvlcomposition.h" +#include "llvoavatarself.h" #include "llvocache.h" #include "llworld.h" #include "llspatialpartition.h" @@ -1485,22 +1486,27 @@ void LLViewerRegion::killObject(LLVOCacheEntry* entry, std::vector<LLDrawable*>& if(drawablep && !drawablep->getParent()) { - if (drawablep->getVObj()->isSelected()) + LLViewerObject* v_obj = drawablep->getVObj(); + if (v_obj->isSelected() + || (v_obj->flagAnimSource() && isAgentAvatarValid() && gAgentAvatarp->hasMotionFromSource(v_obj->getID()))) { - // do not remove selected objects + // do not remove objects user is interacting with ((LLViewerOctreeEntryData*)drawablep)->setVisible(); return; } - LLViewerObject::const_child_list_t& child_list = drawablep->getVObj()->getChildren(); + LLViewerObject::const_child_list_t& child_list = v_obj->getChildren(); for (LLViewerObject::child_list_t::const_iterator iter = child_list.begin(); iter != child_list.end(); iter++) { LLViewerObject* child = *iter; if(child->mDrawable) { - if(!child->mDrawable->getEntry() || !child->mDrawable->getEntry()->hasVOCacheEntry() || child->isSelected()) + if( !child->mDrawable->getEntry() + || !child->mDrawable->getEntry()->hasVOCacheEntry() + || child->isSelected() + || (child->flagAnimSource() && isAgentAvatarValid() && gAgentAvatarp->hasMotionFromSource(child->getID()))) { - //do not remove parent if any of its children non-cacheable or selected + //do not remove parent if any of its children non-cacheable, animating or selected //especially for the case that an avatar sits on a cache-able object ((LLViewerOctreeEntryData*)drawablep)->setVisible(); return; |