-- MAHMOUD SPEED HUB -- Roblox Studio | LocalScript -- For your own Roblox experience local Players = game:GetService("Players") local UIS = game:GetService("UserInputService") local player = Players.LocalPlayer local playerGui = player:WaitForChild("PlayerGui") local old = playerGui:FindFirstChild("MahmoudSpeedHub") if old then old:Destroy() end local DEFAULT_SPEED = 16 local selectedSpeed = 32 local speedEnabled = false local gui = Instance.new("ScreenGui") gui.Name = "MahmoudSpeedHub" gui.ResetOnSpawn = false gui.Parent = playerGui local main = Instance.new("Frame") main.Size = UDim2.fromOffset(280, 220) main.Position = UDim2.new(0.5, -140, 0.5, -110) main.BackgroundColor3 = Color3.fromRGB(20, 22, 35) main.BorderSizePixel = 0 main.Active = true main.Parent = gui local corner = Instance.new("UICorner") corner.CornerRadius = UDim.new(0, 12) corner.Parent = main local outline = Instance.new("UIStroke") outline.Color = Color3.fromRGB(145, 90, 240) outline.Thickness = 1.5 outline.Parent = main -- Header local header = Instance.new("Frame") header.Size = UDim2.new(1, 0, 0, 42) header.BackgroundColor3 = Color3.fromRGB(43, 31, 65) header.BorderSizePixel = 0 header.Active = true header.Parent = main local headerCorner = Instance.new("UICorner") headerCorner.CornerRadius = UDim.new(0, 12) headerCorner.Parent = header local title = Instance.new("TextLabel") title.Size = UDim2.new(1, -50, 1, 0) title.Position = UDim2.fromOffset(12, 0) title.BackgroundTransparency = 1 title.Text = "MAHMOUD SPEED HUB" title.TextColor3 = Color3.fromRGB(205, 175, 255) title.TextSize = 16 title.Font = Enum.Font.GothamBold title.TextXAlignment = Enum.TextXAlignment.Left title.Parent = header -- Close button local close = Instance.new("TextButton") close.Size = UDim2.fromOffset(30, 30) close.Position = UDim2.new(1, -36, 0, 6) close.Text = "X" close.TextColor3 = Color3.new(1, 1, 1) close.TextSize = 15 close.Font = Enum.Font.GothamBold close.BackgroundColor3 = Color3.fromRGB(170, 55, 65) close.Parent = header local closeCorner = Instance.new("UICorner") closeCorner.CornerRadius = UDim.new(0, 7) closeCorner.Parent = close -- Speed input local speedInput = Instance.new("TextBox") speedInput.Size = UDim2.new(1, -30, 0, 38) speedInput.Position = UDim2.fromOffset(15, 58) speedInput.BackgroundColor3 = Color3.fromRGB(40, 43, 60) speedInput.TextColor3 = Color3.new(1, 1, 1) speedInput.PlaceholderText = "Speed: 1 - 999" speedInput.Text = "32" speedInput.TextSize = 14 speedInput.Font = Enum.Font.Gotham speedInput.ClearTextOnFocus = false speedInput.Parent = main local inputCorner = Instance.new("UICorner") inputCorner.CornerRadius = UDim.new(0, 7) inputCorner.Parent = speedInput -- ON/OFF local toggle = Instance.new("TextButton") toggle.Size = UDim2.new(1, -30, 0, 40) toggle.Position = UDim2.fromOffset(15, 108) toggle.BackgroundColor3 = Color3.fromRGB(145, 55, 65) toggle.Text = "SPEED: OFF" toggle.TextColor3 = Color3.new(1, 1, 1) toggle.TextSize = 15 toggle.Font = Enum.Font.GothamBold toggle.Parent = main local toggleCorner = Instance.new("UICorner") toggleCorner.CornerRadius = UDim.new(0, 7) toggleCorner.Parent = toggle -- Status local status = Instance.new("TextLabel") status.Size = UDim2.new(1, -20, 0, 25) status.Position = UDim2.fromOffset(10, 166) status.BackgroundTransparency = 1 status.Text = "STATUS: READY" status.TextColor3 = Color3.fromRGB(100, 230, 160) status.TextSize = 12 status.Font = Enum.Font.Gotham status.Parent = main -- Reopen button local reopen = Instance.new("TextButton") reopen.Size = UDim2.fromOffset(125, 38) reopen.Position = UDim2.new(0, 15, 0.5, -19) reopen.BackgroundColor3 = Color3.fromRGB(75, 45, 120) reopen.Text = "MAHMOUD SPEED" reopen.TextColor3 = Color3.new(1, 1, 1) reopen.TextSize = 11 reopen.Font = Enum.Font.GothamBold reopen.Visible = false reopen.Parent = gui local reopenCorner = Instance.new("UICorner") reopenCorner.CornerRadius = UDim.new(0, 8) reopenCorner.Parent = reopen -- Dragging with mouse and touch local dragging = false local dragInput local dragStart local startPosition header.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then dragging = true dragStart = input.Position startPosition = main.Position input.Changed:Connect(function() if input.UserInputState == Enum.UserInputState.End then dragging = false end end) end end) header.InputChanged:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then dragInput = input end end) UIS.InputChanged:Connect(function(input) if dragging and input == dragInput then local delta = input.Position - dragStart main.Position = UDim2.new( startPosition.X.Scale, startPosition.X.Offset + delta.X, startPosition.Y.Scale, startPosition.Y.Offset + delta.Y ) end end) -- Apply speed in your own experience. local function applySpeed() local character = player.Character local humanoid = character and character:FindFirstChildOfClass("Humanoid") if humanoid then humanoid.WalkSpeed = speedEnabled and selectedSpeed or DEFAULT_SPEED end end local function readSpeed() local number = tonumber(speedInput.Text) if not number or number < 1 or number > 999 then status.Text = "ENTER SPEED FROM 1 TO 999" status.TextColor3 = Color3.fromRGB(255, 120, 120) return false end selectedSpeed = math.floor(number) speedInput.Text = tostring(selectedSpeed) return true end toggle.Activated:Connect(function() if not readSpeed() then return end speedEnabled = not speedEnabled applySpeed() if speedEnabled then toggle.Text = "SPEED: ON" toggle.BackgroundColor3 = Color3.fromRGB(35, 145, 90) status.Text = "SPEED: " .. selectedSpeed status.TextColor3 = Color3.fromRGB(100, 230, 160) else toggle.Text = "SPEED: OFF" toggle.BackgroundColor3 = Color3.fromRGB(145, 55, 65) status.Text = "STATUS: NORMAL SPEED" status.TextColor3 = Color3.fromRGB(180, 180, 195) end end) speedInput.FocusLost:Connect(function() if readSpeed() and speedEnabled then applySpeed() status.Text = "SPEED UPDATED: " .. selectedSpeed end end) -- Close and reopen close.Activated:Connect(function() main.Visible = false reopen.Visible = true end) reopen.Activated:Connect(function() main.Visible = true reopen.Visible = false end) -- Restore selected setting after respawn player.CharacterAdded:Connect(function(character) local humanoid = character:WaitForChild("Humanoid") humanoid.WalkSpeed = speedEnabled and selectedSpeed or DEFAULT_SPEED end) print("MAHMOUD SPEED HUB LOADED")