Looping reload animation

I’m currently working on a swep for the ZPS Winchester and everything is working except the reload animation. Whenever you go to reload it loops the reload animation, I’ve been trying to find a way to send it the ACT_VM_IDLE animation but so far nothing has worked.

Does anyone know of a way to send an idle animation to a view model after it has completed the reload animation?

My reload code:

function SWEP:Reload()
if ( self.Weapon:Clip1() < self.Weapon.Primary.ClipSize && self.Owner:GetAmmoCount( self.Weapon.Primary.Ammo ) > 0 ) then
self.Weapon:DefaultReload( ACT_VM_RELOAD);
self.Weapon:EmitSound(“Weapons/Firearms/DoubleBarrel_Shotgun/winchester_reload.wav”)

end
end

maybe if the primary clip is full set it to idle?

[lua]
function SWEP:Reload()
local full = 36 --example number
if ( self.Weapon:Clip1() < self.Weapon.Primary.ClipSize && self.Owner:GetAmmoCount( self.Weapon.Primary.Ammo ) > 0 ) then
self.Weapon:DefaultReload( ACT_VM_RELOAD)
self.Weapon:EmitSound(“Weapons/Firearms/DoubleBarrel_Shotgun/winchester_reload.wav”)
elseif self.Weapon.Primary.ClipSize == full then
self.Weapon:DefaultReload( ACT_VM_IDLE )
end
end
[/lua]

Thanks for the response but sadly it didn’t work. I tried having it check in the think if it had 2 bullets bullets in the clip (which is the clip size) but that didn’t work either.