[code]function SWEP:Holster( pSwitchingTo )
// cancel any reload in progress.
self.m_bInReload = false
// kill any think functions
self:SetThinkFunction( function() end )
// Send holster animation
self:SendWeaponAnim( ACT_VM_HOLSTER )
return true
end[/code]
After calling this on a weapon, the weapon switched to will retain the previous viewmodel. Do I have to reset the viewmodel to the new model manually after the sequence duration?
After testing switching from a base weapon with this code to a child inheriting from the base, the holster animation seems to not get run at all.
You have to return false in the first holster, then re-holster once the animation is over.
Sorry, you need to Log In to post a reply to this thread.