//----------------------------------------------------------------------------- // Purpose: //----------------------------------------------------------------------------- void CBoneFollowerManager::AddBoneFollower( CBaseAnimating *pParentEntity, const char *pFollowerBoneName, solid_t *pSolid ) { m_iNumBones++; int iIndex = m_physBones.AddToTail(); CreatePhysicsFollower( pParentEntity, m_physBones[iIndex], pFollowerBoneName, pSolid ); }
//----------------------------------------------------------------------------- // Purpose: // Input : *pEntity - // iNumBones - // **pFollowerBoneNames - //----------------------------------------------------------------------------- void CBoneFollowerManager::InitBoneFollowers( CBaseAnimating *pParentEntity, int iNumBones, const char **pFollowerBoneNames ) { m_iNumBones = iNumBones; m_physBones.EnsureCount( iNumBones ); // Now init all the bones for ( int i = 0; i < iNumBones; i++ ) { CreatePhysicsFollower( pParentEntity, m_physBones[i], pFollowerBoneNames[i], NULL ); } }
//----------------------------------------------------------------------------- // Purpose: // Input : *pEntity - // iNumBones - // **pFollowerBoneNames - //----------------------------------------------------------------------------- void CBoneFollowerManager::InitBoneFollowers( CBaseEntity *pEntity, int iNumBones, const char **pFollowerBoneNames ) { m_hOuter = dynamic_cast<CBaseAnimating*>(pEntity); Assert( m_hOuter ); m_iNumBones = iNumBones; m_physBones.EnsureCount( iNumBones ); // Now init all the bones for ( int i = 0; i < iNumBones; i++ ) { CreatePhysicsFollower( m_physBones[i], pFollowerBoneNames[i] ); } }