diff --git a/gamemodes/benny/gamemode/player.lua b/gamemodes/benny/gamemode/player.lua index d46248b..506f5c1 100644 --- a/gamemodes/benny/gamemode/player.lua +++ b/gamemodes/benny/gamemode/player.lua @@ -129,3 +129,41 @@ function PT:HandlerCheck() local wep = self:GetActiveWeapon() return ( wep:IsValid() and wep:GetClass() == "itemhandler" and wep.GetActiveR ) and wep or false end + +-- Temporary + +function GM:UpdateAnimation( ply, vel, maxseqgroundspeed ) + local len = vel:Length() + local movement = 1.0 + + if ( len > 0.2 ) then + movement = ( len / maxseqgroundspeed ) + end + + local rate = math.min( movement, 2 ) + + -- if we're under water we want to constantly be swimming.. + if ( ply:WaterLevel() >= 2 ) then + rate = math.max( rate, 0.5 ) + elseif ( !ply:IsOnGround() && len >= 1000 ) then + rate = 0.1 + end + + ply:SetPlaybackRate( rate ) +end + +function GM:HandlePlayerJumping( ply, vel ) + return false +end + +function GM:HandlePlayerVaulting( ply, vel ) + return false +end + +function GM:HandlePlayerLanding( ply, vel, onground ) + return false +end + +function GM:HandlePlayerNoClipping( ply, vel ) + return false +end \ No newline at end of file