Elisonpp

Auto clicker script

Feb 7th, 2025 (edited)
178
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.46 KB | None | 0 0
  1. -- Criando a GUI
  2. local ScreenGui = Instance.new("ScreenGui")
  3. local AutoClickButton = Instance.new("TextButton")
  4.  
  5. -- Configuração da GUI
  6. ScreenGui.Parent = game:GetService("CoreGui") -- Mantém a GUI ativa
  7.  
  8. AutoClickButton.Parent = Seringas
  9. AutoClickButton.Size = UDim2.new(0, 150, 0, 75)
  10. AutoClickButton.Position = UDim2.new(0.9, -110, 0.85, 0) -- Posição ao lado do botão de pular
  11. AutoClickButton.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
  12. AutoClickButton.TextColor3 = Color3.fromRGB(255, 255, 255)
  13. AutoClickButton.Text = "Auto Click: OFF"
  14. AutoClickButton.Font = Enum.Font.SourceSansBold
  15. AutoClickButton.TextSize = 18
  16. AutoClickButton.BackgroundTransparency = 0.3
  17. AutoClickButton.BorderSizePixel = 2
  18. AutoClickButton.BorderColor3 = Color3.fromRGB(255, 255, 255)
  19.  
  20. -- Variáveis de controle
  21. local autoClickEnabled = false
  22.  
  23. -- Função para Auto Click
  24. function autoClick()
  25. while autoClickEnabled do
  26. -- Simula um clique do mouse
  27. local VirtualInputManager = game:GetService("VirtualInputManager")
  28. VirtualInputManager:SendMouseButtonEvent(0, 0, 0, true, game, 1)
  29. wait(0.05) -- Intervalo entre cliques
  30. end
  31. end
  32.  
  33. -- Alternar Auto Click ao clicar no botão
  34. AutoClickButton.MouseButton1Click:Connect(function()
  35. autoClickEnabled = not autoClickEnabled
  36. if autoClickEnabled then
  37. AutoClickButton.Text = "Auto Click: ON"
  38. autoClick()
  39. else
  40. AutoClickButton.Text = "Auto Click: OFF"
  41. end
  42. end)
Advertisement
Add Comment
Please, Sign In to add comment