SHARE
TWEET

Untitled

a guest Dec 5th, 2018 66 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local Boost = 0
  2.  
  3. concommand.Add( 'alib_bhop_boost', function( ply, _, _, args )
  4.    
  5.     Boost = !Boost
  6.    
  7. end)
  8.  
  9. concommand.Add( 'alib_bhop_on', function( ply, _, _, args )
  10.  
  11.     local function bhop( cmd )
  12.  
  13.         if cmd:KeyDown( IN_JUMP ) and ply:GetMoveType() == MOVETYPE_WALK then
  14.        
  15.             if !ply:IsOnGround() then cmd:SetButtons( bit.band( cmd:GetButtons(), 0xFFFF - IN_JUMP ) ) end
  16.             if Boost then
  17.                 cmd:SetButtons( bit.bor( cmd:GetButtons(), IN_DUCK + IN_SPEED ) )
  18.                 cmd:SetForwardMove( -0.0001 )
  19.                
  20.                 if cmd:GetMouseX() < 0 then cmd:SetSideMove( -10000000 )   
  21.                 elseif cmd:GetMouseX() > 0 then cmd:SetSideMove( 10000000 )
  22.                 end
  23.                
  24.             end
  25.            
  26.         end
  27.        
  28.     end
  29.  
  30.     hook.Add( 'CreateMove', 'CreateMove', bhop )
  31.  
  32. end )
  33.  
  34. concommand.Add( 'alib_bhop_off', function( ply, _, _, args )
  35.  
  36.     hook.Remove( 'CreateMove', 'CreateMove' )
  37.    
  38. end )
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top