-- [[ Rscripts Risk Notice ]] -- This script is not verified by rscripts.net. Deal with caution. -- -- Stay safe: -- • Never log in on unofficial Roblox sites or lookalike domains. -- • Real Roblox links use roblox.com (check the .com ending). -- • Treat fake Roblox login / "claim reward" pages as phishing. -- [[ End Rscripts Risk Notice ]] --============================================================= -- Apocalypse Rising 2 | aimbot + esp + fullbright + bullet tracers + no fog --============================================================= -- ESKI INSTANCE TEMIZLE (2. inject'te cift menu / acilmama yapar) pcall(function() if _G.ZG_Cheat and type(_G.ZG_Cheat.terminate) == "function" then _G.ZG_Cheat.terminate() end end) pcall(function() local _LP = game:GetService("Players").LocalPlayer local function killIn(parent) if not parent then return end local old = parent:FindFirstChild("ZG_Cheat") if old then pcall(function() old:Destroy() end) end end killIn(_LP:FindFirstChildOfClass("PlayerGui")) pcall(function() killIn(game:GetService("CoreGui")) end) local okH, hui = pcall(gethui) if okH and hui then killIn(hui) end local okH2, h2 = pcall(function() return get_hidden_gui and get_hidden_gui() end) if okH2 and h2 then killIn(h2) end end) task.wait(0.05) local Players = game:GetService("Players") local RunService = game:GetService("RunService") local UserInputService = game:GetService("UserInputService") local Lighting = game:GetService("Lighting") local LP = Players.LocalPlayer local Camera = workspace.CurrentCamera local IGNORED_PLAYER_NAMES = { ["Not a Player lol"] = true } local gui = nil --============================================================= -- EXECUTOR FUNCTIONS --============================================================= local EX = { mousemoverel = (function() local ok, v = pcall(function() return mousemoverel end) return ok and type(v) == "function" and v or nil end)(), gethui = (function() local ok, v = pcall(function() return gethui end) return ok and type(v) == "function" and v or nil end)(), getgenv = (function() local ok, v = pcall(function() return getgenv end) return ok and type(v) == "function" and v or nil end)(), hookmetamethod = (function() local ok, v = pcall(function() return hookmetamethod end) return ok and type(v) == "function" and v or nil end)(), getnamecallmethod = (function() local ok, v = pcall(function() return getnamecallmethod end) return ok and type(v) == "function" and v or nil end)(), } local HAS_DRAWING = false pcall(function() local t = Drawing.new("Text") t.Visible = false pcall(function() t:Remove() end) HAS_DRAWING = true end) local HAS_HOOK = (EX.hookmetamethod ~= nil and EX.getnamecallmethod ~= nil) --============================================================= -- CONFIG --============================================================= local Config = { aimbot = { enabled = false, keybind = Enum.UserInputType.MouseButton2, targetKind = "Zombies", fov = 150, smoothness = 4, targetPart = "Head", visibleOnly = false, showFov = true, }, bulletTracers = { enabled = false, thickness = 1.5, lifetime = 0.5, }, playerESP = { enabled = false, box = true, name = true, health = true, distance = true, maxDist = 5000, }, mobESP = { enabled = true, box = true, name = true, health = true, distance = true, maxDist = 5000, }, visuals = { fullbright = false, noFog = false, }, customization = { accentColor = Color3.fromRGB(150, 85, 235), accent2Color = Color3.fromRGB(180, 120, 255), fovColor = Color3.fromRGB(150, 85, 235), tracerColor = Color3.fromRGB(150, 85, 235), }, world = { charactersFolder = "Characters", zombiesFolder = "Zombies", }, ui = { toggleKey = Enum.KeyCode.Home, }, } if not HAS_DRAWING then Config.playerESP.enabled = false Config.mobESP.enabled = false Config.aimbot.showFov = false Config.bulletTracers.enabled = false end local PLAYER_TARGET_PARTS = { "Head", "HumanoidRootPart", "UpperTorso", "Torso", "Left Arm", "Right Arm", "LeftUpperArm", "RightUpperArm", } local MIN_BOX_W = 10 local MIN_BOX_H = 16 --============================================================= -- FULLBRIGHT & NO FOG HANDLER --============================================================= local origLighting = { Brightness = Lighting.Brightness, ClockTime = Lighting.ClockTime, FogEnd = Lighting.FogEnd, FogStart = Lighting.FogStart, GlobalShadows = Lighting.GlobalShadows, Ambient = Lighting.Ambient, OutdoorAmbient = Lighting.OutdoorAmbient, } local fbWasOn = false local noFogWasOn = false local function applyFullbright() Lighting.Brightness = 2 Lighting.ClockTime = 14 if not Config.visuals.noFog then Lighting.FogEnd = 100000 end Lighting.GlobalShadows = false Lighting.Ambient = Color3.fromRGB(255, 255, 255) Lighting.OutdoorAmbient = Color3.fromRGB(255, 255, 255) end local function restoreLighting() pcall(function() Lighting.Brightness = origLighting.Brightness Lighting.ClockTime = origLighting.ClockTime if not Config.visuals.noFog then Lighting.FogEnd = origLighting.FogEnd end Lighting.GlobalShadows = origLighting.GlobalShadows Lighting.Ambient = origLighting.Ambient Lighting.OutdoorAmbient = origLighting.OutdoorAmbient end) end local function updateFullbright() if Config.visuals.fullbright then if not fbWasOn then origLighting.Brightness = Lighting.Brightness origLighting.ClockTime = Lighting.ClockTime origLighting.FogEnd = Lighting.FogEnd origLighting.GlobalShadows = Lighting.GlobalShadows origLighting.Ambient = Lighting.Ambient origLighting.OutdoorAmbient = Lighting.OutdoorAmbient fbWasOn = true end applyFullbright() elseif fbWasOn then restoreLighting() fbWasOn = false end end local function applyNoFog() Lighting.FogEnd = 999999999 pcall(function() Lighting.FogStart = 0 end) end local function restoreFog() pcall(function() Lighting.FogEnd = origLighting.FogEnd Lighting.FogStart = origLighting.FogStart end) end local function updateNoFog() if Config.visuals.noFog then if not noFogWasOn then origLighting.FogEnd = Lighting.FogEnd pcall(function() origLighting.FogStart = Lighting.FogStart end) noFogWasOn = true end applyNoFog() elseif noFogWasOn then restoreFog() noFogWasOn = false end end --============================================================= -- COLORS --============================================================= local COL = { bg = Color3.fromRGB(16, 12, 22), panel = Color3.fromRGB(22, 16, 30), panel2 = Color3.fromRGB(30, 22, 40), header = Color3.fromRGB(26, 18, 36), gray = Color3.fromRGB(70, 62, 88), text = Color3.fromRGB(232, 226, 245), dim = Color3.fromRGB(155, 145, 175), ok = Color3.fromRGB(120, 210, 150), danger = Color3.fromRGB(215, 70, 100), pEsp = Color3.fromRGB(180, 120, 255), mEsp = Color3.fromRGB(230, 90, 90), tracer = Color3.fromRGB(200, 140, 255), scroll = Color3.fromRGB(140, 100, 210), warn = Color3.fromRGB(230, 190, 100), } --============================================================= -- GUI PARENT --============================================================= local GUI_PARENT = (function() if EX.gethui then local ok, hui = pcall(EX.gethui) if ok and hui then return hui end end local ok, h2 = pcall(function() return get_hidden_gui and get_hidden_gui() end) if ok and h2 then return h2 end local ok2, cg = pcall(function() return game:GetService("CoreGui") end) if ok2 and cg then local ok3 = pcall(function() local t = Instance.new("ScreenGui") t.Name = "__zg_test" t.Parent = cg t:Destroy() end) if ok3 then return cg end end local pg = LP:FindFirstChildOfClass("PlayerGui") if pg then return pg end return LP:WaitForChild("PlayerGui", 5) or LP:FindFirstChildOfClass("PlayerGui") end)() --============================================================= -- HELPERS --============================================================= local function isIgnoredPlayer(plr) return IGNORED_PLAYER_NAMES[plr.Name] == true end local function getRealPlayers() local out = {} for _, plr in ipairs(Players:GetPlayers()) do if plr ~= nil and not isIgnoredPlayer(plr) then out[#out + 1] = plr end end return out end local function findPlayerCharacterRaw(plr) if plr.Character and plr.Character.Parent then return plr.Character, "plr.Character" end local chars = workspace:FindFirstChild(Config.world.charactersFolder) if not chars then return nil, nil end local direct = chars:FindFirstChild(plr.Name) if direct then local inner = direct:FindFirstChild("StarterCharacter") if inner then return inner, "Characters[Name].StarterCharacter" end return direct, "Characters[Name]" end local byId = chars:FindFirstChild(tostring(plr.UserId)) if byId then local inner = byId:FindFirstChild("StarterCharacter") if inner then return inner, "Characters[UserId].StarterCharacter" end return byId, "Characters[UserId]" end for _, d in ipairs(chars:GetDescendants()) do if d.Name == "StarterCharacter" and d:IsA("Model") then local attrP = d:GetAttribute("Player") local attrO = d:GetAttribute("Owner") if attrP == plr or attrP == plr.Name or attrP == plr.UserId or attrO == plr or attrO == plr.Name or attrO == plr.UserId then return d, "attr match" end local vP = d:FindFirstChild("Player") local vO = d:FindFirstChild("Owner") if (vP and vP:IsA("ObjectValue") and vP.Value == plr) or (vO and vO:IsA("ObjectValue") and vO.Value == plr) then return d, "ObjectValue match" end end end return nil, nil end local charCache = {} local function findPlayerCharacter(plr) local now = os.clock() local e = charCache[plr] if e and now < e.exp then local c = e.char if c and c.Parent and c:IsDescendantOf(workspace) then return c, e.how end end local c, how = findPlayerCharacterRaw(plr) charCache[plr] = { char = c, how = how, exp = now + 1 } return c, how end Players.PlayerRemoving:Connect(function(plr) charCache[plr] = nil end) LP.CharacterAdded:Connect(function() for k in pairs(charCache) do charCache[k] = nil end end) local zombiesFolderCache = nil local zombiesFolderExp = 0 local function getZombiesFolder() local now = os.clock() if zombiesFolderCache and zombiesFolderCache.Parent and now < zombiesFolderExp then return zombiesFolderCache end zombiesFolderCache = workspace:FindFirstChild(Config.world.zombiesFolder) zombiesFolderExp = now + 2 return zombiesFolderCache end local function getMobs() local folder = getZombiesFolder() if not folder then return {} end local out = {} for _, child in ipairs(folder:GetChildren()) do if child:IsA("Model") then out[#out + 1] = child end end return out end local function getEntityRoot(char) if not char then return nil end if char:IsA("BasePart") then return char end return char:FindFirstChild("HumanoidRootPart") or char:FindFirstChild("UpperTorso") or char:FindFirstChild("Torso") or char.PrimaryPart end local function getEntityHead(char) if not char then return nil end if char:IsA("BasePart") then return char end return char:FindFirstChild("Head") end local function getEntityHealth(char) if not char then return 100, 100 end local hum = char:FindFirstChildOfClass("Humanoid") if hum then return hum.Health, hum.MaxHealth end local hp = char:FindFirstChild("Health") if hp and hp:IsA("ValueBase") then local mx = char:FindFirstChild("MaxHealth") return tonumber(hp.Value) or 100, (mx and tonumber(mx.Value)) or 100 end return 100, 100 end local function entityIsAlive(e) if not e or not e.Parent then return false end local hum = e:FindFirstChildOfClass("Humanoid") if hum then return hum.Health > 0 end return true end local function getMyRoot() local char = LP.Character if not char then return nil end return char:FindFirstChild("HumanoidRootPart") or char:FindFirstChild("UpperTorso") or char:FindFirstChild("Torso") end local function worldToViewport(pos) local v, onScreen = Camera:WorldToViewportPoint(pos) return Vector2.new(v.X, v.Y), onScreen, v.Z end local visParams = RaycastParams.new() visParams.FilterType = Enum.RaycastFilterType.Exclude local function isVisible(targetPart, ignoreModel) if not targetPart then return false end local origin = Camera.CFrame.Position local dir = targetPart.Position - origin visParams.FilterDescendantsInstances = { LP.Character, ignoreModel, gui } local hit = workspace:Raycast(origin, dir, visParams) return hit == nil end --============================================================= -- UI HELPERS --============================================================= local function make(class, props) local inst = Instance.new(class) for k, v in pairs(props or {}) do if k ~= "Parent" then pcall(function() inst[k] = v end) end end if props and props.Parent then xpcall(function() inst.Parent = props.Parent end, function() end) end return inst end local function corner(parent, r) return make("UICorner", { Parent = parent, CornerRadius = UDim.new(0, r or 6) }) end local function stroke(parent, color, thickness) return make("UIStroke", { Parent = parent, Color = color or COL.gray, Thickness = thickness or 1, ApplyStrokeMode = Enum.ApplyStrokeMode.Border, }) end --============================================================= -- WINDOW --============================================================= gui = make("ScreenGui", { Name = "ZG_Cheat", ResetOnSpawn = false, ZIndexBehavior = Enum.ZIndexBehavior.Sibling, IgnoreGuiInset = true, Parent = GUI_PARENT, }) local window = make("Frame", { Parent = gui, Size = UDim2.new(0, 620, 0, 420), Position = UDim2.new(0.5, -310, 0.5, -210), BackgroundColor3 = COL.bg, BorderSizePixel = 0, Active = true, }) corner(window, 10) stroke(window, COL.gray, 1) local header = make("Frame", { Parent = window, Size = UDim2.new(1, 0, 0, 34), BackgroundColor3 = COL.header, BorderSizePixel = 0, }) corner(header, 10) make("Frame", { Parent = header, Size = UDim2.new(1, 0, 0, 10), Position = UDim2.new(0, 0, 1, -10), BackgroundColor3 = COL.header, BorderSizePixel = 0, }) local closeBtn = make("TextButton", { Parent = header, Size = UDim2.new(0, 22, 0, 22), Position = UDim2.new(0, 8, 0.5, -11), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, Text = "×", TextColor3 = COL.text, Font = Enum.Font.GothamBold, TextSize = 16, AutoButtonColor = false, ZIndex = 5, }) corner(closeBtn, 5) stroke(closeBtn, COL.gray, 1) closeBtn.MouseEnter:Connect(function() closeBtn.BackgroundColor3 = COL.danger end) closeBtn.MouseLeave:Connect(function() closeBtn.BackgroundColor3 = COL.panel2 end) local minBtn = make("TextButton", { Parent = header, Size = UDim2.new(0, 22, 0, 22), Position = UDim2.new(0, 34, 0.5, -11), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, Text = "−", TextColor3 = COL.text, Font = Enum.Font.GothamBold, TextSize = 16, AutoButtonColor = false, ZIndex = 5, }) corner(minBtn, 5) stroke(minBtn, COL.gray, 1) minBtn.MouseEnter:Connect(function() minBtn.BackgroundColor3 = COL.gray end) minBtn.MouseLeave:Connect(function() minBtn.BackgroundColor3 = COL.panel2 end) make("TextLabel", { Parent = header, BackgroundTransparency = 1, Size = UDim2.new(1, -80, 1, 0), Position = UDim2.new(0, 66, 0, 0), Text = "Apocalypse Rising 2", TextColor3 = COL.text, Font = Enum.Font.GothamBold, TextSize = 13, TextXAlignment = Enum.TextXAlignment.Left, }) local sidebar = make("Frame", { Parent = window, Size = UDim2.new(0, 130, 1, -60), Position = UDim2.new(0, 10, 0, 42), BackgroundColor3 = COL.panel, BorderSizePixel = 0, }) corner(sidebar, 8) stroke(sidebar, COL.gray, 1) make("UIListLayout", { Parent = sidebar, Padding = UDim.new(0, 6), SortOrder = Enum.SortOrder.LayoutOrder, HorizontalAlignment = Enum.HorizontalAlignment.Center, }) make("UIPadding", { Parent = sidebar, PaddingTop = UDim.new(0, 10), PaddingLeft = UDim.new(0, 8), PaddingRight = UDim.new(0, 8), }) local content = make("Frame", { Parent = window, Size = UDim2.new(1, -160, 1, -60), Position = UDim2.new(0, 148, 0, 42), BackgroundColor3 = COL.panel, BorderSizePixel = 0, }) corner(content, 8) stroke(content, COL.gray, 1) --============================================================= -- WIDGETS --============================================================= local function newPage(name) local page = make("ScrollingFrame", { Parent = content, Size = UDim2.new(1, -16, 1, -16), Position = UDim2.new(0, 8, 0, 8), BackgroundTransparency = 1, BorderSizePixel = 0, CanvasSize = UDim2.new(0, 0, 0, 0), AutomaticCanvasSize = Enum.AutomaticSize.Y, ScrollingDirection = Enum.ScrollingDirection.Y, ScrollBarThickness = 6, ScrollBarImageColor3 = COL.scroll, ScrollBarImageTransparency = 0.2, ElasticBehavior = Enum.ElasticBehavior.WhenScrollable, Visible = false, Name = name, }) make("UIListLayout", { Parent = page, Padding = UDim.new(0, 8), SortOrder = Enum.SortOrder.LayoutOrder, }) make("UIPadding", { Parent = page, PaddingBottom = UDim.new(0, 12), PaddingRight = UDim.new(0, 4), }) return page end local sectionHolders = {} local function sectionLabel(parent, text, order) local holder = make("Frame", { Parent = parent, Size = UDim2.new(1, 0, 0, 20), BackgroundTransparency = 1, LayoutOrder = order, }) local bar = make("Frame", { Parent = holder, Size = UDim2.new(0, 3, 1, 0), BackgroundColor3 = Config.customization.accentColor, BorderSizePixel = 0, Name = "AccentBar", }) local lbl = make("TextLabel", { Parent = holder, BackgroundTransparency = 1, Size = UDim2.new(1, -12, 1, 0), Position = UDim2.new(0, 10, 0, 0), Text = string.upper(text), TextColor3 = Config.customization.accent2Color, Font = Enum.Font.GothamBold, TextSize = 11, TextXAlignment = Enum.TextXAlignment.Left, Name = "AccentText", }) table.insert(sectionHolders, { bar = bar, lbl = lbl }) return holder end local function noteLabel(parent, text, order, color) local lbl = make("TextLabel", { Parent = parent, Size = UDim2.new(1, 0, 0, 0), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, AutomaticSize = Enum.AutomaticSize.Y, Text = " " .. text, TextColor3 = color or COL.warn, Font = Enum.Font.Code, TextSize = 11, TextXAlignment = Enum.TextXAlignment.Left, TextWrapped = true, LayoutOrder = order, }) make("UIPadding", { Parent = lbl, PaddingTop = UDim.new(0, 6), PaddingBottom = UDim.new(0, 6), PaddingLeft = UDim.new(0, 4), PaddingRight = UDim.new(0, 4), }) corner(lbl, 5) stroke(lbl, COL.gray, 1) return lbl end local toggleTracks = {} local function toggle(parent, label, default, order, onChange) local state = default or false local row = make("Frame", { Parent = parent, Size = UDim2.new(1, 0, 0, 28), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, LayoutOrder = order, }) corner(row, 5) stroke(row, COL.gray, 1) make("TextLabel", { Parent = row, BackgroundTransparency = 1, Size = UDim2.new(1, -60, 1, 0), Position = UDim2.new(0, 10, 0, 0), Text = label, TextColor3 = COL.text, Font = Enum.Font.Gotham, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Left, }) local track = make("Frame", { Parent = row, Size = UDim2.new(0, 36, 0, 18), Position = UDim2.new(1, -46, 0.5, -9), BackgroundColor3 = COL.gray, BorderSizePixel = 0, Name = "Track", }) corner(track, 9) local knob = make("Frame", { Parent = track, Size = UDim2.new(0, 14, 0, 14), Position = UDim2.new(0, 2, 0.5, -7), BackgroundColor3 = COL.text, BorderSizePixel = 0, }) corner(knob, 7) local btn = make("TextButton", { Parent = row, Size = UDim2.new(1, 0, 1, 0), BackgroundTransparency = 1, Text = "", }) local function apply() if state then track.BackgroundColor3 = Config.customization.accentColor knob.Position = UDim2.new(1, -16, 0.5, -7) else track.BackgroundColor3 = COL.gray knob.Position = UDim2.new(0, 2, 0.5, -7) end end apply() table.insert(toggleTracks, { track = track, get = function() return state end, apply = apply }) btn.MouseButton1Click:Connect(function() state = not state apply() if onChange then onChange(state) end end) return { set = function(v) state = v; apply(); if onChange then onChange(v) end end, get = function() return state end, } end local sliderFills = {} local function slider(parent, label, min, max, default, order, onChange) local value = default local row = make("Frame", { Parent = parent, Size = UDim2.new(1, 0, 0, 44), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, LayoutOrder = order, }) corner(row, 5) stroke(row, COL.gray, 1) make("TextLabel", { Parent = row, BackgroundTransparency = 1, Size = UDim2.new(1, -80, 0, 20), Position = UDim2.new(0, 10, 0, 2), Text = label, TextColor3 = COL.text, Font = Enum.Font.Gotham, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Left, }) local valLabel = make("TextLabel", { Parent = row, BackgroundTransparency = 1, Size = UDim2.new(0, 70, 0, 20), Position = UDim2.new(1, -80, 0, 2), Text = tostring(value), TextColor3 = Config.customization.accent2Color, Font = Enum.Font.GothamBold, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Right, Name = "ValueLabel", }) local track = make("Frame", { Parent = row, Size = UDim2.new(1, -20, 0, 4), Position = UDim2.new(0, 10, 0, 30), BackgroundColor3 = COL.gray, BorderSizePixel = 0, }) corner(track, 2) local fill = make("Frame", { Parent = track, Size = UDim2.new(0, 0, 1, 0), BackgroundColor3 = Config.customization.accentColor, BorderSizePixel = 0, Name = "Fill", }) corner(fill, 2) table.insert(sliderFills, fill) local knob = make("Frame", { Parent = track, Size = UDim2.new(0, 12, 0, 12), Position = UDim2.new(0, -6, 0.5, -6), BackgroundColor3 = COL.text, BorderSizePixel = 0, ZIndex = 2, }) corner(knob, 6) local function setValue(v, fire) v = math.clamp(v, min, max) value = v local a = (v - min) / (max - min) fill.Size = UDim2.new(a, 0, 1, 0) knob.Position = UDim2.new(a, -6, 0.5, -6) valLabel.Text = tostring(math.floor(v * 100 + 0.5) / 100) if fire and onChange then onChange(v) end end setValue(default, false) local dragging = false local hit = make("TextButton", { Parent = track, Size = UDim2.new(1, 0, 3, 0), Position = UDim2.new(0, 0, -1, 0), BackgroundTransparency = 1, Text = "", }) local function up(input) local rel = math.clamp( (input.Position.X - track.AbsolutePosition.X) / track.AbsoluteSize.X, 0, 1) setValue(min + rel * (max - min), true) end hit.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then dragging = true up(input) end end) UserInputService.InputChanged:Connect(function(input) if dragging and (input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch) then up(input) end end) UserInputService.InputEnded:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then dragging = false end end) return { set = function(v) setValue(v, true) end, get = function() return value end, } end local dropdownStrokes = {} local function dropdown(parent, label, options, default, order, onChange) local value = default or options[1] local open = false local HEAD_H, ITEM_H, ITEM_GAP, PAD = 28, 20, 2, 6 local fullH = #options * ITEM_H + math.max(0, #options - 1) * ITEM_GAP + PAD * 2 local MAX_LIST_H = 6 * ITEM_H + 5 * ITEM_GAP + PAD * 2 local listH = math.min(fullH, MAX_LIST_H) local LIST_GAP = 6 local holder = make("Frame", { Parent = parent, Size = UDim2.new(1, 0, 0, HEAD_H), BackgroundTransparency = 1, LayoutOrder = order, ClipsDescendants = false, }) local head = make("Frame", { Parent = holder, Size = UDim2.new(1, 0, 0, HEAD_H), Position = UDim2.new(0, 0, 0, 0), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, }) corner(head, 5) stroke(head, COL.gray, 1) make("TextLabel", { Parent = head, BackgroundTransparency = 1, Size = UDim2.new(1, -90, 1, 0), Position = UDim2.new(0, 10, 0, 0), Text = label, TextColor3 = COL.text, Font = Enum.Font.Gotham, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Left, }) local valLabel = make("TextLabel", { Parent = head, BackgroundTransparency = 1, Size = UDim2.new(0, 80, 1, 0), Position = UDim2.new(1, -80, 0, 0), Text = tostring(value) .. " v", TextColor3 = Config.customization.accent2Color, Font = Enum.Font.GothamMedium, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Right, Name = "ValLabel", }) local list = make("ScrollingFrame", { Parent = holder, Size = UDim2.new(1, 0, 0, listH), Position = UDim2.new(0, 0, 0, HEAD_H + LIST_GAP), BackgroundColor3 = COL.bg, BorderSizePixel = 0, Visible = false, CanvasSize = UDim2.new(0, 0, 0, 0), AutomaticCanvasSize = Enum.AutomaticSize.Y, ScrollingDirection = Enum.ScrollingDirection.Y, ScrollBarThickness = 5, ScrollBarImageColor3 = COL.scroll, ScrollBarImageTransparency = 0.2, ElasticBehavior = Enum.ElasticBehavior.WhenScrollable, ZIndex = 20, }) corner(list, 5) local listStroke = stroke(list, Config.customization.accentColor, 1) table.insert(dropdownStrokes, listStroke) make("UIListLayout", { Parent = list, Padding = UDim.new(0, ITEM_GAP), SortOrder = Enum.SortOrder.LayoutOrder, }) make("UIPadding", { Parent = list, PaddingTop = UDim.new(0, PAD), PaddingBottom = UDim.new(0, PAD), PaddingLeft = UDim.new(0, 4), PaddingRight = UDim.new(0, 4), }) local function setOpen(v) open = v list.Visible = v holder.Size = UDim2.new(1, 0, 0, v and (HEAD_H + LIST_GAP + listH) or HEAD_H) end for i, opt in ipairs(options) do local ob = make("TextButton", { Parent = list, Size = UDim2.new(1, 0, 0, ITEM_H), BackgroundColor3 = COL.panel, BorderSizePixel = 0, Text = opt, TextColor3 = COL.text, Font = Enum.Font.Gotham, TextSize = 11, AutoButtonColor = false, LayoutOrder = i, }) corner(ob, 4) ob.MouseEnter:Connect(function() ob.BackgroundColor3 = COL.panel2 end) ob.MouseLeave:Connect(function() ob.BackgroundColor3 = COL.panel end) ob.MouseButton1Click:Connect(function() value = opt valLabel.Text = tostring(opt) .. " v" setOpen(false) if onChange then onChange(opt) end end) end local btn = make("TextButton", { Parent = head, Size = UDim2.new(1, 0, 1, 0), BackgroundTransparency = 1, Text = "", }) btn.MouseButton1Click:Connect(function() setOpen(not open) end) return { set = function(v) value = v valLabel.Text = tostring(v) .. " v" if onChange then onChange(v) end end, get = function() return value end, } end local activeNavButtons = {} local function navButton(text, order, onClick) local btn = make("TextButton", { Parent = sidebar, Size = UDim2.new(1, 0, 0, 30), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, Text = text, TextColor3 = COL.text, Font = Enum.Font.GothamMedium, TextSize = 12, AutoButtonColor = false, LayoutOrder = order, }) corner(btn, 5) stroke(btn, COL.gray, 1) table.insert(activeNavButtons, btn) btn.MouseEnter:Connect(function() btn.BackgroundColor3 = COL.gray end) btn.MouseLeave:Connect(function() if not btn:GetAttribute("active") then btn.BackgroundColor3 = COL.panel2 end end) btn.MouseButton1Click:Connect(function() onClick(btn) end) return btn end local function actionButton(parent, label, order, color, hoverColor, onClick) local btn = make("TextButton", { Parent = parent, Size = UDim2.new(1, 0, 0, 30), BackgroundColor3 = color or COL.panel2, BorderSizePixel = 0, Text = label, TextColor3 = COL.text, Font = Enum.Font.GothamMedium, TextSize = 12, AutoButtonColor = false, LayoutOrder = order, }) corner(btn, 5) stroke(btn, COL.gray, 1) local base = color or COL.panel2 local hover = hoverColor or COL.gray btn.MouseEnter:Connect(function() btn.BackgroundColor3 = hover end) btn.MouseLeave:Connect(function() btn.BackgroundColor3 = base end) btn.MouseButton1Click:Connect(function() local ok, err = pcall(onClick) if not ok then warn("[ZG] " + tostring(err)) end end) return btn end --============================================================= -- PAGES --============================================================= local pageAim = newPage("Aimbot") local pageVisuals = newPage("Visuals") local pageCustom = newPage("Customization") local pageSettings = newPage("Settings") local allPages = { pageAim, pageVisuals, pageCustom, pageSettings } local navButtons = {} local function showPage(page, btn) for _, p in ipairs(allPages) do p.Visible = (p == page) end for _, b in ipairs(navButtons) do b:SetAttribute("active", false) b.BackgroundColor3 = COL.panel2 end if btn then btn:SetAttribute("active", true) btn.BackgroundColor3 = Config.customization.accentColor end end -- Tema Güncelleme Fonksiyonu local function updateThemeColors() local acc = Config.customization.accentColor local acc2 = Config.customization.accent2Color for _, b in ipairs(navButtons) do if b:GetAttribute("active") then b.BackgroundColor3 = acc end end for _, item in ipairs(sectionHolders) do if item.bar then item.bar.BackgroundColor3 = acc end if item.lbl then item.lbl.TextColor3 = acc2 end end for _, t in ipairs(toggleTracks) do if t.get() then t.track.BackgroundColor3 = acc end end for _, fill in ipairs(sliderFills) do fill.BackgroundColor3 = acc end for _, ds in ipairs(dropdownStrokes) do ds.Color = acc end end --============================================================= -- NAVIGATION --============================================================= navButtons[1] = navButton("Combat", 1, function(b) showPage(pageAim, b) end) navButtons[2] = navButton("Visuals", 2, function(b) showPage(pageVisuals, b) end) navButtons[3] = navButton("Theme", 3, function(b) showPage(pageCustom, b) end) navButtons[4] = navButton("Settings", 4, function(b) showPage(pageSettings, b) end) --============================================================= -- AIMBOT PAGE (Combat) --============================================================= sectionLabel(pageAim, "Combat", 1) toggle(pageAim, "Enable Aimbot", Config.aimbot.enabled, 2, function(v) Config.aimbot.enabled = v end) dropdown(pageAim, "Targets", { "Players", "Zombies", "Both" }, Config.aimbot.targetKind, 3, function(v) Config.aimbot.targetKind = v end) toggle(pageAim, "Visible Only (Wall Check)", Config.aimbot.visibleOnly, 4, function(v) Config.aimbot.visibleOnly = v end) toggle(pageAim, "Show FOV Circle", Config.aimbot.showFov, 5, function(v) Config.aimbot.showFov = v end) slider(pageAim, "FOV Radius", 20, 800, Config.aimbot.fov, 6, function(v) Config.aimbot.fov = v end) slider(pageAim, "Smoothness", 1, 20, Config.aimbot.smoothness, 7, function(v) Config.aimbot.smoothness = v end) dropdown(pageAim, "Aim Part", PLAYER_TARGET_PARTS, Config.aimbot.targetPart, 8, function(v) Config.aimbot.targetPart = v end) if not EX.mousemoverel then noteLabel(pageAim, "mousemoverel bulunamadi: aimbot calismaz, executor degistir.", 9, COL.danger) end --============================================================= -- BULLET TRACERS (Combat Page) --============================================================= sectionLabel(pageAim, "Bullet Tracers", 10) toggle(pageAim, "Enable Bullet Tracers", Config.bulletTracers.enabled, 11, function(v) Config.bulletTracers.enabled = (HAS_DRAWING and HAS_HOOK) and v or false end) slider(pageAim, "Tracer Lifetime", 0.1, 3, Config.bulletTracers.lifetime, 12, function(v) Config.bulletTracers.lifetime = v end) slider(pageAim, "Tracer Thickness", 0.5, 5, Config.bulletTracers.thickness, 13, function(v) Config.bulletTracers.thickness = v end) if not HAS_DRAWING then noteLabel(pageAim, "Drawing API yok: Bullet Tracers bu executorda calismaz.", 14, COL.danger) elseif not HAS_HOOK then noteLabel(pageAim, "hookmetamethod/getnamecallmethod yok: Tracers calismaz. Xeno, Synapse, Fluxus vb. kullan.", 14, COL.danger) end --============================================================= -- VISUALS PAGE --============================================================= sectionLabel(pageVisuals, "World", 1) toggle(pageVisuals, "Fullbright", Config.visuals.fullbright, 2, function(v) Config.visuals.fullbright = v updateFullbright() end) toggle(pageVisuals, "No Fog", Config.visuals.noFog, 3, function(v) Config.visuals.noFog = v updateNoFog() end) sectionLabel(pageVisuals, "Player ESP", 4) if not HAS_DRAWING then noteLabel(pageVisuals, "Drawing API yok: ESP bu executorda calismaz, menu yine acilir.", 5, COL.danger) end toggle(pageVisuals, "Enable Player ESP", Config.playerESP.enabled, 6, function(v) Config.playerESP.enabled = HAS_DRAWING and v or false end) toggle(pageVisuals, "Player Box", Config.playerESP.box, 7, function(v) Config.playerESP.box = v end) toggle(pageVisuals, "Player Name", Config.playerESP.name, 8, function(v) Config.playerESP.name = v end) toggle(pageVisuals, "Player Health", Config.playerESP.health, 9, function(v) Config.playerESP.health = v end) toggle(pageVisuals, "Player Distance", Config.playerESP.distance, 10, function(v) Config.playerESP.distance = v end) slider(pageVisuals, "Player Max Distance", 100, 20000, Config.playerESP.maxDist, 11, function(v) Config.playerESP.maxDist = v end) sectionLabel(pageVisuals, "Mob ESP", 12) toggle(pageVisuals, "Enable Mob ESP", Config.mobESP.enabled, 13, function(v) Config.mobESP.enabled = HAS_DRAWING and v or false end) toggle(pageVisuals, "Mob Box", Config.mobESP.box, 14, function(v) Config.mobESP.box = v end) toggle(pageVisuals, "Mob Name", Config.mobESP.name, 15, function(v) Config.mobESP.name = v end) toggle(pageVisuals, "Mob Health", Config.mobESP.health, 16, function(v) Config.mobESP.health = v end) toggle(pageVisuals, "Mob Distance", Config.mobESP.distance, 17, function(v) Config.mobESP.distance = v end) slider(pageVisuals, "Mob Max Distance", 100, 20000, Config.mobESP.maxDist, 18, function(v) Config.mobESP.maxDist = v end) --============================================================= -- CUSTOMIZATION (THEME & FOV COLOR & TRACER COLOR) PAGE --============================================================= sectionLabel(pageCustom, "Theme Customization", 1) dropdown(pageCustom, "GUI Accent Color", { "Purple", "Blue", "Green", "Red", "Orange", "Pink" }, "Purple", 2, function(v) if v == "Purple" then Config.customization.accentColor = Color3.fromRGB(150, 85, 235) Config.customization.accent2Color = Color3.fromRGB(180, 120, 255) elseif v == "Blue" then Config.customization.accentColor = Color3.fromRGB(85, 130, 235) Config.customization.accent2Color = Color3.fromRGB(120, 165, 255) elseif v == "Green" then Config.customization.accentColor = Color3.fromRGB(85, 200, 120) Config.customization.accent2Color = Color3.fromRGB(120, 235, 155) elseif v == "Red" then Config.customization.accentColor = Color3.fromRGB(220, 70, 70) Config.customization.accent2Color = Color3.fromRGB(255, 110, 110) elseif v == "Orange" then Config.customization.accentColor = Color3.fromRGB(235, 140, 60) Config.customization.accent2Color = Color3.fromRGB(255, 175, 95) elseif v == "Pink" then Config.customization.accentColor = Color3.fromRGB(235, 85, 180) Config.customization.accent2Color = Color3.fromRGB(255, 120, 210) end updateThemeColors() end) sectionLabel(pageCustom, "Aimbot FOV Color", 3) dropdown(pageCustom, "FOV Circle Color", { "Purple", "Blue", "Green", "Red", "Orange", "Pink", "White" }, "Purple", 4, function(v) if v == "Purple" then Config.customization.fovColor = Color3.fromRGB(150, 85, 235) elseif v == "Blue" then Config.customization.fovColor = Color3.fromRGB(85, 130, 235) elseif v == "Green" then Config.customization.fovColor = Color3.fromRGB(85, 200, 120) elseif v == "Red" then Config.customization.fovColor = Color3.fromRGB(220, 70, 70) elseif v == "Orange" then Config.customization.fovColor = Color3.fromRGB(235, 140, 60) elseif v == "Pink" then Config.customization.fovColor = Color3.fromRGB(235, 85, 180) elseif v == "White" then Config.customization.fovColor = Color3.fromRGB(255, 255, 255) end end) sectionLabel(pageCustom, "Bullet Tracer Color", 5) dropdown(pageCustom, "Tracer Color", { "Purple", "Blue", "Green", "Red", "Orange", "Pink", "White", "Cyan", "Yellow" }, "Purple", 6, function(v) if v == "Purple" then Config.customization.tracerColor = Color3.fromRGB(150, 85, 235) elseif v == "Blue" then Config.customization.tracerColor = Color3.fromRGB(85, 130, 235) elseif v == "Green" then Config.customization.tracerColor = Color3.fromRGB(85, 200, 120) elseif v == "Red" then Config.customization.tracerColor = Color3.fromRGB(220, 70, 70) elseif v == "Orange" then Config.customization.tracerColor = Color3.fromRGB(235, 140, 60) elseif v == "Pink" then Config.customization.tracerColor = Color3.fromRGB(235, 85, 180) elseif v == "White" then Config.customization.tracerColor = Color3.fromRGB(255, 255, 255) elseif v == "Cyan" then Config.customization.tracerColor = Color3.fromRGB(85, 220, 235) elseif v == "Yellow" then Config.customization.tracerColor = Color3.fromRGB(235, 220, 85) end end) --============================================================= -- SETTINGS PAGE --============================================================= sectionLabel(pageSettings, "Menu Keybind", 1) local kbRow = make("Frame", { Parent = pageSettings, Size = UDim2.new(1, 0, 0, 28), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, LayoutOrder = 2, }) corner(kbRow, 5) stroke(kbRow, COL.gray, 1) make("TextLabel", { Parent = kbRow, BackgroundTransparency = 1, Size = UDim2.new(1, -120, 1, 0), Position = UDim2.new(0, 10, 0, 0), Text = "Toggle Menu", TextColor3 = COL.text, Font = Enum.Font.Gotham, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Left, }) local kbValueLabel = make("TextLabel", { Parent = kbRow, BackgroundTransparency = 1, Size = UDim2.new(0, 110, 1, 0), Position = UDim2.new(1, -118, 0, 0), Text = Config.ui.toggleKey.Name, TextColor3 = Config.customization.accent2Color, Font = Enum.Font.GothamBold, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Right, }) local kbBtn = make("TextButton", { Parent = kbRow, Size = UDim2.new(1, 0, 1, 0), BackgroundTransparency = 1, Text = "", }) local awaitingKey = false kbBtn.MouseButton1Click:Connect(function() awaitingKey = true kbValueLabel.Text = "press a key..." kbValueLabel.TextColor3 = COL.dim end) sectionLabel(pageSettings, "Diagnostics", 3) local debugLbl = make("TextLabel", { Parent = pageSettings, Size = UDim2.new(1, 0, 0, 0), BackgroundColor3 = COL.panel2, BorderSizePixel = 0, AutomaticSize = Enum.AutomaticSize.Y, Text = " Click Debug Lookup to scan player -> character mapping.", TextColor3 = COL.dim, Font = Enum.Font.Code, TextSize = 11, TextXAlignment = Enum.TextXAlignment.Left, TextWrapped = true, LayoutOrder = 5, }) make("UIPadding", { Parent = debugLbl, PaddingTop = UDim.new(0, 8), PaddingBottom = UDim.new(0, 8), PaddingLeft = UDim.new(0, 4), PaddingRight = UDim.new(0, 4), }) corner(debugLbl, 5) stroke(debugLbl, COL.gray, 1) actionButton(pageSettings, "Debug Lookup", 4, COL.accent, COL.accent2, function() local lines = {} lines[#lines + 1] = ("Players: %d | Drawing: %s | mousemoverel: %s | hook: %s"):format( #Players:GetPlayers(), HAS_DRAWING and "OK" or "YOK", EX.mousemoverel and "OK" or "YOK", HAS_HOOK and "OK" or "YOK") for _, plr in ipairs(Players:GetPlayers()) do local ignored = isIgnoredPlayer(plr) and " [IGNORED]" or "" local c, how = findPlayerCharacterRaw(plr) lines[#lines + 1] = (" %s%s"):format(plr.Name, ignored) lines[#lines + 1] = (" -> %s"):format( c and (c:GetFullName() .. " [" .. tostring(how) .. "]") or "MISSING") end local chars = workspace:FindFirstChild(Config.world.charactersFolder) lines[#lines + 1] = "" lines[#lines + 1] = ("workspace.%s: %s"):format( Config.world.charactersFolder, chars and "found" or "MISSING") if chars then local kids = chars:GetChildren() lines[#lines + 1] = (" children: %d"):format(#kids) for i = 1, math.min(#kids, 10) do lines[#lines + 1] = (" %d. %s [%s]"):format( i, kids[i].Name, kids[i].ClassName) end if #kids > 10 then lines[#lines + 1] = " ..." end end local zombies = workspace:FindFirstChild(Config.world.zombiesFolder) lines[#lines + 1] = "" lines[#lines + 1] = ("workspace.%s: %s"):format( Config.world.zombiesFolder, zombies and "found" or "MISSING") if zombies then local kids = zombies:GetChildren() lines[#lines + 1] = (" children: %d"):format(#kids) for i = 1, math.min(#kids, 5) do lines[#lines + 1] = (" %d. %s [%s]"):format( i, kids[i].Name, kids[i].ClassName) end if #kids > 5 then lines[#lines + 1] = " ..." end end debugLbl.Text = " " .. table.concat(lines, "\n ") debugLbl.TextColor3 = COL.text end) --============================================================= -- MENU VISIBILITY --============================================================= local function setMenuVisible(v) if window and window.Parent then window.Visible = v end end local function setToggleKey(keyCode) Config.ui.toggleKey = keyCode kbValueLabel.Text = keyCode.Name kbValueLabel.TextColor3 = Config.customization.accent2Color end minBtn.MouseButton1Click:Connect(function() setMenuVisible(false) end) UserInputService.InputBegan:Connect(function(input, gpe) if gpe then return end if awaitingKey then if input.UserInputType == Enum.UserInputType.Keyboard then awaitingKey = false setToggleKey(input.KeyCode) end return end if input.UserInputType == Enum.UserInputType.Keyboard and input.KeyCode == Config.ui.toggleKey then local isOpen = window and window.Visible setMenuVisible(not isOpen) end end) --============================================================= -- DRAG --============================================================= do local dragging, dragStart, startPos = false, nil, nil header.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then dragging = true dragStart = input.Position startPos = window.Position end end) UserInputService.InputEnded:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then dragging = false end end) UserInputService.InputChanged:Connect(function(input) if not dragging then return end if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then local d = input.Position - dragStart window.Position = UDim2.new( startPos.X.Scale, startPos.X.Offset + d.X, startPos.Y.Scale, startPos.Y.Offset + d.Y) end end) end --============================================================= -- DRAWINGS (korumali) --============================================================= local Drawings = { fov = nil, players = {}, mobs = {}, } local function newText(size, color) local t = Drawing.new("Text") t.Size = size or 13 t.Center = true t.Outline = true t.Color = color or COL.text t.Font = 2 t.Visible = false return t end local function newBox(color) local b = Drawing.new("Square") b.Thickness = 1.5 b.Filled = false b.Color = color b.Transparency = 1 b.Visible = false return b end if HAS_DRAWING then local ok, err = pcall(function() local fov = Drawing.new("Circle") fov.Thickness = 1.5 fov.NumSides = 64 fov.Filled = false fov.Color = Config.customization.fovColor fov.Transparency = 0.9 fov.Visible = false Drawings.fov = fov end) if not ok then HAS_DRAWING = false Config.playerESP.enabled = false Config.mobESP.enabled = false Config.bulletTracers.enabled = false warn("[ZG] Drawing FOV kurulamadi: " .. tostring(err)) end end local function ensureSet(bucket, key, boxColor) if not HAS_DRAWING then return nil end local set = bucket[key] if set then return set end local ok, res = pcall(function() local s = { box = newBox(boxColor), name = newText(14, boxColor), hp = newText(13, COL.ok), dist = newText(13, COL.dim), } s.hp.Center = false return s end) if not ok or not res then return nil end bucket[key] = res return res end local function hideSet(set) if not set then return end pcall(function() set.box.Visible = false set.name.Visible = false set.hp.Visible = false set.dist.Visible = false end) end local function removeSet(set) if not set then return end for _, k in ipairs({ "box", "name", "hp", "dist" }) do pcall(function() set[k]:Remove() end) end end --============================================================= -- BULLET TRACER SYSTEM (hookmetamethod __namecall -> Raycast) --============================================================= local activeTracerLines = {} -- { line, startWorld, endWorld, born } local oldNamecall = nil -- orijinal __namecall (unhook icin) local tracerHookActive = false local function spawnTracerLine(origin, direction) if not HAS_DRAWING then return end if not Config.bulletTracers.enabled then return end local hitPos = origin + direction local screenFrom, fromOn = worldToViewport(origin) local screenTo, toOn = worldToViewport(hitPos) if not (fromOn or toOn) then return end local ok, line = pcall(function() local l = Drawing.new("Line") l.From = screenFrom l.To = screenTo l.Color = Config.customization.tracerColor l.Thickness = Config.bulletTracers.thickness l.Transparency = 1 l.Visible = true return l end) if ok and line then table.insert(activeTracerLines, { line = line, startWorld = origin, endWorld = hitPos, born = os.clock(), }) end end local function setupTracerHook() if not HAS_HOOK then return end if not HAS_DRAWING then return end if tracerHookActive then return end local hookOk, result = pcall(function() return EX.hookmetamethod(game, "__namecall", newcclosure(function(self, ...) local method = EX.getnamecallmethod() local args = { ... } if self == workspace and method == "Raycast" then local origin = args[1] local direction = args[2] if Config.bulletTracers.enabled and typeof(origin) == "Vector3" and typeof(direction) == "Vector3" and direction.Magnitude > 5 then task.spawn(spawnTracerLine, origin, direction) end end return oldNamecall(self, ...) end)) end) if hookOk and result then oldNamecall = result tracerHookActive = true print("[ZG] Bullet Tracer hook kuruldu (workspace:Raycast)") else warn("[ZG] Tracer hook kurulamadi: " .. tostring(result)) end end local function removeTracerHook() if not tracerHookActive then return end if oldNamecall then pcall(function() EX.hookmetamethod(game, "__namecall", oldNamecall) end) end tracerHookActive = false oldNamecall = nil end local function updateTracerLines() if not HAS_DRAWING then return end local now = os.clock() local lifetime = Config.bulletTracers.lifetime local i = 1 while i <= #activeTracerLines do local t = activeTracerLines[i] local age = now - t.born if age >= lifetime then pcall(function() t.line:Remove() end) table.remove(activeTracerLines, i) else local alpha = 1 - (age / lifetime) pcall(function() local fromScreen, fromOn = worldToViewport(t.startWorld) local toScreen, toOn = worldToViewport(t.endWorld) t.line.From = fromScreen t.line.To = toScreen t.line.Transparency = alpha t.line.Color = Config.customization.tracerColor t.line.Thickness = Config.bulletTracers.thickness t.line.Visible = (fromOn or toOn) end) i = i + 1 end end end local function clearAllTracers() for _, t in ipairs(activeTracerLines) do pcall(function() t.line:Remove() end) end activeTracerLines = {} end setupTracerHook() --============================================================= -- DRAW HELPER --============================================================= local function drawEntity(set, char, label, cfg, myRootPos, color) if not set then return end local root = getEntityRoot(char) if not root then hideSet(set) return end local dist = 0 if myRootPos then dist = (myRootPos - root.Position).Magnitude end if cfg.maxDist and dist > cfg.maxDist then hideSet(set) return end local head = getEntityHead(char) if not head then hideSet(set) return end local headScreen, headOn = worldToViewport(head.Position + Vector3.new(0, 0.6, 0)) local footScreen, footOn = worldToViewport(root.Position - Vector3.new(0, 2.6, 0)) if not (headOn or footOn) then hideSet(set) return end if cfg.box then local topY = math.min(headScreen.Y, footScreen.Y) local bottomY = math.max(headScreen.Y, footScreen.Y) local h = bottomY - topY local w = h * 0.55 local cx = (headScreen.X + footScreen.X) / 2 if h < MIN_BOX_H then h = MIN_BOX_H end if w < MIN_BOX_W then w = MIN_BOX_W end set.box.Size = Vector2.new(w, h) set.box.Position = Vector2.new(cx - w / 2, topY) set.box.Visible = true else set.box.Visible = false end local visualTop = set.box.Visible and set.box.Position.Y or (headScreen.Y - MIN_BOX_H / 2) local visualBottom = visualTop + (set.box.Visible and set.box.Size.Y or MIN_BOX_H) if cfg.name then set.name.Position = Vector2.new(headScreen.X, visualTop - 18) set.name.Text = label set.name.Color = color set.name.Visible = true else set.name.Visible = false end if cfg.health then local cur, mx = getEntityHealth(char) local pct = math.clamp(cur / math.max(1, mx), 0, 1) set.hp.Position = Vector2.new(headScreen.X + 34, visualTop) set.hp.Text = string.format("%d", math.floor(cur + 0.5)) set.hp.Color = Color3.fromRGB( math.floor(255 * (1 - pct)), math.floor(255 * pct), 90) set.hp.Visible = true else set.hp.Visible = false end if cfg.distance then set.dist.Position = Vector2.new(headScreen.X, visualBottom + 4) set.dist.Text = string.format("[%d]", math.floor(dist)) set.dist.Visible = true else set.dist.Visible = false end end --============================================================= -- AIMBOT --============================================================= local aimHeld = false UserInputService.InputBegan:Connect(function(input, gpe) if gpe then return end if input.UserInputType == Config.aimbot.keybind then aimHeld = true end end) UserInputService.InputEnded:Connect(function(input) if input.UserInputType == Config.aimbot.keybind then aimHeld = false end end) local function findBestTarget() if not Config.aimbot.enabled or not aimHeld then return nil end local mouse = UserInputService:GetMouseLocation() local best, bestDist = nil, math.huge local fov = Config.aimbot.fov local kind = Config.aimbot.targetKind local partName = Config.aimbot.targetPart local function consider(entity) local hum = entity:FindFirstChildOfClass("Humanoid") if hum and hum.Health <= 0 then return end local part = entity:FindFirstChild(partName) or entity:FindFirstChild("Head") or entity:FindFirstChild("HumanoidRootPart") if not part then return end if Config.aimbot.visibleOnly and not isVisible(part, entity) then return end local sp, onScreen = worldToViewport(part.Position) if not onScreen then return end local d = (sp - mouse).Magnitude if d <= fov and d < bestDist then bestDist = d best = { part = part, screen = sp } end end if kind == "Players" or kind == "Both" then for _, plr in ipairs(getRealPlayers()) do if plr ~= LP then local c = findPlayerCharacter(plr) if c and entityIsAlive(c) then consider(c) end end end end if kind == "Zombies" or kind == "Both" then for _, z in ipairs(getMobs()) do if entityIsAlive(z) then consider(z) end end end return best end --============================================================= -- MAIN LOOP --============================================================= local renderConn local frame = 0 renderConn = RunService.RenderStepped:Connect(function(dt) if not gui or not gui.Parent then return end frame = frame + 1 updateFullbright() updateNoFog() local mouse = UserInputService:GetMouseLocation() if HAS_DRAWING and Drawings.fov then Drawings.fov.Position = mouse Drawings.fov.Radius = Config.aimbot.fov Drawings.fov.Color = Config.customization.fovColor Drawings.fov.Visible = Config.aimbot.showFov and Config.aimbot.enabled end local target = findBestTarget() if target and EX.mousemoverel then local dx = target.screen.X - mouse.X local dy = target.screen.Y - mouse.Y local smooth = math.max(1, Config.aimbot.smoothness) if math.abs(dx) > 0.5 or math.abs(dy) > 0.5 then pcall(EX.mousemoverel, dx / smooth, dy / smooth) end end if HAS_DRAWING and Config.bulletTracers.enabled then updateTracerLines() elseif #activeTracerLines > 0 then clearAllTracers() end if not HAS_DRAWING then return end if frame % 2 ~= 0 then return end local myRoot = getMyRoot() local myPos = myRoot and myRoot.Position or nil if Config.playerESP.enabled then local seen = {} for _, plr in ipairs(getRealPlayers()) do if plr == LP then hideSet(Drawings.players[plr]) else local c = findPlayerCharacter(plr) if c and entityIsAlive(c) then seen[plr] = true local set = ensureSet(Drawings.players, plr, COL.pEsp) if set then drawEntity(set, c, plr.Name, Config.playerESP, myPos, COL.pEsp) end else hideSet(Drawings.players[plr]) end end end for plr, set in pairs(Drawings.players) do if not seen[plr] then hideSet(set) end end else for _, set in pairs(Drawings.players) do hideSet(set) end end if Config.mobESP.enabled then local seen = {} for _, z in ipairs(getMobs()) do if entityIsAlive(z) then seen[z] = true local set = ensureSet(Drawings.mobs, z, COL.mEsp) if set then drawEntity(set, z, z.Name, Config.mobESP, myPos, COL.mEsp) end else hideSet(Drawings.mobs[z]) end end for z, set in pairs(Drawings.mobs) do if not seen[z] then hideSet(set) if not z.Parent then removeSet(set) Drawings.mobs[z] = nil end end end else for _, set in pairs(Drawings.mobs) do hideSet(set) end end end) Players.PlayerRemoving:Connect(function(plr) local set = Drawings.players[plr] if set then removeSet(set) Drawings.players[plr] = nil end end) --============================================================= -- TERMINATE --============================================================= local terminated = false local function terminate() if terminated then return end terminated = true if renderConn then renderConn:Disconnect() end removeTracerHook() clearAllTracers() if fbWasOn then restoreLighting() fbWasOn = false end if noFogWasOn then restoreFog() noFogWasOn = false end for _, set in pairs(Drawings.players) do removeSet(set) end Drawings.players = {} for _, set in pairs(Drawings.mobs) do removeSet(set) end Drawings.mobs = {} pcall(function() Drawings.fov:Remove() end) if gui then pcall(function() gui:Destroy() end) end gui = nil _G.ZG_Cheat = nil if EX.getgenv then local ok, env = pcall(EX.getgenv) if ok and env then env.ZG_Cheat = nil end end print("[ZG_Cheat] terminated.") end closeBtn.MouseButton1Click:Connect(terminate) --============================================================= -- BOOT --============================================================= showPage(pageAim, navButtons[1]) _G.ZG_Cheat = { Config = Config, terminate = terminate } if EX.getgenv then local ok, env = pcall(EX.getgenv) if ok and env then env.ZG_Cheat = _G.ZG_Cheat end end print("[ZG] loaded. Drawing:", HAS_DRAWING and "OK" or "YOK", "| Hook:", HAS_HOOK and "OK" or "YOK", "| Tracers:", (HAS_DRAWING and HAS_HOOK) and "HAZIR" or "DEVRE DISI")