CStudioHdr *C_FirstpersonBody::OnNewModel()
{
	CStudioHdr *pRet = BaseClass::OnNewModel();

	m_iBoneNeck = LookupBone( "ValveBiped.Bip01_Neck1" );
	m_iBoneArmL = LookupBone( "ValveBiped.Bip01_L_UpperArm" );
	m_iBoneArmR = LookupBone( "ValveBiped.Bip01_R_UpperArm" );
	m_iPoseParam_MoveYaw = LookupPoseParameter( "move_yaw" );

	return pRet;
}
CStudioHdr *C_GStringPlayerRagdoll::OnNewModel()
{
	CStudioHdr *ret = BaseClass::OnNewModel();

	m_iBoneHead = LookupBone( "ValveBiped.Bip01_Head1" );

	return ret;
}
Example #3
0
//-----------------------------------------------------------------------------
// Purpose: 
//-----------------------------------------------------------------------------
CStudioHdr *CTFMinigun::OnNewModel( void )
{
	CStudioHdr *hdr = BaseClass::OnNewModel();

	m_iBarrelBone = LookupBone( "barrel" );

	// skip resetting this while recording in the tool
	// we change the weapon to the worldmodel and back to the viewmodel when recording
	// which causes the minigun to not spin while recording
	if ( !IsToolRecording() )
	{
		m_flBarrelAngle = 0;

		m_flBarrelCurrentVelocity = 0;
		m_flBarrelTargetVelocity = 0;
	}

	return hdr;
}