From 5b09da5079d576678eb5d66a5518044d1b22664f Mon Sep 17 00:00:00 2001 From: prep Date: Wed, 5 Jan 2011 16:07:16 -0500 Subject: Fix for SH-579 --- indra/newview/llvoavatarself.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'indra/newview/llvoavatarself.cpp') diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp index 935bd4a588..5d1020fce8 100644 --- a/indra/newview/llvoavatarself.cpp +++ b/indra/newview/llvoavatarself.cpp @@ -1159,10 +1159,15 @@ BOOL LLVOAvatarSelf::detachObject(LLViewerObject *viewer_object) const LLMeshSkinInfo* pSkinData = gMeshRepo.getSkinInfo( pVObj->getVolume()->getParams().getSculptID() ); if ( pSkinData ) { - const int bindCnt = pSkinData->mAlternateBindMatrix.size(); - if ( bindCnt > 0 ) + const int jointCnt = pSkinData->mJointNames.size(); + bool fullRig = ( jointCnt>=20 ) ? true : false; + if ( fullRig ) { - LLVOAvatar::resetJointPositionsToDefault(); + const int bindCnt = pSkinData->mAlternateBindMatrix.size(); + if ( bindCnt > 0 ) + { + LLVOAvatar::resetJointPositionsToDefault(); + } } } } -- cgit v1.3