Advertisement
Mister_Stefan

BuyBot Lua(LWv4)

Apr 9th, 2021
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.21 KB | None | 0 0
  1. -- enable buybot.
  2. menu.add_check_box("Enable BuyBot")
  3.  
  4. -- weapons to buy.
  5. menu.add_combo_box("Rifle", {"None", "Scout", "AWP", "Auto"})
  6. menu.add_combo_box("Pistol", {"None", "Elite", "Deagle/Revolver"})
  7. menu.add_combo_box("Other", {"None", "Nades & Gear"})
  8.  
  9. -- buy when round start.
  10. events.register_event("round_start", function()
  11.     if menu.get_bool("Enable BuyBot") then
  12.         if menu.get_int("Rifle") == 1 then
  13.             console.execute("buy ssg08")
  14.         elseif menu.get_int("Rifle") == 2 then
  15.             console.execute("buy awp")
  16.         elseif menu.get_int("Rifle") == 3 then
  17.             console.execute("buy scar20")
  18.         end
  19.  
  20.         if menu.get_int("Pistol") == 1 then
  21.             console.execute("buy elite")
  22.         elseif menu.get_int("Pistol") == 2 then
  23.             console.execute("buy deagle")
  24.         end
  25.  
  26.         if menu.get_int("Other") == 1 then
  27.             console.execute("buy vest")
  28.             console.execute("buy vesthelm")
  29.             console.execute("buy smokegrenade")
  30.             console.execute("buy hegrenade")
  31.             console.execute("buy molotov")
  32.             console.execute("buy defuser")
  33.             console.execute("buy taser")
  34.         end
  35.     end
  36. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement