Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- WLh4x Hub v10 - Anti Lag e FPS Booster realmente funcionais
- -- Delta Executor | Mobile e PC
- local player = game.Players.LocalPlayer
- local camera = workspace.CurrentCamera
- local UIS = game:GetService("UserInputService")
- local RunService = game:GetService("RunService")
- local TweenService = game:GetService("TweenService")
- local StarterGui = game:GetService("StarterGui")
- local HttpService = game:GetService("HttpService")
- local Lighting = game:GetService("Lighting")
- if not game:IsLoaded() then game.Loaded:Wait() end
- -- ==================== CONFIGURAÇÕES ====================
- local Settings = {
- Aimbot = false,
- AimbotKey = nil,
- AimPart = "Head",
- FOV = 150,
- FOVCircle = false,
- FOVColor = Color3.fromRGB(255, 255, 255),
- Smoothness = 1.0,
- TriggerBot = false,
- TriggerDelay = 0.1,
- SilentAim = false,
- BoxESP = false,
- ESPMaxDistance = 1000,
- LineESP = false,
- SkeletonESP = false,
- NoRecoil = false,
- NoSpread = false,
- HitboxExpand = false,
- HitboxMultiplier = 1.2,
- AntiLag = false,
- FPSBoost = false,
- ToggleKey = Enum.KeyCode.RightShift
- }
- -- ==================== SALVAMENTO ====================
- local function save()
- pcall(function() writefile("WLh4xHub_v10.json", HttpService:JSONEncode(Settings)) end)
- end
- local function load()
- pcall(function()
- if isfile("WLh4xHub_v10.json") then
- local data = HttpService:JSONDecode(readfile("WLh4xHub_v10.json"))
- for k, v in pairs(data) do Settings[k] = v end
- end
- end)
- end
- load()
- -- ==================== UTILITÁRIOS ====================
- local function isEnemy(plr)
- if plr == player then return false end
- if not player.Team or not plr.Team then return true end
- return plr.Team ~= player.Team
- end
- local function getWeaponName(char)
- for _, v in ipairs(char:GetChildren()) do
- if v:IsA("Tool") and v:FindFirstChild("Handle") then return v.Name end
- end
- return "Unarmed"
- end
- local function isVisible(targetPos, ignoreChar)
- local origin = camera.CFrame.Position
- local dir = (targetPos - origin).Unit
- local ray = Ray.new(origin, dir * 1000)
- local ignore = {player.Character or nil}
- if ignoreChar then table.insert(ignore, ignoreChar) end
- local hit = workspace:FindPartOnRayWithIgnoreList(ray, ignore)
- return hit == nil
- end
- local function onScreen(pos)
- local sp, on = camera:WorldToViewportPoint(pos)
- return on, sp
- end
- -- Pega APENAS a parte "Head"
- local function getHeadPos(char)
- local head = char:FindFirstChild("Head")
- return head and head.Position or nil
- end
- -- ==================== ESP (CORRIGIDO) ====================
- local ESPObjects = {}
- function clearESP(plr)
- if ESPObjects[plr] then
- local data = ESPObjects[plr]
- for _, drawing in pairs(data.drawings) do
- if type(drawing) == "table" then
- for _, sub in pairs(drawing) do
- if sub.Visible ~= nil then sub:Remove() end
- end
- elseif drawing.Remove then
- drawing:Remove()
- end
- end
- if data.connection then data.connection:Disconnect() end
- ESPObjects[plr] = nil
- end
- end
- local function createESP(plr)
- if not isEnemy(plr) then return end
- local function setup()
- local char = plr.Character
- if not char then return false end
- local head = char:FindFirstChild("Head")
- local root = char:FindFirstChild("HumanoidRootPart")
- local humanoid = char:FindFirstChildOfClass("Humanoid")
- if not (head and root and humanoid) then return false end
- clearESP(plr)
- local d = {}
- d.box = Drawing.new("Square"); d.box.Visible = false; d.box.Color = Color3.fromRGB(255,0,0); d.box.Thickness = 2; d.box.Filled = false
- d.name = Drawing.new("Text"); d.name.Visible = false; d.name.Color = Color3.fromRGB(255,255,255); d.name.Size = 14; d.name.Center = true; d.name.Outline = true
- d.weapon = Drawing.new("Text"); d.weapon.Visible = false; d.weapon.Color = Color3.fromRGB(200,200,200); d.weapon.Size = 12; d.weapon.Center = true; d.weapon.Outline = true
- d.dist = Drawing.new("Text"); d.dist.Visible = false; d.dist.Color = Color3.fromRGB(200,200,200); d.dist.Size = 12; d.dist.Center = true; d.dist.Outline = true
- d.hpBar = Drawing.new("Square"); d.hpBar.Visible = false; d.hpBar.Filled = true; d.hpBar.Color = Color3.fromRGB(0,255,0)
- d.hpBg = Drawing.new("Square"); d.hpBg.Visible = false; d.hpBg.Filled = true; d.hpBg.Color = Color3.fromRGB(50,50,50)
- d.line = Drawing.new("Line"); d.line.Visible = false; d.line.Color = Color3.fromRGB(255,0,0); d.line.Thickness = 1
- d.skeletonLines = {}
- local connections = {
- {"Head", "UpperTorso"}, {"UpperTorso", "LowerTorso"},
- {"UpperTorso", "LeftUpperArm"}, {"UpperTorso", "RightUpperArm"},
- {"LowerTorso", "LeftUpperLeg"}, {"LowerTorso", "RightUpperLeg"}
- }
- for _, conn in ipairs(connections) do
- local l = Drawing.new("Line"); l.Visible = false; l.Color = Color3.fromRGB(0,255,0); l.Thickness = 1
- table.insert(d.skeletonLines, {line = l, from = conn[1], to = conn[2]})
- end
- local function update()
- local c = plr.Character
- if not c or not c:FindFirstChild("Head") or not c:FindFirstChild("HumanoidRootPart") or not c:FindFirstChildOfClass("Humanoid") then
- for _, obj in pairs(d) do
- if type(obj) == "table" then
- for _, sub in pairs(obj) do if sub.Visible ~= nil then sub.Visible = false end end
- elseif obj.Visible ~= nil then obj.Visible = false end
- end
- return
- end
- local headPos = c.Head.Position
- local r = c.HumanoidRootPart
- local hum = c.Humanoid
- local myRoot = player.Character and player.Character:FindFirstChild("HumanoidRootPart")
- local dist = myRoot and (r.Position - myRoot.Position).Magnitude or 0
- if dist > Settings.ESPMaxDistance then
- for _, obj in pairs(d) do
- if type(obj) == "table" then
- for _, sub in pairs(obj) do if sub.Visible ~= nil then sub.Visible = false end end
- elseif obj.Visible ~= nil then obj.Visible = false end
- end
- return
- end
- local on, pos = onScreen(headPos)
- if not on then
- for _, obj in pairs(d) do
- if type(obj) == "table" then
- for _, sub in pairs(obj) do if sub.Visible ~= nil then sub.Visible = false end end
- elseif obj.Visible ~= nil then obj.Visible = false end
- end
- return
- end
- local charHeight = (headPos.Y - r.Position.Y) * 1.2
- local height = math.clamp(charHeight / (dist * 0.01), 40, 250)
- local width = height * 0.6
- local x = pos.X - width/2
- local y = pos.Y - height/2
- d.box.Size = Vector2.new(width, height); d.box.Position = Vector2.new(x, y); d.box.Visible = Settings.BoxESP
- d.name.Text = plr.Name; d.name.Position = Vector2.new(pos.X, y - 18); d.name.Visible = Settings.BoxESP
- d.weapon.Text = getWeaponName(c); d.weapon.Position = Vector2.new(pos.X, y - 6); d.weapon.Visible = Settings.BoxESP
- d.dist.Text = string.format("%.0fm", dist); d.dist.Position = Vector2.new(pos.X, y + height + 6); d.dist.Visible = Settings.BoxESP
- local hp = (hum.MaxHealth > 0) and (hum.Health / hum.MaxHealth) or 0
- local barWidth = 4
- d.hpBg.Size = Vector2.new(barWidth, height); d.hpBg.Position = Vector2.new(x - barWidth - 2, y); d.hpBg.Visible = Settings.BoxESP
- d.hpBar.Size = Vector2.new(barWidth, height * hp); d.hpBar.Position = Vector2.new(x - barWidth - 2, y + height * (1 - hp))
- if hp > 0.6 then d.hpBar.Color = Color3.fromRGB(0,255,0)
- elseif hp > 0.3 then d.hpBar.Color = Color3.fromRGB(255,255,0)
- else d.hpBar.Color = Color3.fromRGB(255,0,0) end
- d.hpBar.Visible = Settings.BoxESP
- if myRoot then
- local myPos = camera:WorldToViewportPoint(myRoot.Position)
- d.line.From = Vector2.new(myPos.X, myPos.Y); d.line.To = Vector2.new(pos.X, pos.Y)
- end
- d.line.Visible = Settings.LineESP
- for _, sk in ipairs(d.skeletonLines) do
- local partA = c:FindFirstChild(sk.from)
- local partB = c:FindFirstChild(sk.to)
- if partA and partB then
- local onA, posA = onScreen(partA.Position)
- local onB, posB = onScreen(partB.Position)
- if onA and onB then
- sk.line.From = Vector2.new(posA.X, posA.Y); sk.line.To = Vector2.new(posB.X, posB.Y)
- sk.line.Visible = Settings.SkeletonESP
- else sk.line.Visible = false end
- else sk.line.Visible = false end
- end
- end
- local conn = RunService.RenderStepped:Connect(update)
- ESPObjects[plr] = {drawings = d, connection = conn}
- return true
- end
- if not setup() then
- local retryConn
- retryConn = RunService.Heartbeat:Connect(function()
- if setup() then retryConn:Disconnect() end
- end)
- end
- plr.CharacterAdded:Connect(function()
- clearESP(plr)
- local retryConn
- retryConn = RunService.Heartbeat:Connect(function()
- if setup() then retryConn:Disconnect() end
- end)
- end)
- plr.CharacterRemoving:Connect(function()
- clearESP(plr)
- end)
- end
- for _, p in ipairs(game.Players:GetPlayers()) do
- if p ~= player then createESP(p) end
- end
- game.Players.PlayerAdded:Connect(function(p)
- if p ~= player then createESP(p) end
- end)
- game.Players.PlayerRemoving:Connect(function(p)
- clearESP(p)
- end)
- -- ==================== AIMBOT ====================
- local function getClosest()
- local best, bestAngle = nil, math.huge
- local myChar = player.Character
- if not myChar or not myChar.PrimaryPart then return nil end
- for _, target in ipairs(game.Players:GetPlayers()) do
- if isEnemy(target) and target.Character then
- local headPos = getHeadPos(target.Character)
- if not headPos then continue end
- if not isVisible(headPos, target.Character) then continue end
- local on, sp = onScreen(headPos)
- if not on then continue end
- local dist = (myChar.PrimaryPart.Position - headPos).Magnitude
- if dist > Settings.ESPMaxDistance then continue end
- if Settings.FOVCircle then
- local center = Vector2.new(camera.ViewportSize.X/2, camera.ViewportSize.Y/2)
- if (Vector2.new(sp.X, sp.Y) - center).Magnitude > Settings.FOV then continue end
- end
- local dir = (headPos - camera.CFrame.Position).Unit
- local angle = math.acos(math.clamp(camera.CFrame.LookVector:Dot(dir), -1, 1))
- if angle < bestAngle then
- bestAngle = angle
- best = {position = headPos}
- end
- end
- end
- return best
- end
- RunService:BindToRenderStep("WLh4xAimbot", 200, function()
- if not Settings.Aimbot then return end
- if Settings.AimbotKey and not UIS:IsKeyDown(Settings.AimbotKey) then return end
- local target = getClosest()
- if target then
- if Settings.Smoothness >= 1.0 then
- camera.CFrame = CFrame.lookAt(camera.CFrame.Position, target.position)
- else
- local newDir = (target.position - camera.CFrame.Position).Unit
- local currentDir = camera.CFrame.LookVector
- local interpolated = currentDir:Lerp(newDir, Settings.Smoothness)
- camera.CFrame = CFrame.new(camera.CFrame.Position, camera.CFrame.Position + interpolated)
- end
- end
- end)
- -- Trigger Bot
- RunService.RenderStepped:Connect(function()
- if Settings.TriggerBot then
- local t = getClosest()
- if t then
- local tool = player.Character and player.Character:FindFirstChildOfClass("Tool")
- if tool then
- tool:Activate()
- task.wait(Settings.TriggerDelay)
- tool:Deactivate()
- end
- end
- end
- end)
- -- ==================== NO RECOIL ====================
- local lastRecoilTime = 0
- UIS.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 then
- lastRecoilTime = tick()
- end
- end)
- RunService.RenderStepped:Connect(function()
- if Settings.NoRecoil and tick() - lastRecoilTime < 0.5 then
- camera.CFrame = camera.CFrame * CFrame.Angles(-0.003, 0, 0)
- end
- end)
- -- ==================== NO SPREAD ====================
- local oldRandom = math.random
- local function setNoSpread(state)
- if state then math.random = function(...) return 0 end
- else math.random = oldRandom end
- end
- local function onNoSpreadChanged(val)
- Settings.NoSpread = val
- setNoSpread(val)
- save()
- end
- -- ==================== HITBOX EXPAND ====================
- local function expandHitbox(char)
- if not Settings.HitboxExpand then return end
- for _, part in ipairs(char:GetChildren()) do
- if part:IsA("BasePart") and part.Name ~= "HumanoidRootPart" then
- part.Size = part.Size * Settings.HitboxMultiplier
- end
- end
- end
- for _, p in ipairs(game.Players:GetPlayers()) do
- if p ~= player then
- if p.Character then expandHitbox(p.Character) end
- p.CharacterAdded:Connect(expandHitbox)
- end
- end
- game.Players.PlayerAdded:Connect(function(p)
- if p ~= player then
- p.CharacterAdded:Connect(expandHitbox)
- if p.Character then expandHitbox(p.Character) end
- end
- end)
- -- ==================== FOV CIRCLE ====================
- local fovCircle
- local function updateFOV()
- if fovCircle then fovCircle:Remove() fovCircle = nil end
- if not Settings.FOVCircle then return end
- pcall(function()
- fovCircle = Drawing.new("Circle")
- fovCircle.Visible = true
- fovCircle.Color = Settings.FOVColor
- fovCircle.Thickness = 2
- fovCircle.NumSides = 80
- fovCircle.Radius = Settings.FOV
- fovCircle.Position = Vector2.new(camera.ViewportSize.X/2, camera.ViewportSize.Y/2)
- fovCircle.Transparency = 0.4
- end)
- end
- camera:GetPropertyChangedSignal("ViewportSize"):Connect(updateFOV)
- -- ==================== SISTEMA DE PERFORMANCE (ANTI LAG / FPS BOOST) ====================
- local function applyPerformanceChanges()
- -- Anti Lag
- if Settings.AntiLag then
- pcall(function() settings().Rendering.QualityLevel = "Level01" end)
- for _, obj in ipairs(workspace:GetDescendants()) do
- if obj:IsA("ParticleEmitter") or obj:IsA("Fire") or obj:IsA("Smoke") then
- obj.Enabled = false
- end
- if obj:IsA("Decal") or obj:IsA("Texture") then
- obj.Texture = ""
- end
- end
- -- Reduz distância de renderização
- workspace.StreamingMinRadius = 16
- workspace.StreamingTargetRadius = 32
- -- Remove neblina
- Lighting.FogEnd = 1000
- Lighting.FogStart = 800
- -- Desliga pós‑processamento
- if Lighting:FindFirstChild("Bloom") then Lighting.Bloom.Enabled = false end
- if Lighting:FindFirstChild("Blur") then Lighting.Blur.Enabled = false end
- if Lighting:FindFirstChild("SunRays") then Lighting.SunRays.Enabled = false end
- if Lighting:FindFirstChild("ColorCorrection") then Lighting.ColorCorrection.Enabled = false end
- else
- pcall(function() settings().Rendering.QualityLevel = "Level10" end)
- for _, obj in ipairs(workspace:GetDescendants()) do
- if obj:IsA("ParticleEmitter") or obj:IsA("Fire") or obj:IsA("Smoke") then
- obj.Enabled = true
- end
- end
- workspace.StreamingMinRadius = 64
- workspace.StreamingTargetRadius = 128
- Lighting.FogEnd = 10000
- Lighting.FogStart = 8000
- if Lighting:FindFirstChild("Bloom") then Lighting.Bloom.Enabled = true end
- if Lighting:FindFirstChild("Blur") then Lighting.Blur.Enabled = true end
- if Lighting:FindFirstChild("SunRays") then Lighting.SunRays.Enabled = true end
- if Lighting:FindFirstChild("ColorCorrection") then Lighting.ColorCorrection.Enabled = true end
- end
- -- FPS Boost
- if Settings.FPSBoost then
- pcall(function() settings().Rendering.ShadowQuality = "Level01" end)
- for _, light in ipairs(workspace:GetDescendants()) do
- if light:IsA("SurfaceLight") or light:IsA("PointLight") or light:IsA("SpotLight") then
- light.Enabled = false
- end
- end
- -- Desliga reflexos
- for _, obj in ipairs(workspace:GetDescendants()) do
- if obj:IsA("Part") and obj.Material == Enum.Material.Glass then
- obj.Reflectance = 0
- end
- end
- -- Aumenta prioridade de performance
- pcall(function() settings().Rendering.FrameRateManager = "Default" end)
- -- Congela corpos mortos (ragdolls)
- for _, plr in ipairs(game.Players:GetPlayers()) do
- if plr.Character and plr.Character:FindFirstChild("Humanoid") then
- local humanoid = plr.Character.Humanoid
- if humanoid.Health <= 0 then
- for _, part in ipairs(plr.Character:GetChildren()) do
- if part:IsA("BasePart") then part.Anchored = true end
- end
- end
- end
- end
- else
- pcall(function() settings().Rendering.ShadowQuality = "Level10" end)
- for _, light in ipairs(workspace:GetDescendants()) do
- if light:IsA("SurfaceLight") or light:IsA("PointLight") or light:IsA("SpotLight") then
- light.Enabled = true
- end
- end
- pcall(function() settings().Rendering.FrameRateManager = "Auto" end)
- end
- end
- -- Monitorar mudanças nas toggles
- local function onAntiLagChanged(val)
- Settings.AntiLag = val
- applyPerformanceChanges()
- save()
- end
- local function onFPSBoostChanged(val)
- Settings.FPSBoost = val
- applyPerformanceChanges()
- save()
- end
- -- Aplicar imediatamente ao ligar o script se já estiver ativo
- applyPerformanceChanges()
- -- ==================== INTERFACE ====================
- local gui = Instance.new("ScreenGui")
- gui.Name = "WLh4xHub"
- gui.Parent = game.CoreGui
- gui.ResetOnSpawn = false
- gui.IgnoreGuiInset = true
- gui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
- local main = Instance.new("Frame")
- main.Size = UDim2.new(0.5, 0, 0.5, 0)
- main.Position = UDim2.new(0.25, 0, 0.25, 0)
- main.BackgroundColor3 = Color3.fromRGB(17, 17, 17)
- main.BorderSizePixel = 0
- main.ClipsDescendants = true
- main.Active = false
- Instance.new("UICorner", main).CornerRadius = UDim.new(0, 8)
- main.Parent = gui
- local topBar = Instance.new("Frame")
- topBar.Size = UDim2.new(1, 0, 0, 32)
- topBar.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
- topBar.BorderSizePixel = 0
- topBar.Active = true
- topBar.Parent = main
- local title = Instance.new("TextLabel")
- title.Text = "WLh4x Hub"
- title.Size = UDim2.new(0.5, 0, 1, 0)
- title.Position = UDim2.new(0.02, 0, 0, 0)
- title.BackgroundTransparency = 1
- title.TextColor3 = Color3.fromRGB(255, 40, 40)
- title.Font = Enum.Font.GothamBold
- title.TextSize = 16
- title.TextXAlignment = Enum.TextXAlignment.Left
- title.Parent = topBar
- -- Arrastar
- local dragging, dragStart, startPos
- topBar.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- dragging = true
- dragStart = input.Position
- startPos = main.Position
- input.Changed:Connect(function()
- if input.UserInputState == Enum.UserInputState.End then dragging = false end
- end)
- end
- end)
- topBar.InputChanged:Connect(function(input)
- if dragging and (input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch) then
- local delta = input.Position - dragStart
- main.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y)
- end
- end)
- -- Botões
- local minBtn = Instance.new("TextButton")
- minBtn.Text = "_"
- minBtn.Size = UDim2.new(0, 30, 0, 30)
- minBtn.Position = UDim2.new(1, -65, 0, 0)
- minBtn.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- minBtn.TextColor3 = Color3.fromRGB(255, 255, 255)
- minBtn.Font = Enum.Font.GothamBold; minBtn.TextSize = 18; minBtn.BorderSizePixel = 0
- Instance.new("UICorner", minBtn).CornerRadius = UDim.new(0, 6)
- minBtn.Parent = topBar
- local closeBtn = Instance.new("TextButton")
- closeBtn.Text = "X"
- closeBtn.Size = UDim2.new(0, 30, 0, 30)
- closeBtn.Position = UDim2.new(1, -30, 0, 0)
- closeBtn.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
- closeBtn.TextColor3 = Color3.fromRGB(255, 255, 255)
- closeBtn.Font = Enum.Font.GothamBold; closeBtn.TextSize = 16; closeBtn.BorderSizePixel = 0
- Instance.new("UICorner", closeBtn).CornerRadius = UDim.new(0, 6)
- closeBtn.Parent = topBar
- closeBtn.MouseButton1Click:Connect(function()
- gui:Destroy()
- if fovCircle then fovCircle:Remove() end
- end)
- -- Botão flutuante
- local floatBtn = Instance.new("TextButton")
- floatBtn.Text = "WL"
- floatBtn.Size = UDim2.new(0, 40, 0, 40)
- floatBtn.Position = UDim2.new(1, -50, 0, 10)
- floatBtn.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
- floatBtn.BorderColor3 = Color3.fromRGB(255, 0, 0); floatBtn.BorderSizePixel = 2
- floatBtn.TextColor3 = Color3.fromRGB(255, 0, 0)
- floatBtn.Font = Enum.Font.GothamBold; floatBtn.TextSize = 18
- floatBtn.Visible = false
- floatBtn.Draggable = true
- floatBtn.Active = true
- floatBtn.Parent = gui
- local minimized = false
- minBtn.MouseButton1Click:Connect(function()
- minimized = true; main.Visible = false; floatBtn.Visible = true
- end)
- floatBtn.MouseButton1Click:Connect(function()
- minimized = false; main.Visible = true; floatBtn.Visible = false
- end)
- UIS.InputBegan:Connect(function(input, gpe)
- if gpe then return end
- if input.KeyCode == Settings.ToggleKey then
- minimized = not minimized
- main.Visible = not minimized
- floatBtn.Visible = minimized
- end
- end)
- -- Abas
- local tabFrame = Instance.new("Frame")
- tabFrame.Size = UDim2.new(1, 0, 0, 30)
- tabFrame.Position = UDim2.new(0, 0, 0, 32)
- tabFrame.BackgroundTransparency = 1
- tabFrame.Active = false
- tabFrame.Parent = main
- local combatTab = Instance.new("TextButton")
- combatTab.Text = "Combate"; combatTab.Size = UDim2.new(0.5, -2, 1, 0)
- combatTab.Position = UDim2.new(0, 0, 0, 0)
- combatTab.BackgroundColor3 = Color3.fromRGB(255, 0, 0); combatTab.TextColor3 = Color3.fromRGB(255,255,255)
- combatTab.Font = Enum.Font.GothamBold; combatTab.TextSize = 14; combatTab.BorderSizePixel = 0
- Instance.new("UICorner", combatTab).CornerRadius = UDim.new(0, 6)
- combatTab.Parent = tabFrame
- local configTab = Instance.new("TextButton")
- configTab.Text = "Configurações"; configTab.Size = UDim2.new(0.5, -2, 1, 0)
- configTab.Position = UDim2.new(0.5, 2, 0, 0)
- configTab.BackgroundColor3 = Color3.fromRGB(40, 40, 40); configTab.TextColor3 = Color3.fromRGB(255,255,255)
- configTab.Font = Enum.Font.GothamBold; configTab.TextSize = 14; configTab.BorderSizePixel = 0
- Instance.new("UICorner", configTab).CornerRadius = UDim.new(0, 6)
- configTab.Parent = tabFrame
- local combatContent = Instance.new("ScrollingFrame")
- combatContent.Size = UDim2.new(1, -10, 1, -67)
- combatContent.Position = UDim2.new(0, 5, 0, 67)
- combatContent.BackgroundTransparency = 1
- combatContent.ScrollBarThickness = 4
- combatContent.ScrollBarImageColor3 = Color3.fromRGB(255, 0, 0)
- combatContent.CanvasSize = UDim2.new(0, 0, 0, 700)
- combatContent.Active = false
- combatContent.Visible = true
- combatContent.Parent = main
- local configContent = Instance.new("ScrollingFrame")
- configContent.Size = UDim2.new(1, -10, 1, -67)
- configContent.Position = UDim2.new(0, 5, 0, 67)
- configContent.BackgroundTransparency = 1
- configContent.ScrollBarThickness = 4
- configContent.ScrollBarImageColor3 = Color3.fromRGB(255, 0, 0)
- configContent.CanvasSize = UDim2.new(0, 0, 0, 600)
- configContent.Active = false
- configContent.Visible = false
- configContent.Parent = main
- combatTab.MouseButton1Click:Connect(function()
- combatTab.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
- configTab.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- combatContent.Visible = true; configContent.Visible = false
- end)
- configTab.MouseButton1Click:Connect(function()
- configTab.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
- combatTab.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- configContent.Visible = true; combatContent.Visible = false
- end)
- local function createToggle(parent, text, default, callback, yPos)
- local frame = Instance.new("Frame")
- frame.Size = UDim2.new(1, -10, 0, 32)
- frame.Position = UDim2.new(0, 5, 0, yPos)
- frame.BackgroundColor3 = Color3.fromRGB(28, 28, 28)
- frame.BorderSizePixel = 0
- frame.Active = false
- Instance.new("UICorner", frame).CornerRadius = UDim.new(0, 6)
- frame.Parent = parent
- local label = Instance.new("TextLabel")
- label.Text = text; label.Size = UDim2.new(0.65, 0, 1, 0)
- label.BackgroundTransparency = 1; label.TextColor3 = Color3.fromRGB(240, 240, 240)
- label.Font = Enum.Font.Gotham; label.TextSize = 13; label.TextXAlignment = Enum.TextXAlignment.Left
- label.Parent = frame
- local btn = Instance.new("TextButton")
- btn.Size = UDim2.new(0, 40, 0, 20); btn.Position = UDim2.new(0.75, 10, 0.5, -10)
- btn.BackgroundColor3 = Color3.fromRGB(100, 100, 100); btn.BorderSizePixel = 0; btn.Text = ""
- Instance.new("UICorner", btn).CornerRadius = UDim.new(1, 0)
- btn.Parent = frame
- local ball = Instance.new("Frame")
- ball.Size = UDim2.new(0, 16, 0, 16); ball.Position = UDim2.new(0, 2, 0.5, -8)
- ball.BackgroundColor3 = Color3.fromRGB(255, 255, 255); ball.BorderSizePixel = 0
- Instance.new("UICorner", ball).CornerRadius = UDim.new(1, 0)
- ball.Parent = btn
- local active = default
- local function update()
- if active then
- btn.BackgroundColor3 = Color3.fromRGB(0, 200, 0)
- ball:TweenPosition(UDim2.new(1, -18, 0.5, -8), "In", "Linear", 0.15)
- else
- btn.BackgroundColor3 = Color3.fromRGB(100, 100, 100)
- ball:TweenPosition(UDim2.new(0, 2, 0.5, -8), "In", "Linear", 0.15)
- end
- end
- update()
- btn.MouseButton1Click:Connect(function()
- active = not active; update(); callback(active)
- end)
- return frame
- end
- -- ==================== PREENCHER COMBATE ====================
- local y = 0
- createToggle(combatContent, "Aimbot", Settings.Aimbot, function(v) Settings.Aimbot = v save() end, y)
- y = y + 37
- -- Slider Smoothness
- local smoothFrame = Instance.new("Frame")
- smoothFrame.Size = UDim2.new(1, -10, 0, 32)
- smoothFrame.Position = UDim2.new(0, 5, 0, y)
- smoothFrame.BackgroundColor3 = Color3.fromRGB(28, 28, 28)
- smoothFrame.BorderSizePixel = 0
- Instance.new("UICorner", smoothFrame).CornerRadius = UDim.new(0, 6)
- smoothFrame.Parent = combatContent
- local smoothLabel = Instance.new("TextLabel")
- smoothLabel.Text = "Smoothness: " .. string.format("%.1f", Settings.Smoothness)
- smoothLabel.Size = UDim2.new(0.4, 0, 1, 0); smoothLabel.BackgroundTransparency = 1
- smoothLabel.TextColor3 = Color3.fromRGB(240, 240, 240); smoothLabel.Font = Enum.Font.Gotham; smoothLabel.TextSize = 13; smoothLabel.TextXAlignment = Enum.TextXAlignment.Left
- smoothLabel.Parent = smoothFrame
- local smoothSliderFrame = Instance.new("Frame")
- smoothSliderFrame.Size = UDim2.new(0.5, 0, 0.6, 0)
- smoothSliderFrame.Position = UDim2.new(0.45, 0, 0.2, 0)
- smoothSliderFrame.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
- smoothSliderFrame.BorderSizePixel = 0
- Instance.new("UICorner", smoothSliderFrame).CornerRadius = UDim.new(0, 4)
- smoothSliderFrame.Parent = smoothFrame
- local smoothFill = Instance.new("Frame")
- smoothFill.Size = UDim2.new(Settings.Smoothness, 0, 1, 0)
- smoothFill.BackgroundColor3 = Color3.fromRGB(255, 0, 0); smoothFill.BorderSizePixel = 0
- Instance.new("UICorner", smoothFill).CornerRadius = UDim.new(0, 4)
- smoothFill.Parent = smoothSliderFrame
- local smoothKnob = Instance.new("TextButton")
- smoothKnob.Size = UDim2.new(0, 16, 0, 16)
- smoothKnob.Position = UDim2.new(Settings.Smoothness, -8, 0.5, -8)
- smoothKnob.BackgroundColor3 = Color3.fromRGB(255, 255, 255); smoothKnob.BorderSizePixel = 0; smoothKnob.Text = ""
- Instance.new("UICorner", smoothKnob).CornerRadius = UDim.new(1, 0)
- smoothKnob.Parent = smoothSliderFrame
- local function updateSmoothSlider(percent)
- local val = math.clamp(percent, 0.1, 1.0)
- Settings.Smoothness = val
- smoothLabel.Text = "Smoothness: " .. string.format("%.1f", val)
- smoothFill.Size = UDim2.new(val, 0, 1, 0)
- smoothKnob.Position = UDim2.new(val, -8, 0.5, -8)
- save()
- end
- local draggingSmooth = false
- smoothKnob.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- draggingSmooth = true
- end
- end)
- smoothKnob.InputEnded:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- draggingSmooth = false
- end
- end)
- smoothSliderFrame.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- local pos = input.Position.X - smoothSliderFrame.AbsolutePosition.X
- local perc = math.clamp(pos / smoothSliderFrame.AbsoluteSize.X, 0, 1)
- updateSmoothSlider(perc)
- draggingSmooth = true
- end
- end)
- smoothSliderFrame.InputEnded:Connect(function(input)
- draggingSmooth = false
- end)
- UIS.InputChanged:Connect(function(input)
- if draggingSmooth and (input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch) then
- local pos = input.Position.X - smoothSliderFrame.AbsolutePosition.X
- local perc = math.clamp(pos / smoothSliderFrame.AbsoluteSize.X, 0, 1)
- updateSmoothSlider(perc)
- end
- end)
- y = y + 37
- createToggle(combatContent, "FOV Circle", Settings.FOVCircle, function(v) Settings.FOVCircle = v updateFOV() save() end, y)
- y = y + 37
- -- Slider FOV
- local fovFrame = Instance.new("Frame")
- fovFrame.Size = UDim2.new(1, -10, 0, 32)
- fovFrame.Position = UDim2.new(0, 5, 0, y)
- fovFrame.BackgroundColor3 = Color3.fromRGB(28, 28, 28)
- fovFrame.BorderSizePixel = 0
- Instance.new("UICorner", fovFrame).CornerRadius = UDim.new(0, 6)
- fovFrame.Parent = combatContent
- local fovLabel = Instance.new("TextLabel")
- fovLabel.Text = "FOV Size: " .. Settings.FOV
- fovLabel.Size = UDim2.new(0.4, 0, 1, 0); fovLabel.BackgroundTransparency = 1
- fovLabel.TextColor3 = Color3.fromRGB(240, 240, 240); fovLabel.Font = Enum.Font.Gotham; fovLabel.TextSize = 13; fovLabel.TextXAlignment = Enum.TextXAlignment.Left
- fovLabel.Parent = fovFrame
- local fovSliderFrame = Instance.new("Frame")
- fovSliderFrame.Size = UDim2.new(0.5, 0, 0.6, 0)
- fovSliderFrame.Position = UDim2.new(0.45, 0, 0.2, 0)
- fovSliderFrame.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
- fovSliderFrame.BorderSizePixel = 0
- Instance.new("UICorner", fovSliderFrame).CornerRadius = UDim.new(0, 4)
- fovSliderFrame.Parent = fovFrame
- local fovFill = Instance.new("Frame")
- fovFill.Size = UDim2.new((Settings.FOV - 50) / 200, 0, 1, 0)
- fovFill.BackgroundColor3 = Color3.fromRGB(255, 0, 0); fovFill.BorderSizePixel = 0
- Instance.new("UICorner", fovFill).CornerRadius = UDim.new(0, 4)
- fovFill.Parent = fovSliderFrame
- local fovKnob = Instance.new("TextButton")
- fovKnob.Size = UDim2.new(0, 16, 0, 16)
- fovKnob.Position = UDim2.new((Settings.FOV - 50) / 200, -8, 0.5, -8)
- fovKnob.BackgroundColor3 = Color3.fromRGB(255, 255, 255); fovKnob.BorderSizePixel = 0; fovKnob.Text = ""
- Instance.new("UICorner", fovKnob).CornerRadius = UDim.new(1, 0)
- fovKnob.Parent = fovSliderFrame
- local function updateFovSlider(percent)
- local val = math.floor(50 + percent * 200)
- Settings.FOV = val
- fovLabel.Text = "FOV Size: " .. val
- fovFill.Size = UDim2.new(percent, 0, 1, 0)
- fovKnob.Position = UDim2.new(percent, -8, 0.5, -8)
- if Settings.FOVCircle then updateFOV() end
- save()
- end
- local draggingFov = false
- fovKnob.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- draggingFov = true
- end
- end)
- fovKnob.InputEnded:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- draggingFov = false
- end
- end)
- fovSliderFrame.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- local pos = input.Position.X - fovSliderFrame.AbsolutePosition.X
- local perc = math.clamp(pos / fovSliderFrame.AbsoluteSize.X, 0, 1)
- updateFovSlider(perc)
- draggingFov = true
- end
- end)
- fovSliderFrame.InputEnded:Connect(function(input)
- draggingFov = false
- end)
- UIS.InputChanged:Connect(function(input)
- if draggingFov and (input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch) then
- local pos = input.Position.X - fovSliderFrame.AbsolutePosition.X
- local perc = math.clamp(pos / fovSliderFrame.AbsoluteSize.X, 0, 1)
- updateFovSlider(perc)
- end
- end)
- y = y + 37
- createToggle(combatContent, "Trigger Bot", Settings.TriggerBot, function(v) Settings.TriggerBot = v save() end, y)
- y = y + 37
- createToggle(combatContent, "Silent Aim", Settings.SilentAim, function(v) Settings.SilentAim = v save() end, y)
- y = y + 37
- createToggle(combatContent, "No Recoil", Settings.NoRecoil, function(v) Settings.NoRecoil = v save() end, y)
- y = y + 37
- createToggle(combatContent, "No Spread", Settings.NoSpread, onNoSpreadChanged, y)
- y = y + 37
- createToggle(combatContent, "Hitbox Expand", Settings.HitboxExpand, function(v)
- Settings.HitboxExpand = v
- for _, p in ipairs(game.Players:GetPlayers()) do
- if p ~= player and p.Character then expandHitbox(p.Character) end
- end
- save()
- end, y)
- y = y + 37
- -- ==================== PREENCHER CONFIGURAÇÕES ====================
- y = 0
- createToggle(configContent, "Box ESP", Settings.BoxESP, function(v)
- Settings.BoxESP = v
- for _, data in pairs(ESPObjects) do
- if data.drawings.box then data.drawings.box.Visible = v end
- if data.drawings.name then data.drawings.name.Visible = v end
- if data.drawings.weapon then data.drawings.weapon.Visible = v end
- if data.drawings.dist then data.drawings.dist.Visible = v end
- if data.drawings.hpBar then data.drawings.hpBar.Visible = v end
- if data.drawings.hpBg then data.drawings.hpBg.Visible = v end
- end
- save()
- end, y)
- y = y + 37
- createToggle(configContent, "Line ESP", Settings.LineESP, function(v)
- Settings.LineESP = v
- for _, data in pairs(ESPObjects) do
- if data.drawings.line then data.drawings.line.Visible = v end
- end
- save()
- end, y)
- y = y + 37
- createToggle(configContent, "Skeleton ESP", Settings.SkeletonESP, function(v)
- Settings.SkeletonESP = v
- for _, data in pairs(ESPObjects) do
- if data.drawings.skeletonLines then
- for _, sk in ipairs(data.drawings.skeletonLines) do sk.line.Visible = v end
- end
- end
- save()
- end, y)
- y = y + 37
- createToggle(configContent, "Anti Lag", Settings.AntiLag, onAntiLagChanged, y)
- y = y + 37
- createToggle(configContent, "FPS Booster", Settings.FPSBoost, onFPSBoostChanged, y)
- y = y + 37
- -- Tecla de atalho
- local keyFrame = Instance.new("Frame")
- keyFrame.Size = UDim2.new(1, -10, 0, 32)
- keyFrame.Position = UDim2.new(0, 5, 0, y)
- keyFrame.BackgroundColor3 = Color3.fromRGB(28, 28, 28)
- keyFrame.BorderSizePixel = 0
- Instance.new("UICorner", keyFrame).CornerRadius = UDim.new(0, 6)
- keyFrame.Parent = configContent
- local keyLabel = Instance.new("TextLabel")
- keyLabel.Text = "Toggle Key"; keyLabel.Size = UDim2.new(0.6, 0, 1, 0)
- keyLabel.BackgroundTransparency = 1; keyLabel.TextColor3 = Color3.fromRGB(240, 240, 240)
- keyLabel.Font = Enum.Font.Gotham; keyLabel.TextSize = 13; keyLabel.TextXAlignment = Enum.TextXAlignment.Left
- keyLabel.Parent = keyFrame
- local keyBtn = Instance.new("TextButton")
- keyBtn.Size = UDim2.new(0, 100, 0, 24); keyBtn.Position = UDim2.new(0.65, 10, 0.5, -12)
- keyBtn.BackgroundColor3 = Color3.fromRGB(50, 50, 50); keyBtn.TextColor3 = Color3.fromRGB(255, 255, 255)
- keyBtn.Font = Enum.Font.Gotham; keyBtn.TextSize = 13; keyBtn.Text = Settings.ToggleKey.Name
- keyBtn.BorderSizePixel = 0
- Instance.new("UICorner", keyBtn).CornerRadius = UDim.new(0, 6)
- keyBtn.Parent = keyFrame
- keyBtn.MouseButton1Click:Connect(function()
- keyBtn.Text = "..."
- local conn
- conn = UIS.InputBegan:Connect(function(input, gpe)
- if gpe then return end
- if input.UserInputType == Enum.UserInputType.Keyboard then
- Settings.ToggleKey = input.KeyCode
- keyBtn.Text = input.KeyCode.Name
- save()
- conn:Disconnect()
- end
- end)
- end)
- y = y + 37
- -- Salvar
- local saveBtn = Instance.new("TextButton")
- saveBtn.Size = UDim2.new(1, -10, 0, 32)
- saveBtn.Position = UDim2.new(0, 5, 0, y)
- saveBtn.BackgroundColor3 = Color3.fromRGB(255, 0, 0); saveBtn.TextColor3 = Color3.fromRGB(255, 255, 255)
- saveBtn.Font = Enum.Font.GothamBold; saveBtn.TextSize = 14; saveBtn.Text = "Salvar Configurações"
- saveBtn.BorderSizePixel = 0
- Instance.new("UICorner", saveBtn).CornerRadius = UDim.new(0, 6)
- saveBtn.Parent = configContent
- saveBtn.MouseButton1Click:Connect(function()
- save()
- StarterGui:SetCore("SendNotification", {Title = "WLh4x Hub", Text = "Configurações salvas!", Duration = 2})
- end)
- -- Animação
- main.BackgroundTransparency = 1
- main.Size = UDim2.new(0, 0, 0, 0)
- main.Position = UDim2.new(0.5, 0, 0.5, 0)
- local info = TweenInfo.new(0.5, Enum.EasingStyle.Back, Enum.EasingDirection.Out)
- local goalSize = UDim2.new(0.5, 0, 0.5, 0)
- local goalPos = UDim2.new(0.25, 0, 0.25, 0)
- local tween = TweenService:Create(main, info, {Size = goalSize, Position = goalPos, BackgroundTransparency = 0})
- tween:Play()
- StarterGui:SetCore("SendNotification", {Title = "WLh4x Hub", Text = "Welcome to WLh4x Hub", Duration = 3})
- updateFOV()
Advertisement
Add Comment
Please, Sign In to add comment