2023-12-21 13:58:05 -05:00
|
|
|
|
|
|
|
function SWEP:Reload()
|
|
|
|
if self:GetDelay() > CurTime() then
|
|
|
|
return false
|
|
|
|
end
|
2023-12-21 16:15:25 -05:00
|
|
|
if self:GetDelayReload() > CurTime() then
|
|
|
|
return false
|
|
|
|
end
|
2023-12-22 09:07:47 -05:00
|
|
|
if self:GetShotgunReloading() == 1 then
|
|
|
|
return false
|
|
|
|
end
|
2023-12-21 13:58:05 -05:00
|
|
|
if self:Clip1() >= self.Primary.ClipSize then
|
|
|
|
return false
|
|
|
|
end
|
2023-12-22 09:07:47 -05:00
|
|
|
|
|
|
|
if self.ShotgunReloading then
|
|
|
|
self:SendWeaponAnim( ACT_SHOTGUN_RELOAD_START )
|
|
|
|
self:GetOwner():GetViewModel():SetPlaybackRate( 2.5 )
|
|
|
|
self:SetDelayReload( CurTime() + 0.1 )
|
|
|
|
self:SetShotgunReloading( 1 )
|
|
|
|
else
|
2024-07-18 17:27:46 -04:00
|
|
|
self:SendAnim( "reload" )
|
|
|
|
--self:SetDelayReload( CurTime() + animtime*0.9 )
|
|
|
|
--self:SetRefillTime( CurTime() + animtime*0.5 )
|
2023-12-22 09:07:47 -05:00
|
|
|
end
|
2023-12-21 13:58:05 -05:00
|
|
|
return true
|
|
|
|
end
|