Skip to content

Instantly share code, notes, and snippets.

@x4fx77x4f
Created April 21, 2021 06:08
Show Gist options
  • Save x4fx77x4f/b29bfda8f5e474ce35fb5ccaa61edc49 to your computer and use it in GitHub Desktop.
Save x4fx77x4f/b29bfda8f5e474ce35fb5ccaa61edc49 to your computer and use it in GitHub Desktop.
Lag out your favorite sandbox server by throwing shittons of crowbars!
--@name Crowbars!
--@client
setupPermissionRequest({'console.command'}, "Crowbars!", true)
local i, j = 0, 50 -- set j to how many times you want to do it
hook.add('tick', '', function()
if not hasPermission('console.command') then
return
end
for i=1, 2 do -- more than twice doesn't work right
concmd('gm_giveswep weapon_crowbar')
concmd('use weapon_crowbar')
concmd('iam drop') -- or whatever the command is on your server
end
concmd('use none')
i = i+1
if i > j then
hook.remove('tick', '')
end
end)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment