Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Auto-Clicker Script for Roblox Features:
- --Creates movable GUI window
- --Adjustable click speed (random between min/max)
- --Position finder tool (shows X,Y coordinates)
- --Multi-position clicking sequence
- --Start/Stop controls
- --Cycles through specified click positions
- --Works while allowing real-time adjustments
- local UserInputService = game:GetService("UserInputService")
- local RunService = game:GetService("RunService")
- local Players = game:GetService("Players")
- local player = Players.LocalPlayer
- local mouse = player:GetMouse()
- local Clicking = false
- local ClickSpeed = {Min = 0.1, Max = 0.3}
- local ClickPositions = {}
- local CurrentPositionIndex = 1
- local ScreenGui = Instance.new("ScreenGui")
- ScreenGui.Parent = game.CoreGui
- local MainFrame = Instance.new("Frame")
- MainFrame.Size = UDim2.new(0, 300, 0, 400)
- MainFrame.Position = UDim2.new(0.5, -150, 0.5, -200)
- MainFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- MainFrame.Active = true
- MainFrame.Draggable = true
- MainFrame.Parent = ScreenGui
- local ScrollingFrame = Instance.new("ScrollingFrame")
- ScrollingFrame.Size = UDim2.new(1, 0, 1, 0)
- ScrollingFrame.CanvasSize = UDim2.new(0, 0, 0, 800)
- ScrollingFrame.ScrollBarThickness = 5
- ScrollingFrame.Parent = MainFrame
- -- Click Speed Section
- local SpeedSection = Instance.new("Frame")
- SpeedSection.Size = UDim2.new(0, 280, 0, 100)
- SpeedSection.Position = UDim2.new(0, 10, 0, 10)
- SpeedSection.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- SpeedSection.Parent = ScrollingFrame
- local SpeedLabel = Instance.new("TextLabel")
- SpeedLabel.Size = UDim2.new(1, 0, 0, 30)
- SpeedLabel.Text = "Click Speed (seconds)"
- SpeedLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
- SpeedLabel.Parent = SpeedSection
- local MinSpeedBox = Instance.new("TextBox")
- MinSpeedBox.Size = UDim2.new(0, 120, 0, 30)
- MinSpeedBox.Position = UDim2.new(0, 10, 0, 40)
- MinSpeedBox.PlaceholderText = "Min (0.1)"
- MinSpeedBox.Text = "0.1"
- MinSpeedBox.Parent = SpeedSection
- local MaxSpeedBox = Instance.new("TextBox")
- MaxSpeedBox.Size = UDim2.new(0, 120, 0, 30)
- MaxSpeedBox.Position = UDim2.new(0, 150, 0, 40)
- MaxSpeedBox.PlaceholderText = "Max (0.3)"
- MaxSpeedBox.Text = "0.3"
- MaxSpeedBox.Parent = SpeedSection
- -- Position Finder Section
- local FinderSection = Instance.new("Frame")
- FinderSection.Size = UDim2.new(0, 280, 0, 100)
- FinderSection.Position = UDim2.new(0, 10, 0, 120)
- FinderSection.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- FinderSection.Parent = ScrollingFrame
- local FinderLabel = Instance.new("TextLabel")
- FinderLabel.Size = UDim2.new(1, 0, 0, 30)
- FinderLabel.Text = "Position Finder"
- FinderLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
- FinderLabel.Parent = FinderSection
- local FindButton = Instance.new("TextButton")
- FindButton.Size = UDim2.new(0, 260, 0, 40)
- FindButton.Position = UDim2.new(0, 10, 0, 40)
- FindButton.Text = "Click to Find Position (Move Mouse)"
- FindButton.Parent = FinderSection
- local PositionDisplay = Instance.new("TextLabel")
- PositionDisplay.Size = UDim2.new(1, 0, 0, 20)
- PositionDisplay.Position = UDim2.new(0, 0, 0, 85)
- PositionDisplay.Text = "X: 0, Y: 0"
- PositionDisplay.TextColor3 = Color3.fromRGB(255, 255, 255)
- PositionDisplay.Parent = FinderSection
- -- Multi-Position Section
- local MultiPosSection = Instance.new("Frame")
- MultiPosSection.Size = UDim2.new(0, 280, 0, 200)
- MultiPosSection.Position = UDim2.new(0, 10, 0, 240)
- MultiPosSection.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- MultiPosSection.Parent = ScrollingFrame
- local MultiPosLabel = Instance.new("TextLabel")
- MultiPosLabel.Size = UDim2.new(1, 0, 0, 30)
- MultiPosLabel.Text = "Multi-Position Clicking"
- MultiPosLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
- MultiPosLabel.Parent = MultiPosSection
- local PosInputBox = Instance.new("TextBox")
- PosInputBox.Size = UDim2.new(0, 260, 0, 100)
- PosInputBox.Position = UDim2.new(0, 10, 0, 40)
- PosInputBox.MultiLine = true
- PosInputBox.TextWrapped = true
- PosInputBox.PlaceholderText = "Enter positions (x0000 y0000 x0000 y0000...)"
- PosInputBox.Parent = MultiPosSection
- local AddPosButton = Instance.new("TextButton")
- AddPosButton.Size = UDim2.new(0, 260, 0, 40)
- AddPosButton.Position = UDim2.new(0, 10, 0, 150)
- AddPosButton.Text = "Add Positions"
- AddPosButton.Parent = MultiPosSection
- -- Control Section
- local ControlSection = Instance.new("Frame")
- ControlSection.Size = UDim2.new(0, 280, 0, 60)
- ControlSection.Position = UDim2.new(0, 10, 0, 450)
- ControlSection.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- ControlSection.Parent = ScrollingFrame
- local StartButton = Instance.new("TextButton")
- StartButton.Size = UDim2.new(0, 120, 0, 40)
- StartButton.Position = UDim2.new(0, 10, 0, 10)
- StartButton.Text = "START"
- StartButton.TextColor3 = Color3.fromRGB(0, 255, 0)
- StartButton.Parent = ControlSection
- local StopButton = Instance.new("TextButton")
- StopButton.Size = UDim2.new(0, 120, 0, 40)
- StopButton.Position = UDim2.new(0, 150, 0, 10)
- StopButton.Text = "STOP"
- StopButton.TextColor3 = Color3.fromRGB(255, 0, 0)
- StopButton.Parent = ControlSection
- -- Functions
- FindButton.MouseButton1Click:Connect(function()
- FindButton.Text = "Move mouse and click anywhere..."
- local connection
- connection = UserInputService.InputBegan:Connect(function(input, processed)
- if input.UserInputType == Enum.UserInputType.MouseButton1 then
- PositionDisplay.Text = string.format("X: %d, Y: %d", mouse.X, mouse.Y)
- FindButton.Text = "Click to Find Position (Move Mouse)"
- connection:Disconnect()
- end
- end)
- end)
- AddPosButton.MouseButton1Click:Connect(function()
- local text = PosInputBox.Text
- local positions = {}
- for num in text:gmatch("%d+") do
- table.insert(positions, tonumber(num))
- end
- ClickPositions = {}
- for i = 1, #positions, 2 do
- if positions[i+1] then
- table.insert(ClickPositions, {X = positions[i], Y = positions[i+1]})
- end
- end
- end)
- local function ClickAtPosition(x, y)
- local oldPos = Vector2.new(mouse.X, mouse.Y)
- mouse1click()
- mousemoveabs(x, y)
- mouse1click()
- mousemoveabs(oldPos.X, oldPos.Y)
- end
- StartButton.MouseButton1Click:Connect(function()
- Clicking = true
- ClickSpeed.Min = tonumber(MinSpeedBox.Text) or 0.1
- ClickSpeed.Max = tonumber(MaxSpeedBox.Text) or 0.3
- spawn(function()
- while Clicking do
- if #ClickPositions > 0 then
- local pos = ClickPositions[CurrentPositionIndex]
- ClickAtPosition(pos.X, pos.Y)
- CurrentPositionIndex = CurrentPositionIndex % #ClickPositions + 1
- else
- mouse1click()
- end
- local delay = math.random() * (ClickSpeed.Max - ClickSpeed.Min) + ClickSpeed.Min
- wait(delay)
- end
- end)
- end)
- StopButton.MouseButton1Click:Connect(function()
- Clicking = false
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement