local Rayfield = loadstring(game:HttpGet('https://[Log in to view URL]'))()
local executor = identifyexecutor and identifyexecutor() or "Unknown Executor"

local customTheme = {
   TextColor = Color3.fromRGB(255, 255, 255),
   Background = Color3.fromRGB(0, 0, 0),
   Topbar = Color3.fromRGB(0, 0, 0),
   Shadow = Color3.fromRGB(0, 0, 0),
   NotificationBackground = Color3.fromRGB(0, 0, 0),
   NotificationActionsBackground = Color3.fromRGB(0, 0, 0),
   TabBackground = Color3.fromRGB(0, 0, 0),
   TabStroke = Color3.fromRGB(0, 0, 0),
   TabBackgroundSelected = Color3.fromRGB(0, 0, 0),
   TabTextColor = Color3.fromRGB(255, 255, 255),
   SelectedTabTextColor = Color3.fromRGB(255, 255, 255),
   ElementBackground = Color3.fromRGB(0, 0, 0),
   ElementBackgroundHover = Color3.fromRGB(0, 0, 0),
   SecondaryElementBackground = Color3.fromRGB(0, 0, 0),
   ElementStroke = Color3.fromRGB(0, 0, 0),
   SecondaryElementStroke = Color3.fromRGB(0, 0, 0),
   SliderBackground = Color3.fromRGB(0, 0, 0),
   SliderProgress = Color3.fromRGB(255, 0, 0),
   SliderStroke = Color3.fromRGB(0, 0, 0),
   ToggleBackground = Color3.fromRGB(0, 0, 0),
   ToggleEnabled = Color3.fromRGB(255, 0, 0),
   ToggleDisabled = Color3.fromRGB(60, 60, 60),
   ToggleEnabledStroke = Color3.fromRGB(0, 0, 0),
   ToggleDisabledStroke = Color3.fromRGB(0, 0, 0),
   ToggleEnabledOuterStroke = Color3.fromRGB(0, 0, 0),
   ToggleDisabledOuterStroke = Color3.fromRGB(0, 0, 0),
   DropdownSelected = Color3.fromRGB(0, 0, 0),
   DropdownUnselected = Color3.fromRGB(0, 0, 0),
   InputBackground = Color3.fromRGB(0, 0, 0),
   InputStroke = Color3.fromRGB(0, 0, 0),
   PlaceholderColor = Color3.fromRGB(255, 0, 0),
   KeyInputBackground = Color3.fromRGB(0, 0, 0),
   KeyInputTextColor = Color3.fromRGB(255, 255, 255)
}



local Window = Rayfield:CreateWindow({
   Name = "X-Dk V2 | Tha Bronx | " .. executor,
   Icon = nil,
   LoadingTitle = "",
   LoadingSubtitle = "",
   Theme = customTheme,
   DisableRayfieldPrompts = false,
   DisableBuildWarnings = false,
   ConfigurationSaving = {
      Enabled = false,
      FolderName = "GreenBlackThemeHub",
      FileName = "BigHub"
   },
   Discord = {
      Enabled = false,
      Invite = "",
      RememberJoins = true
   },
   KeySystem = false,
   KeySettings = {
      Title = "",
      Subtitle = "Authentication Required",
      Note = "Get your key at: discord.gg/dkshub",
      FileName = "jc_hub_key",
      SaveKey = true,
      GrabKeyFromSite = false,
      Key = {""},
      Theme = customTheme
   }
})

local HomeTab = Window:CreateTab("Home", "scan-face")
local HomeSection = HomeTab:CreateSection("Welcome!")


HomeTab:CreateParagraph({Title = "Welcome!", Content = "Thank you for using X-Dk."})

HomeTab:CreateSection("User Information")

local player = game.Players.LocalPlayer
local username = player.Name
HomeTab:CreateLabel("Player: " .. username)

local userId = player.UserId
HomeTab:CreateLabel("User Id: " .. userId)

HomeTab:CreateSection("Game and Executor")

local gameName = game:GetService("MarketplaceService"):GetProductInfo(game.PlaceId).Name
HomeTab:CreateLabel("Game: " .. gameName)

local executor = identifyexecutor and identifyexecutor() or "Unknown Executor"
HomeTab:CreateLabel("Executor: " .. executor)

HomeTab:CreateSection("Hardware")

local function getHWID()
    if syn and syn.request then
        return syn.crypt and syn.crypt.hash or "Synapse HWID Unavailable"
    elseif identifyexecutor and identifyexecutor():lower():find("scriptware") then
        return "ScriptWare HWID is not publicly accessible"
    elseif gethwid then
        return gethwid()
    elseif fluxus and fluxus.gethwid then
        return fluxus.gethwid()
    elseif isexecutorenv and isexecutorenv() then
        return getgenv().KRNL_ID or "KRNL HWID Unavailable"
    end
    return "Not Supported"
end

local hwid = getHWID()
HomeTab:CreateLabel("HWID: " .. hwid)

HomeTab:CreateSection("Date + Time")

local currentDate = os.date("%Y-%m-%d")
HomeTab:CreateLabel("Date: " .. currentDate)

local currentTime = os.date("%H:%M:%S")
HomeTab:CreateLabel("Time: " .. currentTime)

HomeTab:CreateSection("Credits")

HomeTab:CreateButton({
    Name = "Join Discord!", 
    Callback = function()
        if setclipboard then
            setclipboard("https://[Log in to view URL]")
            print("Copied to clipboard!")
        else
            print("Your executor does not support setclipboard.")
        end

        Rayfield:Notify({
            Title = "Link Copied!",
            Content = "The Discord link has been copied to your clipboard.",
            Duration = 8.5
        })
    end,
})

HomeTab:CreateLabel("Credits: XDkdev | Read Bio before @")

local MainTab = Window:CreateTab("Main", "box")
local MainSection1 = MainTab:CreateSection("Dupe")

MainTab:CreateParagraph({
    Title = "Duping Guide",
    Content = "Buy Kool Aid Ingredients then cook in a pot then wait for them to be done then fill pitchers cup then fill. DONT HOLD OUT CUP just press Money Vulnerability then boom you have 990k dirty money. Enjoy!"
})

local player = game.Players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")
local screenGui

-- Create Blackout GUI (full screen)
function createBlackout()
    if screenGui then return end

    screenGui = Instance.new("ScreenGui")
    screenGui.Name = "BlackoutGui"
    screenGui.IgnoreGuiInset = true -- Makes sure it covers entire screen
    screenGui.ResetOnSpawn = false
    screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
    screenGui.Parent = playerGui

    local blackFrame = Instance.new("Frame")
    blackFrame.Name = "BlackFrame"
    blackFrame.Size = UDim2.new(1, 0, 1, 0)
    blackFrame.Position = UDim2.new(0, 0, 0, 0)
    blackFrame.BackgroundColor3 = Color3.new(0, 0, 0)
    blackFrame.BackgroundTransparency = 0
    blackFrame.BorderSizePixel = 0
    blackFrame.ZIndex = 1
    blackFrame.Parent = screenGui

    local label = Instance.new("TextLabel")
    label.Name = "BlackoutLabel"
    label.Size = UDim2.new(1, 0, 1, 0)
    label.Position = UDim2.new(0, 0, 0, 0)
    label.BackgroundTransparency = 1
    label.Text = "#1 Undetected DKHub"
    label.TextColor3 = Color3.new(1, 0, 0)
    label.TextStrokeTransparency = 0
    label.Font = Enum.Font.GothamBold
    label.TextScaled = true
    label.ZIndex = 2
    label.Parent = blackFrame
end

-- Destroy Blackout GUI
function destroyBlackout()
    if screenGui then
        screenGui:Destroy()
        screenGui = nil
    end
end

-- Teleport with blackout
function teleport(x, y, z)
    createBlackout()

    local seat
    local targetPosition = Vector3.new(-1487.578369140625, 251.75901794433594, -408.8100891113281)

    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end

    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end

    local character = player.Character
    local rootPart = character and character:FindFirstChild("HumanoidRootPart")
    local humanoid = character and character:FindFirstChild("Humanoid")

    if seat and rootPart and humanoid then
        local originalPosition = seat.CFrame

        seat.CFrame = rootPart.CFrame
        task.wait(0.6)
        seat:Sit(humanoid)
        task.wait(0.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(1e-27)
        seat.CFrame = CFrame.new(originalPosition.X, originalPosition.Y - 100, originalPosition.Z)
    end

    task.wait(0.5)
    destroyBlackout()
end

-- Check if player has Ice-Fruit Cupz
function checkSell()
    local backpack = player:WaitForChild("Backpack")
    return backpack:FindFirstChild("Ice-Fruit Cupz") ~= nil
end

-- Button Callback
MainTab:CreateButton({
    Name = "Dupe Money / Infinite Money",
    Callback = function()
        local character = player.Character or player.CharacterAdded:Wait()
        local hrp = character:FindFirstChild("HumanoidRootPart")

        if not (character and hrp) then return end

        if not checkSell() then
            Rayfield:Notify({
                Title = "Error",
                Content = "You do not have an Ice-Fruit Cupz!",
                Duration = 5,
                Image = 4483345998,
            })
            return
        end

        local originalCFrame = hrp.CFrame
        local sellPart = workspace:FindFirstChild("IceFruit Sell")
        local sellPrompt = sellPart and sellPart:FindFirstChild("ProximityPrompt")
        if not (sellPart and sellPrompt) then return end

        player.Character.Humanoid:EquipTool(player.Backpack:FindFirstChild("Ice-Fruit Cupz"))

        teleport(sellPart.Position.X, sellPart.Position.Y, sellPart.Position.Z)
        task.wait(0.2)

        for _ = 1, 2000 do
            pcall(function()
                fireproximityprompt(sellPrompt, 0)
            end)
        end

        task.wait(1)
        teleport(originalCFrame.Position.X, originalCFrame.Position.Y, originalCFrame.Position.Z)

        Rayfield:Notify({
            Title = "Success!",
            Content = "Your dirty money has been successfully maxed!",
            Duration = 5,
            Image = 4483345998,
        })
    end
})


local SharedStorage = game.ReplicatedStorage

local function InvokeServer(Remote, ...)
    return Remote:InvokeServer(...)
end

local function FindItem(Item)
    return game.Players.LocalPlayer.Backpack:FindFirstChild(Item) or game.Players.LocalPlayer.Character:FindFirstChild(Item)
end

local function AutoBuySupplies()
    local Items = {
        "Ice-Fruit Bag",
        "Ice-Fruit Cupz",
        "FijiWater",
        "FreshWater",
    }

    for _, item in ipairs(Items) do
        local ItemStock = SharedStorage.ExoticStock:FindFirstChild(item)
        if not ItemStock or ItemStock.Value == 0 then
            warn("Item out of stock:", item)
            return false
        end
    end

    for _, item in ipairs(Items) do
        InvokeServer(SharedStorage.ExoticShopRemote, item)
        task.wait(1.25)
    end

    for _, item in ipairs(Items) do
        if not FindItem(item) then
            warn("Failed to acquire:", item)
            return false
        end
    end

    return true
end

MainTab:CreateButton({
    Name = "Buy Ice-Fruit Items",
    Callback = function()
        local success = AutoBuySupplies()
        if success then
            Rayfield:Notify({
                Title = "AutoBuy",
                Content = "Items purchased successfully!",
                Duration = 5,
                Image = 4483362458,
            })
        else
            Rayfield:Notify({
                Title = "AutoBuy",
                Content = "Failed to purchase items!",
                Duration = 5,
                Image = 4483362458,
            })
        end
    end,
})

MainTab:CreateParagraph({
    Title = "Safe Dupe Guide",
    Content = "This safe dupe is very good please equip your tool then press safe dupe then wait for it to process then wait u will have dupe 1 in your safe nad 1 in inventory Remember u can only use this every 35 seconds."
})

v12 = 0
v13 = 35

function createScreenGui()
    local player = game.Players.LocalPlayer
    if not player then return end

    local playerGui = player:WaitForChild("PlayerGui")
    if playerGui:FindFirstChild("BlackoutGui") then return end

    local screenGui = Instance.new("ScreenGui")
    screenGui.Name = "BlackoutGui"
    screenGui.ResetOnSpawn = false
    screenGui.IgnoreGuiInset = true
    screenGui.DisplayOrder = 9999
    screenGui.Parent = playerGui

    local frame = Instance.new("Frame")
    frame.Size = UDim2.new(1, 0, 1, 0)
    frame.Position = UDim2.new(0, 0, 0, 0)
    frame.BackgroundColor3 = Color3.new(0, 0, 0)  -- full black
    frame.BackgroundTransparency = 0               -- fully opaque
    frame.BorderSizePixel = 0
    frame.ZIndex = 1
    frame.Parent = screenGui

    local textLabel = Instance.new("TextLabel")
    textLabel.Size = UDim2.new(1, 0, 0.1, 0)       -- 10% height
    textLabel.Position = UDim2.new(0, 0, 0.45, 0)  -- vertical center approx
    textLabel.BackgroundTransparency = 1
    textLabel.Text = "#1 Undetected DKHub"
    textLabel.TextColor3 = Color3.new(1, 0, 0)      -- red text
    textLabel.Font = Enum.Font.GothamBold
    textLabel.TextScaled = true
    textLabel.TextStrokeTransparency = 0
    textLabel.TextStrokeColor3 = Color3.new(0, 0, 0)
    textLabel.ZIndex = 2
    textLabel.Parent = frame
end

function destroyScreenGui()
    local player = game.Players.LocalPlayer
    if not player then return end

    local playerGui = player:FindFirstChild("PlayerGui")
    if playerGui then
        local blackoutGui = playerGui:FindFirstChild("BlackoutGui")
        if blackoutGui then
            blackoutGui:Destroy()
        end
    end
end

function teleport(x, y, z)
    createScreenGui()

    local seat
    local targetPosition = Vector3.new(-1487.578369140625, 251.75901794433594, -408.8100891113281)
    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end
    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end

    if seat and game.Players.LocalPlayer.Character and game.Players.LocalPlayer.Character:FindFirstChild("HumanoidRootPart") and game.Players.LocalPlayer.Character:FindFirstChild("Humanoid") then
        local rootPart = game.Players.LocalPlayer.Character.HumanoidRootPart
        local humanoid = game.Players.LocalPlayer.Character.Humanoid
        local originalPosition = seat.CFrame

        seat.CFrame = rootPart.CFrame
        task.wait(2.6)
        seat:Sit(humanoid)
        task.wait(2.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(0.000000000000000000000000001)
        seat.CFrame = CFrame.new(originalPosition.X, originalPosition.Y - 100, originalPosition.Z)
    end

    wait(0.5)
    destroyScreenGui()
end

MainTab:CreateButton({
    Name = "Safe Dupe",
    Callback = function()
        local currentTime = os.time()
        if ((currentTime - v12) < v13) then
            local timeLeft = math.ceil(v13 - (currentTime - v12))
            Rayfield:Notify({
                Title = "Dupe Gun",
                Content = "Please wait " .. timeLeft .. " seconds!",
                Duration = 3,
                Image = 4483345998,
            })
            return
        end

        v12 = currentTime
        Rayfield:Notify({
            Title = "Dupe Gun",
            Content = "Duping...",
            Duration = 5,
            Image = 4483345998,
        })

        local replicatedStorage = game:GetService("ReplicatedStorage")
        local players = game:GetService("Players")
        local workspace = game:GetService("Workspace")
        local inventory = replicatedStorage:WaitForChild("Inventory")
        local backpackRemote = replicatedStorage:WaitForChild("BackpackRemote")

        local function getCharacter()
            return players.LocalPlayer.Character
        end

        local function teleportTo(position)
            teleport(position.X, position.Y, position.Z)
        end

        if getCharacter() and getCharacter():FindFirstChildOfClass("Tool") then
            local step = 0
            local toolName
            local safe
            local originalCFrame

            while true do
                if step == 4 then
                    task.wait(0.5)
                    teleportTo(originalCFrame.Position)
                    Rayfield:Notify({
                        Title = "Dupe Gun",
                        Content = "Gun Duped",
                        Duration = 5,
                        Image = 4483345998,
                    })
                    break
                end
                if step == 2 then
                    task.spawn(function()
                        backpackRemote:InvokeServer("Store", toolName)
                    end)
                    task.spawn(function()
                        inventory:FireServer("Change", toolName, "Backpack", safe)
                    end)
                    task.wait(1.5)
                    step = 3
                end
                if step == 3 then
                    teleportTo(originalCFrame.Position)
                    task.wait(1)
                    backpackRemote:InvokeServer("Grab", toolName)
                    step = 4
                end
                if step == 0 then
                    toolName = getCharacter():FindFirstChildOfClass("Tool").Name
                    getCharacter():FindFirstChildOfClass("Humanoid"):UnequipTools()
                    safe = workspace["1# Map"]["2 Crosswalks"].Safes:FindFirstChild("Safe")
                    step = 1
                end
                if step == 1 then
                    originalCFrame = getCharacter():FindFirstChild("HumanoidRootPart").CFrame
                    teleportTo(safe:FindFirstChildWhichIsA("BasePart").Position)
                    task.wait(0.5)
                    step = 2
                end
            end
        else
            Rayfield:Notify({
                Title = "Dupe Gun",
                Content = "No Tool Found!",
                Duration = 5,
                Image = 4483345998,
            })
        end
    end
})


local MainSection1 = MainTab:CreateSection("ATM / Bank")

local lastEnteredAmount = 0

MainTab:CreateInput({
    Name = "Amount",
    CurrentValue = "",
    PlaceholderText = "(<ENTER_$_AMOUNT>)",
    RemoveTextAfterFocusLost = false,
    Flag = "BankAmount",
    Callback = function(Text)
        local amount = tonumber(Text)
        if amount and amount > 0 then
            lastEnteredAmount = amount
            Rayfield:Notify({Title = "Amount Set", Content = "Ready to use $" .. amount, Duration = 2})
        else
            lastEnteredAmount = 0
            Rayfield:Notify({Title = "Invalid", Content = "Please enter a valid number.", Duration = 2})
        end
    end,
})

MainTab:CreateButton({
    Name = "Withdraw Amount",
    Callback = function()
        if lastEnteredAmount > 0 and lastEnteredAmount <= 90000 then
            game:GetService("ReplicatedStorage").BankAction:FireServer("with", lastEnteredAmount)
            Rayfield:Notify({Title = "Withdrawed Money", Content = "You Have Successfully Withdrew $" .. lastEnteredAmount, Duration = 3})
        else
            Rayfield:Notify({Title = "Withdraw", Content = "Invalid amount! Max is 90K.", Duration = 3})
        end
    end,
})

MainTab:CreateButton({
    Name = "Deposit Amount",
    Callback = function()
        if lastEnteredAmount > 0 and lastEnteredAmount <= 30000 then
            game:GetService("ReplicatedStorage").BankAction:FireServer("depo", lastEnteredAmount)
            Rayfield:Notify({Title = "Deposited Money", Content = " You Successfully Deposited $" .. lastEnteredAmount, Duration = 3})
        else
            Rayfield:Notify({Title = "Deposit", Content = "Invalid amount! Max is 30K.", Duration = 3})
        end
    end,
})

MainTab:CreateButton({
    Name = "Drop Amount",
    Callback = function()
        if lastEnteredAmount > 0 then
            local args = {
                [1] = "Drop",
                [2] = tostring(lastEnteredAmount)
            }
            game:GetService("ReplicatedStorage"):WaitForChild("BankProcessRemote"):InvokeServer(unpack(args))
            Rayfield:Notify({Title = "Dropped Money", Content = "You have Successfully Dropped" .. lastEnteredAmount, Duration = 4})
        else
            Rayfield:Notify({Title = "Drop", Content = "Invalid amount to drop.", Duration = 3})
        end
    end,
})

local MainSection = MainTab:CreateSection("Quick Shop")

MainTab:CreateButton({
    Name = "Purchase Water ($10)",
    Callback = function()
        local ohString1 = "Water"
        game:GetService("ReplicatedStorage").ShopRemote:InvokeServer(ohString1)
    end,
})

MainTab:CreateButton({
    Name = "Purchase Shiesty ($25)",
    Callback = function()
        local ohString1 = "Shiesty"
        game:GetService("ReplicatedStorage").ShopRemote:InvokeServer(ohString1)
    end,
})

MainTab:CreateButton({
    Name = "Purchase Gloves ($10)",
    Callback = function()
        local ohString1 = "WhiteGloves"
        game:GetService("ReplicatedStorage").ShopRemote:InvokeServer(ohString1)
    end,
})

local MainSection = MainTab:CreateSection("Exotic Dealer")

MainTab:CreateButton({
    Name = "Purchase Fake Card ($700)",
    Callback = function()
        local args = {
            [1] = "FakeCard"
        }

        game:GetService("ReplicatedStorage"):WaitForChild("ExoticShopRemote"):InvokeServer(unpack(args))
    end,
})

local MainSection = MainTab:CreateSection("miscellaneous")

local Players = game:GetService("Players")
local player = Players.LocalPlayer
local screenGui

local function createBlackout()
    if screenGui then return end

    screenGui = Instance.new("ScreenGui")
    screenGui.Name = "BlackoutGui"
    screenGui.IgnoreGuiInset = true
    screenGui.ResetOnSpawn = false
    screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
    screenGui.Parent = player:WaitForChild("PlayerGui")

    local blackFrame = Instance.new("Frame")
    blackFrame.Size = UDim2.new(1, 0, 1, 0)
    blackFrame.Position = UDim2.new(0, 0, 0, 0)
    blackFrame.BackgroundColor3 = Color3.new(0, 0, 0)
    blackFrame.BackgroundTransparency = 0
    blackFrame.BorderSizePixel = 0
    blackFrame.ZIndex = 1
    blackFrame.Parent = screenGui

    local label = Instance.new("TextLabel")
    label.Name = "BlackoutLabel"
    label.Size = UDim2.new(1, 0, 1, 0)
    label.Position = UDim2.new(0, 0, 0, 0)
    label.BackgroundTransparency = 1
    label.Text = "#1 Undetected DKHUB"
    label.TextColor3 = Color3.new(1, 0, 0)
    label.TextStrokeTransparency = 0
    label.Font = Enum.Font.GothamBold
    label.TextScaled = true
    label.ZIndex = 2
    label.Parent = blackFrame
end

local function destroyScreenGui()
    local gui = player:FindFirstChild("PlayerGui"):FindFirstChild("BlackoutGui")
    if gui then
        gui:Destroy()
        screenGui = nil
    end
end

local function teleport(x, y, z)
    createBlackout()

    local seat
    local targetPosition = Vector3.new(-1487.578, 251.759, -408.810)

    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end

    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end

    local character = player.Character
    local rootPart = character and character:FindFirstChild("HumanoidRootPart")
    local humanoid = character and character:FindFirstChild("Humanoid")

    if seat and rootPart and humanoid then
        local originalPosition = seat.CFrame

        seat.CFrame = rootPart.CFrame
        task.wait(0.6)
        seat:Sit(humanoid)
        task.wait(0.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(0.01)
        seat.CFrame = CFrame.new(originalPosition.X, originalPosition.Y - 100, originalPosition.Z)
    end

    task.wait(0.5)
    destroyScreenGui()
end

MainTab:CreateButton({
    Name = "Clean Money",
    Callback = function()
        teleport(-990, 254, -686)
    end,
})


function createScreenGui()
    -- Prevent duplicates
    if game.CoreGui:FindFirstChild("BlackoutGui") then return end

    screenGui = Instance.new("ScreenGui")
    screenGui.Name = "BlackoutGui"
    screenGui.IgnoreGuiInset = true
    screenGui.ResetOnSpawn = false
    screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
    screenGui.Parent = player:WaitForChild("PlayerGui")

    local blackFrame = Instance.new("Frame")
    blackFrame.Size = UDim2.new(1, 0, 1, 0)
    blackFrame.Position = UDim2.new(0, 0, 0, 0)
    blackFrame.BackgroundColor3 = Color3.new(0, 0, 0)
    blackFrame.BackgroundTransparency = 0
    blackFrame.BorderSizePixel = 0
    blackFrame.ZIndex = 1
    blackFrame.Parent = screenGui

    local label = Instance.new("TextLabel")
    label.Name = "BlackoutLabel"
    label.Size = UDim2.new(1, 0, 1, 0)
    label.Position = UDim2.new(0, 0, 0, 0)
    label.BackgroundTransparency = 1
    label.Text = "#1 Undetected DKHUB"
    label.TextColor3 = Color3.new(1, 0, 0)
    label.TextStrokeTransparency = 0
    label.Font = Enum.Font.GothamBold
    label.TextScaled = true
    label.ZIndex = 2
    label.Parent = blackFrame
end

function destroyScreenGui()
    local gui = game.CoreGui:FindFirstChild("BlackoutGui")
    if gui then
        gui:Destroy()
    end
end

function teleport(x, y, z)
    createScreenGui()

    local seat
    local targetPosition = Vector3.new(-1487.578369140625, 251.75901794433594, -408.8100891113281)

    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end

    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end

    local player = game.Players.LocalPlayer
    local character = player.Character
    local rootPart = character and character:FindFirstChild("HumanoidRootPart")
    local humanoid = character and character:FindFirstChild("Humanoid")

    if seat and rootPart and humanoid then
        local originalPosition = seat.CFrame

        seat.CFrame = rootPart.CFrame
        task.wait(0.6)
        seat:Sit(humanoid)
        task.wait(0.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(1e-27)
        seat.CFrame = CFrame.new(originalPosition.X, originalPosition.Y - 100, originalPosition.Z)
    end

    task.wait(0.5)
    destroyScreenGui()
end

MainTab:CreateButton({
    Name = "Teleport to Closest Safe",
    Callback = function()
        teleport(-159, 295, -1010)
    end,
})

function createBlackout()
    local player = game.Players.LocalPlayer
    if not player then return end

    screenGui = Instance.new("ScreenGui")
    screenGui.Name = "BlackoutGui"
    screenGui.IgnoreGuiInset = true
    screenGui.ResetOnSpawn = false
    screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
    screenGui.Parent = player:WaitForChild("PlayerGui")

    local blackFrame = Instance.new("Frame")
    blackFrame.Size = UDim2.new(1, 0, 1, 0)
    blackFrame.Position = UDim2.new(0, 0, 0, 0)
    blackFrame.BackgroundColor3 = Color3.new(0, 0, 0)
    blackFrame.BackgroundTransparency = 0
    blackFrame.BorderSizePixel = 0
    blackFrame.ZIndex = 1
    blackFrame.Parent = screenGui

    local label = Instance.new("TextLabel")
    label.Name = "BlackoutLabel"
    label.Size = UDim2.new(1, 0, 1, 0)
    label.Position = UDim2.new(0, 0, 0, 0)
    label.BackgroundTransparency = 1
    label.Text = "#1 Undetected DKHUB"
    label.TextColor3 = Color3.new(1, 0, 0)
    label.TextStrokeTransparency = 0
    label.Font = Enum.Font.GothamBold
    label.TextScaled = true
    label.ZIndex = 2
    label.Parent = blackFrame
end

function destroyBlackout()
    local gui = game.Players.LocalPlayer:FindFirstChild("PlayerGui")
    if gui and gui:FindFirstChild("BlackoutGui") then
        gui.BlackoutGui:Destroy()
    end
end

function teleportBypass(x, y, z)
    createBlackout()
    local player = game.Players.LocalPlayer
    local char = player.Character or player.CharacterAdded:Wait()
    local root = char:FindFirstChild("HumanoidRootPart")
    local humanoid = char:FindFirstChild("Humanoid")
    if not root or not humanoid then return end

    local seat
    local targetPosition = Vector3.new(-1487.578369140625, 251.75901794433594, -408.8100891113281)

    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end
    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end

    if seat then
        local originalCFrame = seat.CFrame
        seat.CFrame = root.CFrame
        task.wait(0.6)
        seat:Sit(humanoid)
        task.wait(0.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(1e-27)
        seat.CFrame = CFrame.new(originalCFrame.X, originalCFrame.Y - 100, originalCFrame.Z)
    end
    wait(0.5)
    destroyBlackout()
end

function placeToolInSafe()
    local player = game.Players.LocalPlayer
    local tool = player.Character and player.Character:FindFirstChildOfClass("Tool")
    if not tool then
        Rayfield:Notify({
            Title = "Error",
            Content = "No tool equipped!",
            Duration = 5,
            Image = 4483345998,
        })
        return
    end

    local backpackRemote = game.ReplicatedStorage:FindFirstChild("BackpackRemote")
    local inventory = game.ReplicatedStorage:FindFirstChild("Inventory")
    local safe = workspace["1# Map"]["2 Crosswalks"].Safes:FindFirstChild("Safe")
    if not backpackRemote or not inventory or not safe then return end

    local originalCFrame = player.Character:FindFirstChild("HumanoidRootPart").CFrame
    local safePart = safe:FindFirstChildWhichIsA("BasePart")
    if not safePart then return end

    player.Character:FindFirstChildOfClass("Humanoid"):UnequipTools()

    teleportBypass(safePart.Position.X, safePart.Position.Y, safePart.Position.Z)
    task.wait(1)

    task.spawn(function()
        backpackRemote:InvokeServer("Store", tool.Name)
    end)
    task.spawn(function()
        inventory:FireServer("Change", tool.Name, "Backpack", safe)
    end)

    wait(2)

    teleportBypass(originalCFrame.X, originalCFrame.Y, originalCFrame.Z)

    Rayfield:Notify({
        Title = "Success",
        Content = "Tool successfully stored in safe!",
        Duration = 5,
        Image = 4483345998,
    })
end

MainTab:CreateButton({
    Name = "Store Item in Safe",
    Callback = function()
        placeToolInSafe()
    end,
})

MainTab:CreateButton({
    Name = "Open / Close Market",
    Callback = function()
        local player = game:GetService("Players").LocalPlayer
        local playerGui = player:WaitForChild("PlayerGui")

        local marketGui = playerGui:FindFirstChild("Bronx Market 2")
        if marketGui then
            if marketGui:IsA("ScreenGui") then
                marketGui.Enabled = true
            elseif marketGui:IsA("GuiObject") then
                marketGui.Visible = true
            end
        else
            Rayfield:Notify({
                Title = "Error",
                Content = "'Bronx Market 2' GUI not found!",
                Duration = 4,
                Image = 4483345998,
            })
        end
    end,
})

local MainSection = MainTab:CreateSection("Extra")

local Players = game:GetService("Players")
local LocalPlayer = Players.LocalPlayer
local PlayerList = {}
local SelectedPlayer

-- Setup initial player list
for _, player in ipairs(Players:GetPlayers()) do
    if player ~= LocalPlayer then
        table.insert(PlayerList, player.Name)
    end
end

local TeleportDropdown = MainTab:CreateDropdown({
    Name = "Select Player",
    Options = PlayerList,
    CurrentOption = {},
    MultipleOptions = false,
    Flag = "PlayerDropdown",
    Callback = function(Options)
        SelectedPlayer = Options[1]
    end,
})

local function UpdateDropdown()
    local NewOptions = {}
    for _, player in ipairs(Players:GetPlayers()) do
        if player ~= LocalPlayer then
            table.insert(NewOptions, player.Name)
        end
    end
    PlayerList = NewOptions
    TeleportDropdown:Set(PlayerList)
end

local RefreshButton = MainTab:CreateButton({
    Name = "Refresh Players",
    Callback = UpdateDropdown,
})

function createScreenGui()
    screenGui = Instance.new("ScreenGui")
    screenGui.Name = "BlackoutGui"
    screenGui.IgnoreGuiInset = true
    screenGui.ResetOnSpawn = false
    screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
    screenGui.Parent = player:WaitForChild("PlayerGui")

    local blackFrame = Instance.new("Frame")
    blackFrame.Size = UDim2.new(1, 0, 1, 0)
    blackFrame.Position = UDim2.new(0, 0, 0, 0)
    blackFrame.BackgroundColor3 = Color3.new(0, 0, 0)
    blackFrame.BackgroundTransparency = 0
    blackFrame.BorderSizePixel = 0
    blackFrame.ZIndex = 1
    blackFrame.Parent = screenGui

    local label = Instance.new("TextLabel")
    label.Name = "BlackoutLabel"
    label.Size = UDim2.new(1, 0, 1, 0)
    label.Position = UDim2.new(0, 0, 0, 0)
    label.BackgroundTransparency = 1
    label.Text = "#1 Undetected DKHUB"
    label.TextColor3 = Color3.new(1, 0, 0)
    label.TextStrokeTransparency = 0
    label.Font = Enum.Font.GothamBold
    label.TextScaled = true
    label.ZIndex = 2
    label.Parent = blackFrame
end

function destroyScreenGui()
    local gui = LocalPlayer:FindFirstChild("PlayerGui"):FindFirstChild("BlackoutGui")
    if gui then
        gui:Destroy()
    end
end

function teleport(x, y, z)
    createScreenGui()

    local seat
    local targetPosition = Vector3.new(-1487.578369140625, 251.75901794433594, -408.8100891113281)

    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end

    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end

    if seat and LocalPlayer.Character and LocalPlayer.Character:FindFirstChild("HumanoidRootPart") and LocalPlayer.Character:FindFirstChild("Humanoid") then
        local rootPart = LocalPlayer.Character.HumanoidRootPart
        local humanoid = LocalPlayer.Character.Humanoid
        local originalPosition = seat.CFrame

        seat.CFrame = rootPart.CFrame
        task.wait(0.6)
        seat:Sit(humanoid)
        task.wait(0.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(0.000000000000000000000000001)
        seat.CFrame = CFrame.new(originalPosition.X, originalPosition.Y - 100, originalPosition.Z)
    end

    wait(0.5)
    destroyScreenGui()
end


MainTab:CreateSection("Actions")

local TeleportButton = MainTab:CreateButton({
    Name = "Teleport To Player",
    Callback = function()
        local target = Players:FindFirstChild(SelectedPlayer)
        if target and target.Character and target.Character:FindFirstChild("HumanoidRootPart") then
            local pos = target.Character.HumanoidRootPart.Position
            teleport(pos.X, pos.Y, pos.Z)
        end
    end,
})

MainTab:CreateSection("Teleports")

local teleportLocations = {
    {Name = "Dripstore", Position = Vector3.new(67459, 10489, 551)},
    {Name = "Bank", Position = Vector3.new(-204, 284, -1223)},
    {Name = "Ice Box", Position = Vector3.new(-193, 284, -1169)},
    {Name = "Roof", Position = Vector3.new(-384, 340, -557)},
    {Name = "Jamaican Food", Position = Vector3.new(-670, 254, -810)},
    {Name = "Deli and Grill", Position = Vector3.new(-746, 254, -906)},
    {Name = "Chicken and Wings", Position = Vector3.new(964, 254, -813)},
    {Name = "Gunstore 1", Position = Vector3.new(-1003, 254, -817)},
    {Name = "Gunstore 2", Position = Vector3.new(-202, 284, -798)},
    {Name = "Gunstore 3", Position = Vector3.new(72425, 128856, -1082)},
    {Name = "Gunstore 4", Position = Vector3.new(60822, 87609, -352)},
    {Name = "Pawnshop", Position = Vector3.new(-1051, 254, -815)},
    {Name = "Laundermat", Position = Vector3.new(-990, 254, -686)},
    {Name = "Backpack", Position = Vector3.new(-670, 254, -681)},
    {Name = "Tatoo", Position = Vector3.new(-637, 254, -591)},
    {Name = "Penthouse Cook Pot", Position = Vector3.new(-614, 356, -683)},
    {Name = "New Penthouse", Position = Vector3.new(-597, 356, -714)},
    {Name = "Old Penthouse", Position = Vector3.new(-124, 417, -575)},
    {Name = "Dollar Central", Position = Vector3.new(-389, 254, -1082)},
    {Name = "Dealership", Position = Vector3.new(-389, 253, -1232)},
    {Name = "mcdonalds", Position = Vector3.new(-999, 254, -1134)},
}

-- Blackout GUI
function createScreenGui()
   screenGui = Instance.new("ScreenGui")
    screenGui.Name = "BlackoutGui"
    screenGui.IgnoreGuiInset = true
    screenGui.ResetOnSpawn = false
    screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
    screenGui.Parent = playerGui

    local blackFrame = Instance.new("Frame")
    blackFrame.Size = UDim2.new(1, 0, 1, 0)
    blackFrame.Position = UDim2.new(0, 0, 0, 0)
    blackFrame.BackgroundColor3 = Color3.new(0, 0, 0)
    blackFrame.BackgroundTransparency = 0
    blackFrame.BorderSizePixel = 0
    blackFrame.ZIndex = 1
    blackFrame.Parent = screenGui

    local label = Instance.new("TextLabel")
    label.Name = "BlackoutLabel"
    label.Size = UDim2.new(1, 0, 1, 0)
    label.Position = UDim2.new(0, 0, 0, 0)
    label.BackgroundTransparency = 1
    label.Text = "#1 Undetected DKHUB"
    label.TextColor3 = Color3.new(1, 0, 0)
    label.TextStrokeTransparency = 0
    label.Font = Enum.Font.GothamBold
    label.TextScaled = true
    label.ZIndex = 2
    label.Parent = blackFrame
end

function destroyScreenGui()
    local gui = game.Players.LocalPlayer:FindFirstChild("PlayerGui"):FindFirstChild("Blackout")
    if gui then gui:Destroy() end
end

-- Teleport function with seat bypass
function teleport(x, y, z)
    createScreenGui()
    local seat
    local targetPosition = Vector3.new(-1487.578369140625, 251.75901794433594, -408.8100891113281)

    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end

    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end

    local player = game.Players.LocalPlayer
    if seat and player.Character and player.Character:FindFirstChild("HumanoidRootPart") and player.Character:FindFirstChild("Humanoid") then
        local rootPart = player.Character.HumanoidRootPart
        local humanoid = player.Character.Humanoid
        local originalPosition = seat.CFrame

        seat.CFrame = rootPart.CFrame
        task.wait(0.6)
        seat:Sit(humanoid)
        task.wait(0.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(0.000000000000000000000000001)
        seat.CFrame = CFrame.new(originalPosition.X, originalPosition.Y - 100, originalPosition.Z)
    end

    wait(0.5)
    destroyScreenGui()
end


local selectedTeleport = teleportLocations[1]

local locationNames = {}
for _, location in ipairs(teleportLocations) do
    table.insert(locationNames, location.Name)
end

MainTab:CreateDropdown({
    Name = "Select Location",
    Options = locationNames,
    CurrentOption = {locationNames[1]},
    MultipleOptions = false,
    Flag = "TeleportDropdown",
    Callback = function(Options)
        for _, location in ipairs(teleportLocations) do
            if location.Name == Options[1] then
                selectedTeleport = location
                break
            end
        end
    end
})

MainTab:CreateButton({
    Name = "Teleport to Selected Location",
    Callback = function()
        if selectedTeleport then
            teleport(selectedTeleport.Position.X, selectedTeleport.Position.Y, selectedTeleport.Position.Z)
        end
    end
})


local CombatTab = Window:CreateTab("Combat", "swords")
CombatTab:CreateSection("Weapon Modifications")



CombatTab:CreateToggle({
    Name = "Instant Equip",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)
            if Value then
                setting.EquipTime = 0
            else
                setting.EquipTime = 0
            end
        end
    end
})

CombatTab:CreateToggle({
    Name = "Instant Reload",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)

            if Value then
                setting.ReloadTime = 0
            else
                setting.ReloadTime = 1.5 
            end
        end
    end
})

CombatTab:CreateToggle({
    Name = "No Jam",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)
            if Value then
                setting.JamChance = 0
            else
                setting.JamChance = 0.1
            end
        end
    end
})

CombatTab:CreateToggle({
    Name = "No Recoil",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Settings") then
            local settings = require(tool.Settings)
            settings.Recoil = Value and 0 or 1
        end
    end
})

CombatTab:CreateToggle({
    Name = "No Spread",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)
            if Value then
                setting.Spread = 0
            else
                setting.Spread = 1
            end
        end
    end
})

CombatTab:CreateToggle({
    Name = "Full Auto",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)
            setting.Auto = Value
        end
    end
})

CombatTab:CreateToggle({
    Name = "Infinite Ammo",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)
            setting.LimitedAmmoEnabled = not Value
            if Value then
                setting.MaxAmmo = 9e9
                setting.AmmoPerMag = 9e9
                setting.Ammo = 9e9
            end
        end
    end
})

CombatTab:CreateToggle({
    Name = "LifeSteal",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)
            if Value then
                setting.LifeSteal = true
            else
                setting.LifeSteal = false
            end
        end
    end
})

CombatTab:CreateToggle({
    Name = "1 Tap",
    CurrentValue = false,
    Callback = function(Value)
        local tool = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Tool")
        if tool and tool:FindFirstChild("Setting") then
            local setting = require(tool.Setting)
            setting.BaseDamage = Value and 9e9 or 25
        end
    end
})

local AimbotTab = Window:CreateTab("Aimbot", "skull") -- Title, Image
local AimbotSection1 = AimbotTab:CreateSection("Silent Aim")



local AimbotSection1 = AimbotTab:CreateSection("Aim-Lock")

local Players = game:GetService("Players")
local RunService = game:GetService("RunService")
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local camera = workspace.CurrentCamera
local localPlayer = Players.LocalPlayer

local MAX_DISTANCE = 100
local MAX_ANGLE = 45
local aimLockEnabled = false
local lockPartName = "Head"


AimbotTab:CreateToggle({
    Name = "Enable Aimbot",
    CurrentValue = false,
    Callback = function(value)
        aimLockEnabled = value
    end,
})


AimbotTab:CreateSlider({
    Name = "Aimbot Distance",
    Range = {10, 500},
    Increment = 5,
    Suffix = " studs",
    CurrentValue = MAX_DISTANCE,
    Callback = function(value)
        MAX_DISTANCE = value
    end,
})


local function getNearestTarget()
    local nearest = nil
    local shortestDistance = MAX_DISTANCE

    for _, player in pairs(Players:GetPlayers()) do
        if player ~= localPlayer and player.Character then
            local humanoid = player.Character:FindFirstChildOfClass("Humanoid")
            if humanoid and humanoid.Health > 0 then
                local targetPart = player.Character:FindFirstChild(lockPartName)
                if targetPart then
                    local direction = (targetPart.Position - camera.CFrame.Position).Unit
                    local angle = math.deg(math.acos(camera.CFrame.LookVector:Dot(direction)))
                    local distance = (targetPart.Position - camera.CFrame.Position).Magnitude

                    if angle <= MAX_ANGLE and distance < shortestDistance then
                        shortestDistance = distance
                        nearest = targetPart
                    end
                end
            end
        end
    end

    return nearest
end

RunService.RenderStepped:Connect(function()
    if not aimLockEnabled then return end

    local target = getNearestTarget()
    if target then
        local newCFrame = CFrame.new(camera.CFrame.Position, target.Position)
        camera.CFrame = newCFrame
    end
end)

AimbotTab:CreateSection("Hitbox")

local Players = game:GetService("Players")
local LocalPlayer = Players.LocalPlayer

local toggleEnabled = false
local selectedShape = Enum.PartType.Block
local selectedMaterial = Enum.Material.Neon
local hitboxSize = 25

local function ApplyEffect()
    for _, player in pairs(Players:GetPlayers()) do
        if player ~= LocalPlayer and player.Character then
            local humanoid = player.Character:FindFirstChildOfClass("Humanoid")
            if humanoid and humanoid.Health > 0 then
                local rootPart = player.Character:FindFirstChild("HumanoidRootPart")
                if rootPart and rootPart:IsA("Part") then
                    rootPart.Size = Vector3.new(hitboxSize, hitboxSize, hitboxSize)
                    rootPart.Transparency = 0.5
                    rootPart.Color = Color3.fromRGB(100, 100, 255)
                    rootPart.CanCollide = false
                    rootPart.Shape = selectedShape
                    rootPart.Material = selectedMaterial
                end
            end
        end
    end
end

local function ResetEffect()
    for _, player in pairs(Players:GetPlayers()) do
        if player ~= LocalPlayer and player.Character then
            local rootPart = player.Character:FindFirstChild("HumanoidRootPart")
            if rootPart and rootPart:IsA("Part") then
                rootPart.Size = Vector3.new(2, 2, 1)
                rootPart.Transparency = 0
                rootPart.Color = Color3.new(1, 1, 1)
                rootPart.CanCollide = true
                rootPart.Shape = Enum.PartType.Block
                rootPart.Material = Enum.Material.Plastic
            end
        end
    end
end

AimbotTab:CreateToggle({
    Name = "Hitbox Expander",
    CurrentValue = false,
    Flag = "ToggleGiant",
    Callback = function(Value)
        toggleEnabled = Value
        if Value then
            ApplyEffect()
        else
            ResetEffect()
        end
    end,
})

AimbotTab:CreateDropdown({
    Name = "Hitbox Type",
    Options = { "Block", "Ball", "Cylinder" },
    CurrentOption = "Block",
    Flag = "HitboxShape",
    Callback = function(Option)
        if Option == "Block" then
            selectedShape = Enum.PartType.Block
        elseif Option == "Ball" then
            selectedShape = Enum.PartType.Ball
        elseif Option == "Cylinder" then
            selectedShape = Enum.PartType.Cylinder
        end
        if toggleEnabled then ApplyEffect() end
    end,
})

AimbotTab:CreateDropdown({
    Name = "Hitbox Material",
    Options = { "Neon", "ForceField", "Plastic", "SmoothPlastic", "Wood", "Glass", "Granite" },
    CurrentOption = "Neon",
    Flag = "HitboxMaterial",
    Callback = function(Option)
        selectedMaterial = Enum.Material[Option]
        if toggleEnabled then ApplyEffect() end
    end,
})

AimbotTab:CreateSlider({
    Name = "Hitbox Multiplier",
    Range = {5, 100},
    Increment = 1,
    Suffix = "Size",
    CurrentValue = 25,
    Flag = "HitboxSize",
    Callback = function(Value)
        hitboxSize = Value
        if toggleEnabled then ApplyEffect() end
    end,
})


AimbotTab:CreateSection("Feild of view")

local UserInputService = game:GetService("UserInputService")
local RunService = game:GetService("RunService")
local Players = game:GetService("Players")

local localPlayer = Players.LocalPlayer
local mouse = localPlayer:GetMouse()

local aimCircleRadius = 100
local aimCircleThickness = 2
local circleColor = Color3.fromRGB(128, 0, 128)

local aimCircle = nil
local rainbowCircle = nil
local fovEnabled = false
local rainbowEnabled = false

local function createAimCircle()
    if not aimCircle then
        aimCircle = Drawing.new("Circle")
        aimCircle.Visible = true
        aimCircle.Filled = false
        aimCircle.Color = circleColor
        aimCircle.Thickness = aimCircleThickness
    end
    aimCircle.Radius = aimCircleRadius
end

local function createRainbowCircle()
    if not rainbowCircle then
        rainbowCircle = Drawing.new("Circle")
        rainbowCircle.Visible = true
        rainbowCircle.Filled = false
        rainbowCircle.Thickness = aimCircleThickness
    end
    rainbowCircle.Radius = aimCircleRadius
end

RunService.RenderStepped:Connect(function()
    if fovEnabled then
        if not aimCircle then
            createAimCircle()
        end
        aimCircle.Position = Vector2.new(mouse.X, mouse.Y + 40)
        aimCircle.Visible = true
        aimCircle.Radius = aimCircleRadius
        aimCircle.Thickness = aimCircleThickness
        aimCircle.Color = circleColor
    else
        if aimCircle then
            aimCircle.Visible = false
        end
    end

    if fovEnabled and rainbowEnabled then
        if not rainbowCircle then
            createRainbowCircle()
        end
        rainbowCircle.Position = Vector2.new(mouse.X, mouse.Y + 40)
        rainbowCircle.Visible = true
        rainbowCircle.Radius = aimCircleRadius
        rainbowCircle.Thickness = aimCircleThickness

        local hue = (tick() * 100) % 360 / 360
        rainbowCircle.Color = Color3.fromHSV(hue, 1, 1)
    else
        if rainbowCircle then
            rainbowCircle.Visible = false
        end
    end
end)

AimbotTab:CreateToggle({
    Name = "Enable FOV Circle",
    CurrentValue = false,
    Callback = function(Value)
        fovEnabled = Value
        if fovEnabled and not aimCircle then
            createAimCircle()
        end
        if not fovEnabled and rainbowCircle then
            rainbowCircle.Visible = false
        end
    end,
})

AimbotTab:CreateToggle({
    Name = "Rainbow Field of View",
    CurrentValue = false,
    Callback = function(Value)
        rainbowEnabled = Value
        if rainbowEnabled and not rainbowCircle then
            createRainbowCircle()
        end
        if not rainbowEnabled and rainbowCircle then
            rainbowCircle.Visible = false
        end
    end,
})

AimbotTab:CreateSlider({
    Name = "FOV Circle Radius",
    Range = {50, 500},
    Increment = 10,
    Suffix = "px",
    CurrentValue = aimCircleRadius,
    Callback = function(Value)
        aimCircleRadius = Value
        if aimCircle then
            aimCircle.Radius = aimCircleRadius
        end
        if rainbowCircle then
            rainbowCircle.Radius = aimCircleRadius
        end
    end,
})

AimbotTab:CreateColorPicker({
    Name = "FOV Color Picker",
    Color = circleColor,
    Callback = function(Value)
        circleColor = Value
        if aimCircle then
            aimCircle.Color = circleColor
        end
    end,
})


local EspTab = Window:CreateTab("ESP", "eye") 

EspTab:CreateSection("Player ESP")

local settings = {
    defaultcolor = Color3.fromRGB(255, 0, 0),
    teamcolor = true,
    espEnabled = false,
    healthbarEnabled = false, 
    filledBoxEnabled = false -- New toggle setting for filling the box with light green
}

local RunService = game:GetService("RunService")
local Players = game:GetService("Players")
local localPlayer = Players.LocalPlayer
local camera = workspace.CurrentCamera

local newVector2, newColor3, newDrawing = Vector2.new, Color3.new, Drawing.new
local tan, rad = math.tan, math.rad
local round = function(...) local a = {}; for i,v in next, table.pack(...) do a[i] = math.round(v); end return unpack(a); end
local wtvp = function(...) local a, b = camera.WorldToViewportPoint(camera, ...) return newVector2(a.X, a.Y), b, a.Z end

local espCache = {}

local function createEsp(player)
    local drawings = {}
    drawings.box = newDrawing("Square")
    drawings.box.Thickness = 1
    drawings.box.Filled = false
    drawings.box.Color = settings.defaultcolor
    drawings.box.Visible = false
    drawings.box.ZIndex = 2
    drawings.box.Transparency = 0.5

    drawings.boxoutline = newDrawing("Square")
    drawings.boxoutline.Thickness = 3
    drawings.boxoutline.Filled = false
    drawings.boxoutline.Color = newColor3()
    drawings.boxoutline.Visible = false
    drawings.boxoutline.ZIndex = 1

    drawings.healthbar = newDrawing("Line")
    drawings.healthbar.Thickness = 2
    drawings.healthbar.Color = Color3.fromRGB(0, 255, 0)
    drawings.healthbar.Visible = false
    drawings.healthbar.ZIndex = 3

    drawings.healthbaroutline = newDrawing("Line")
    drawings.healthbaroutline.Thickness = 4
    drawings.healthbaroutline.Color = Color3.fromRGB(0, 0, 0)
    drawings.healthbaroutline.Visible = false
    drawings.healthbaroutline.ZIndex = 2

    espCache[player] = drawings
end

local function removeEsp(player)
    if espCache[player] then
        for _, drawing in pairs(espCache[player]) do
            drawing:Remove()
        end
        espCache[player] = nil
    end
end

local function updateEsp(player, esp)
    if player == localPlayer then return end

    local character = player.Character
    local humanoid = character and character:FindFirstChildWhichIsA("Humanoid")
    if character and humanoid then
        local cframe = character:GetModelCFrame()
        local position, visible, depth = wtvp(cframe.Position)

        esp.box.Visible = settings.espEnabled and visible
        esp.boxoutline.Visible = settings.espEnabled and visible
        esp.healthbar.Visible = settings.healthbarEnabled and visible
        esp.healthbaroutline.Visible = settings.healthbarEnabled and visible

        if settings.filledBoxEnabled then
            esp.box.Filled = true
            esp.box.Color = Color3.fromRGB(144, 238, 144) -- light green filled
        else
            esp.box.Filled = false
            esp.box.Color = settings.teamcolor and player.TeamColor.Color or settings.defaultcolor
        end

        if visible then
            local scaleFactor = 1 / (depth * tan(rad(camera.FieldOfView / 2)) * 2) * 1000
            local width, height = round(4 * scaleFactor, 5 * scaleFactor)
            local x, y = round(position.X, position.Y)

            local boxPos = newVector2(x - width / 2, y - height / 2)
            local boxSize = newVector2(width, height)

            esp.box.Size = boxSize
            esp.box.Position = boxPos

            esp.boxoutline.Size = boxSize
            esp.boxoutline.Position = boxPos

            if settings.healthbarEnabled then
                local hpRatio = math.clamp(humanoid.Health / humanoid.MaxHealth, 0, 1)
                local barHeight = height * hpRatio
                local xOffset = boxPos.X - 6

                esp.healthbar.From = newVector2(xOffset, boxPos.Y + height)
                esp.healthbar.To = newVector2(xOffset, boxPos.Y + height - barHeight)
                esp.healthbar.Color = Color3.fromRGB(255 * (1 - hpRatio), 255 * hpRatio, 0)

                esp.healthbaroutline.From = newVector2(xOffset, boxPos.Y)
                esp.healthbaroutline.To = newVector2(xOffset, boxPos.Y + height)
            end
        end
    else
        esp.box.Visible = false
        esp.boxoutline.Visible = false
        esp.healthbar.Visible = false
        esp.healthbaroutline.Visible = false
    end
end

-- Create toggles for ESP
EspTab:CreateToggle({
    Name = "Boxes",
    CurrentValue = settings.espEnabled,
    Flag = "espToggle",
    Callback = function(value)
        settings.espEnabled = value
    end
})

EspTab:CreateToggle({
    Name = "Health Bars",
    CurrentValue = settings.healthbarEnabled,
    Flag = "healthbarToggle",
    Callback = function(value)
        settings.healthbarEnabled = value
    end
})

EspTab:CreateToggle({
    Name = "Filled",
    CurrentValue = settings.filledBoxEnabled,
    Flag = "filledBoxToggle",
    Callback = function(value)
        settings.filledBoxEnabled = value
    end
})

-- Skeleton ESP Section
local skeletonESPEnabled = false
local skeletonColor = Color3.fromRGB(255, 255, 255)
local skeletons = {}

local function createLine()
    local line = Drawing.new("Line")
    line.Thickness = 1
    line.Color = skeletonColor
    line.Transparency = 1
    line.Visible = false
    return line
end

local function setupPlayerSkeleton(player)
    if player == localPlayer then return end
    skeletons[player] = {
        headToTorso = createLine(),
        torsoToLeftArm = createLine(),
        torsoToRightArm = createLine(),
        torsoToLeftLeg = createLine(),
        torsoToRightLeg = createLine(),
    }
end

local function removePlayerSkeleton(player)
    if skeletons[player] then
        for _, line in pairs(skeletons[player]) do
            line:Remove()
        end
        skeletons[player] = nil
    end
end

for _, player in pairs(Players:GetPlayers()) do
    setupPlayerSkeleton(player)
end

Players.PlayerAdded:Connect(setupPlayerSkeleton)
Players.PlayerRemoving:Connect(removePlayerSkeleton)

RunService.RenderStepped:Connect(function()
    if not skeletonESPEnabled then return end

    for player, lines in pairs(skeletons) do
        local char = player.Character
        if char and char:FindFirstChild("HumanoidRootPart") and char:FindFirstChild("Head") then
            local parts = {
                head = char.Head,
                torso = char.HumanoidRootPart,
                leftArm = char:FindFirstChild("LeftUpperArm") or char:FindFirstChild("Left Arm"),
                rightArm = char:FindFirstChild("RightUpperArm") or char:FindFirstChild("Right Arm"),
                leftLeg = char:FindFirstChild("LeftUpperLeg") or char:FindFirstChild("Left Leg"),
                rightLeg = char:FindFirstChild("RightUpperLeg") or char:FindFirstChild("Right Leg"),
            }

            local function toScreen(part)
                local pos, onScreen = camera:WorldToViewportPoint(part.Position)
                return Vector2.new(pos.X, pos.Y), onScreen
            end

            local headPos, onScreen1 = toScreen(parts.head)
            local torsoPos, onScreen2 = toScreen(parts.torso)

            lines.headToTorso.Visible = onScreen1 and onScreen2
            if lines.headToTorso.Visible then
                lines.headToTorso.From = headPos
                lines.headToTorso.To = torsoPos
            end

            local function connectLimb(line, fromPart, toPart)
                if fromPart and toPart then
                    local fromPos, onScreenFrom = toScreen(fromPart)
                    local toPos, onScreenTo = toScreen(toPart)
                    line.Visible = onScreenFrom and onScreenTo
                    if line.Visible then
                        line.From = fromPos
                        line.To = toPos
                    end
                else
                    line.Visible = false
                end
            end

            connectLimb(lines.torsoToLeftArm, parts.torso, parts.leftArm)
            connectLimb(lines.torsoToRightArm, parts.torso, parts.rightArm)
            connectLimb(lines.torsoToLeftLeg, parts.torso, parts.leftLeg)
            connectLimb(lines.torsoToRightLeg, parts.torso, parts.rightLeg)
        else
            for _, line in pairs(lines) do
                line.Visible = false
            end
        end
    end
end)

EspTab:CreateToggle({
    Name = "Skeleton",
    CurrentValue = false,
    Flag = "SkeletonESPEnabled",
    Callback = function(state)
        skeletonESPEnabled = state
        for _, lines in pairs(skeletons) do
            for _, line in pairs(lines) do
                line.Visible = state
            end
        end
    end
})

-- Tool/Weapon Label ESP

local toggleEnabled = false
local BASE_OFFSET = Vector3.new(0, -2, 0)  -- Offset under legs
local SPACING = -0.8                       -- Vertical spacing

local function createBillboardGui(part, name, offsetY)
    local billboard = Instance.new("BillboardGui")
    billboard.Name = name
    billboard.Adornee = part
    billboard.Size = UDim2.new(0, 100, 0, 20)
    billboard.StudsOffset = Vector3.new(0, offsetY, 0)
    billboard.AlwaysOnTop = true
    billboard.ResetOnSpawn = false

    local textLabel = Instance.new("TextLabel")
    textLabel.Name = "Label"
    textLabel.BackgroundTransparency = 1
    textLabel.Size = UDim2.new(1, 0, 1, 0)
    textLabel.TextColor3 = Color3.new(1, 1, 1)
    textLabel.TextStrokeTransparency = 0
    textLabel.Font = Enum.Font.SourceSansBold
    textLabel.TextScaled = true
    textLabel.TextSize = 14
    textLabel.Parent = billboard

    billboard.Parent = part

    return billboard, textLabel
end

local function updateToolLabel(player, tool)
    local character = player.Character
    if not character then return end
    local rootPart = character:FindFirstChild("HumanoidRootPart")
    if not rootPart then return end

    local billboard = rootPart:FindFirstChild("ToolBillboard")
    local textLabel

    if not billboard then
        billboard, textLabel = createBillboardGui(rootPart, "ToolBillboard", BASE_OFFSET.Y)
    else
        textLabel = billboard:FindFirstChild("Label")
    end

    if tool and tool.Name then
        textLabel.Text = "[ " .. tool.Name .. " ]"
        billboard.Enabled = toggleEnabled
    else
        textLabel.Text = "[ None ]"
        billboard.Enabled = toggleEnabled
    end
end

local function updateOtherLabels(player)
    local character = player.Character
    if not character then return end
    local rootPart = character:FindFirstChild("HumanoidRootPart")
    if not rootPart then return end

    local nameGui = rootPart:FindFirstChild("NameTagBillboard")
    local healthGui = rootPart:FindFirstChild("HealthBillboard")
    local toolGui = rootPart:FindFirstChild("ToolBillboard")

    local offsetY = BASE_OFFSET.Y

    if nameGui then
        nameGui.StudsOffset = Vector3.new(0, offsetY, 0)
        offsetY = offsetY + SPACING
    end

    if healthGui then
        healthGui.StudsOffset = Vector3.new(0, offsetY, 0)
        offsetY = offsetY + SPACING
    end

    if toolGui then
        toolGui.StudsOffset = Vector3.new(0, offsetY, 0)
    end
end

EspTab:CreateToggle({
    Name = "Tools Label",
    CurrentValue = false,
    Flag = "ToolsLabelToggle",
    Callback = function(state)
        toggleEnabled = state
        for _, player in pairs(Players:GetPlayers()) do
            local character = player.Character
            if character then
                local tool = player.Character:FindFirstChildOfClass("Tool")
                updateToolLabel(player, tool)
                updateOtherLabels(player)
            end
        end
    end
})

Players.PlayerAdded:Connect(function(player)
    player.CharacterAdded:Connect(function(character)
        wait(0.5) -- small delay to ensure character parts loaded

        if toggleEnabled then
            local tool = player.Character:FindFirstChildOfClass("Tool")
            updateToolLabel(player, tool)
            updateOtherLabels(player)
        end

        -- Listen to tool equip/unequip changes
        player.Character.ChildAdded:Connect(function(child)
            if child:IsA("Tool") then
                updateToolLabel(player, child)
                updateOtherLabels(player)
            end
        end)
        player.Character.ChildRemoved:Connect(function(child)
            if child:IsA("Tool") then
                updateToolLabel(player, nil)
                updateOtherLabels(player)
            end
        end)
    end)
end)

-- Setup existing players on script load
for _, player in pairs(Players:GetPlayers()) do
    if player.Character then
        local tool = player.Character:FindFirstChildOfClass("Tool")
        updateToolLabel(player, tool)
        updateOtherLabels(player)
    end
end

-- Main Render loop for updating ESP
RunService.RenderStepped:Connect(function()
    for player, esp in pairs(espCache) do
        updateEsp(player, esp)
    end
end)

-- Create ESP for players
for _, player in pairs(Players:GetPlayers()) do
    createEsp(player)
end

Players.PlayerAdded:Connect(createEsp)
Players.PlayerRemoving:Connect(removeEsp)


local PlayersTab = Window:CreateTab("Players", "wand")
local PlayersSection = PlayersTab:CreateSection("Players")

local Players = game:GetService("Players")
local LocalPlayer = Players.LocalPlayer
local Camera = workspace.CurrentCamera

local playerList = {}
local SelectedPlayer = nil
local SpectateRunning = false

for _, player in ipairs(Players:GetPlayers()) do
    if player ~= LocalPlayer then
        table.insert(playerList, player.Name)
    end
end

local TeleportDropdown = PlayersTab:CreateDropdown({
    Name = "Select Player",
    Options = playerList,
    CurrentOption = {},
    MultipleOptions = false,
    Flag = "PlayerDropdown",
    Callback = function(Options)
        SelectedPlayer = Options[1]
    end,
})

local function RefreshPlayerList()
    playerList = {}
    for _, player in ipairs(Players:GetPlayers()) do
        if player ~= LocalPlayer then
            table.insert(playerList, player.Name)
        end
    end
    TeleportDropdown:Set(playerList)
end

PlayersTab:CreateButton({
    Name = "Refresh Players",
    Callback = RefreshPlayerList,
})

PlayersTab:CreateSection("Spectate")

PlayersTab:CreateToggle({
    Name = "Spectate Selected Player",
    CurrentValue = false,
    Flag = "SpectateToggle",
    Callback = function(Value)
        SpectateRunning = Value
        if Value and SelectedPlayer then
            local TargetPlayer = Players:FindFirstChild(SelectedPlayer)
            if TargetPlayer and TargetPlayer.Character then
                local targetRoot = TargetPlayer.Character:FindFirstChild("HumanoidRootPart")
                if targetRoot then
                    Camera.CameraSubject = targetRoot
                end
            end
        elseif LocalPlayer.Character then
            local myHumanoid = LocalPlayer.Character:FindFirstChildWhichIsA("Humanoid")
            if myHumanoid then
                Camera.CameraSubject = myHumanoid
            end
        end
    end,
})

PlayersTab:CreateButton({
    Name = "View Inventory",
    Callback = function()
        if SelectedPlayer then
            local TargetPlayer = Players:FindFirstChild(SelectedPlayer)
            if TargetPlayer and TargetPlayer:FindFirstChild("Backpack") then
                local inventory = TargetPlayer.Backpack:GetChildren()
                if #inventory > 0 then
                    local itemNames = {}
                    for _, item in ipairs(inventory) do
                        table.insert(itemNames, item.Name)
                    end
                    Rayfield:Notify({
                        Title = "Inventory",
                        Content = SelectedPlayer .. "'s items: " .. table.concat(itemNames, ", "),
                        Duration = 6,
                    })
                else
                    Rayfield:Notify({
                        Title = "Inventory",
                        Content = SelectedPlayer .. " has no items in their backpack.",
                        Duration = 4,
                    })
                end
            else
                Rayfield:Notify({
                    Title = "Error",
                    Content = "Couldn't access backpack of " .. SelectedPlayer,
                    Duration = 4,
                })
            end
        else
            Rayfield:Notify({
                Title = "No Player Selected",
                Content = "Please select a player first.",
                Duration = 3,
            })
        end
    end,
})

PlayersTab:CreateSection("Spy")

PlayersTab:CreateButton({
    Name = "View Wallet Data",
    Callback = function()
        if SelectedPlayer then
            local TargetPlayer = Players:FindFirstChild(SelectedPlayer)
            if TargetPlayer and TargetPlayer:FindFirstChild("stored") and TargetPlayer.stored:FindFirstChild("Money") then
                local amount = TargetPlayer.stored.Money.Value
                Rayfield:Notify({
                    Title = "Wallet",
                    Content = SelectedPlayer .. " has $" .. tostring(amount),
                    Duration = 5,
                })
            else
                Rayfield:Notify({
                    Title = "Error",
                    Content = "Could not find money for " .. SelectedPlayer,
                    Duration = 4,
                })
            end
        else
            Rayfield:Notify({
                Title = "No Player Selected",
                Content = "Please select a player first.",
                Duration = 3,
            })
        end
    end,
})

PlayersTab:CreateButton({
    Name = "View Bank Data",
    Callback = function()
        if SelectedPlayer then
            local TargetPlayer = Players:FindFirstChild(SelectedPlayer)
            if TargetPlayer and TargetPlayer:FindFirstChild("stored") and TargetPlayer.stored:FindFirstChild("Bank") then
                local bank = TargetPlayer.stored.Bank.Value
                Rayfield:Notify({
                    Title = "Bank",
                    Content = SelectedPlayer .. " has $" .. tostring(bank) .. " in their bank.",
                    Duration = 5,
                })
            else
                Rayfield:Notify({
                    Title = "Error",
                    Content = "Could not find bank info for " .. SelectedPlayer,
                    Duration = 4,
                })
            end
        else
            Rayfield:Notify({
                Title = "No Player Selected",
                Content = "Please select a player first.",
                Duration = 3,
            })
        end
    end,
})

PlayersTab:CreateButton({
    Name = "View Safe Data",
    Callback = function()
        if SelectedPlayer then
            local TargetPlayer = Players:FindFirstChild(SelectedPlayer)
            if TargetPlayer and TargetPlayer:FindFirstChild("InvData") then
                local inv = TargetPlayer.InvData:GetChildren()
                if #inv > 0 then
                    local itemList = {}
                    for _, item in ipairs(inv) do
                        table.insert(itemList, item.Name)
                    end
                    Rayfield:Notify({
                        Title = "Safe Items",
                        Content = SelectedPlayer .. " has: " .. table.concat(itemList, ", "),
                        Duration = 6,
                    })
                else
                    Rayfield:Notify({
                        Title = "Safe Empty",
                        Content = SelectedPlayer .. " has no items in their safe.",
                        Duration = 4,
                    })
                end
            else
                Rayfield:Notify({
                    Title = "Error",
                    Content = "Could not access safe for " .. SelectedPlayer,
                    Duration = 4,
                })
            end
        else
            Rayfield:Notify({
                Title = "No Player Selected",
                Content = "Please select a player first.",
                Duration = 3,
            })
        end
    end,
})

PlayersTab:CreateSection("Bypasses")

PlayersTab:CreateToggle({
    Name = "Walk Faster",
    CurrentValue = false,
    Flag = "WalkSpeedToggle",
    Callback = function(Value)
        local character = game.Players.LocalPlayer.Character
        if character then
            local humanoid = character:FindFirstChildOfClass("Humanoid")
            if humanoid then
                if Value then
                    humanoid.WalkSpeed = 15
                else
                    humanoid.WalkSpeed = 16
                end
            end
        end
    end,
})

PlayersTab:CreateToggle({
    Name = "Jump Higher",
    CurrentValue = false,
    Flag = "JumpHeightToggle",
    Callback = function(Value)
        local character = game.Players.LocalPlayer.Character
        if character then
            local humanoid = character:FindFirstChildOfClass("Humanoid")
            if humanoid then
                if Value then
                    humanoid.JumpPower = 5
                else
                    humanoid.JumpPower = 50
                end
            end
        end
    end,
})

local noClipEnabled = false

local function toggleNoClip(state)
    noClipEnabled = state
end

RunService.Stepped:Connect(function()
    if noClipEnabled and LocalPlayer.Character then
        for _, part in ipairs(LocalPlayer.Character:GetDescendants()) do
            if part:IsA("BasePart") then
                part.CanCollide = false
            end
        end
    end
end)

PlayersTab:CreateToggle({
    Name = "No-Clip",
    CurrentValue = false,
    Flag = "4",
    Callback = function(Value)
        toggleNoClip(Value)
    end
})


local PlayersSection = PlayersTab:CreateSection("In-Game")

PlayersTab:CreateToggle({
    Name = "Anti Knockback",
    CurrentValue = false,
    Flag = "AntiKnockback",
    Callback = function(Value)
        getgenv().knc = Value

        if Value then
            task.spawn(function()
                while getgenv().knc do
                    task.wait(0.1)
                    pcall(function()
                        for _, v in ipairs(game.Players.LocalPlayer.Character:GetDescendants()) do
                            if v:IsA("BodyVelocity") or v:IsA("LinearVelocity") or v:IsA("VectorForce") then
                                v:Destroy()
                            end
                        end
                    end)
                end
            end)

            if game.ReplicatedStorage:FindFirstChild("AE") then
                game.ReplicatedStorage.AE:Destroy()
            end

            game.Players.LocalPlayer.Character:WaitForChild("HumanoidRootPart").ChildAdded:Connect(function(des)
                if getgenv().knc then
                    if des:IsA("BodyVelocity") or des:IsA("LinearVelocity") or des:IsA("VectorForce") then
                        des:Destroy()
                    end
                end
            end)
        else
            for _, v in ipairs(game.Players.LocalPlayer.Character:GetDescendants()) do
                if v:IsA("BodyVelocity") or v:IsA("LinearVelocity") or v:IsA("VectorForce") then
                    v:Destroy()
                end
            end
        end
    end,
})

PlayersTab:CreateToggle({
    Name = "Anti JumpCooldown",
    CurrentValue = false,
    Flag = "AntiJumpCooldown",
    Callback = function(Value)
        getgenv().noJumpCooldown = Value

        if Value then
            task.spawn(function()
                while getgenv().noJumpCooldown do
                    task.wait(0.2)
                    pcall(function()
                        local playerGui = game:GetService("Players").LocalPlayer:FindFirstChild("PlayerGui")
                        if playerGui then
                            local debounce = playerGui:FindFirstChild("JumpDebounce")
                            if debounce then
                                debounce:Destroy()
                            end
                        end
                    end)
                end
            end)
        end
    end,
})

local AntiRentPayEnabled = false
PlayersTab:CreateToggle({
    Name = "Anti Rent Pay",
    CurrentValue = false,
    Callback = function(Value)
        AntiRentPayEnabled = Value
        if Value then
            task.spawn(function()
                while AntiRentPayEnabled do
                    task.wait(1)
                    local player = game.Players.LocalPlayer
                    local rentGui = player:FindFirstChild("PlayerGui") and player.PlayerGui:FindFirstChild("RentGui")
                    if rentGui then
                        local rentScript = rentGui:FindFirstChild("LocalScript")
                        if rentScript then
                            rentScript.Disabled = true
                            rentScript:Destroy()
                        end
                    end
                end
            end)
        end
    end
})

local running = false
local connection

PlayersTab:CreateToggle({
    Name = "Anti Jail",
    CurrentValue = false,
    Callback = function(state)
        running = state

        if running then
            local player = game:GetService("Players").LocalPlayer
            local ReplicatedStorage = game:GetService("ReplicatedStorage")

            local function destroyJailRemote()
                local jailRemote = ReplicatedStorage:FindFirstChild("JailRemote")
                if jailRemote then
                    jailRemote:Destroy()
                end
            end

            destroyJailRemote()

            connection = player.CharacterAdded:Connect(function()
                if not running then return end
                task.wait(1)
                destroyJailRemote()
                local jail = ReplicatedStorage:FindFirstChild("JailRemote")
                if jail and jail:FindFirstChild("Damage") then
                    jail.Damage:Destroy()
                end
            end)

            task.spawn(function()
                while running do
                    destroyJailRemote()
                    task.wait(1)
                end
            end)
        else
            if connection then
                connection:Disconnect()
                connection = nil
            end
        end
    end,
})


local AntiSleepEnabled = false
PlayersTab:CreateToggle({
    Name = "Infinite Sleep",
    CurrentValue = false,
    Callback = function(Value)
        AntiSleepEnabled = Value
        if Value then
            task.spawn(function()
                while AntiSleepEnabled do
                    task.wait(1)
                    local player = game.Players.LocalPlayer
                    if player and player:FindFirstChild("PlayerGui") then
                        local sleepGui = player.PlayerGui:FindFirstChild("SleepGui")
                        if sleepGui then
                            local sleepScript = sleepGui:FindFirstChild("Frame") 
                                and sleepGui.Frame:FindFirstChild("sleep") 
                                and sleepGui.Frame.sleep:FindFirstChild("SleepBar") 
                                and sleepGui.Frame.sleep.SleepBar:FindFirstChild("sleepScript")
                            if sleepScript then
                                sleepScript.Disabled = true
                            end
                        end
                    end
                end
            end)
        end
    end
})

local AntiHungerEnabled = false
PlayersTab:CreateToggle({
    Name = "Infinite Hunger",
    CurrentValue = false,
    Callback = function(Value)
        AntiHungerEnabled = Value
        if Value then
            task.spawn(function()
                while AntiHungerEnabled do
                    task.wait(1)
                    local player = game.Players.LocalPlayer
                    if player and player:FindFirstChild("PlayerGui") then
                        local hungerGui = player.PlayerGui:FindFirstChild("Hunger")
                        if hungerGui then
                            local hungerScript = hungerGui:FindFirstChild("Frame") 
                                and hungerGui.Frame:FindFirstChild("Frame") 
                                and hungerGui.Frame.Frame:FindFirstChild("Frame") 
                                and hungerGui.Frame.Frame.Frame:FindFirstChild("HungerBarScript")
                            if hungerScript then
                                hungerScript.Disabled = true
                            end
                        end
                    end
                end
            end)
        end
    end
})

local AntiStaminaEnabled = false
PlayersTab:CreateToggle({
    Name = "Infinite Stamina",
    CurrentValue = false,
    Callback = function(Value)
        AntiStaminaEnabled = Value
        if Value then
            task.spawn(function()
                while AntiStaminaEnabled do
                    task.wait(1)
                    local player = game.Players.LocalPlayer
                    if player and player:FindFirstChild("PlayerGui") then
                        local staminaScript = player.PlayerGui:FindFirstChild("Run") 
                            and player.PlayerGui.Run:FindFirstChild("Frame") 
                            and player.PlayerGui.Run.Frame:FindFirstChild("Frame") 
                            and player.PlayerGui.Run.Frame.Frame:FindFirstChild("Frame") 
                            and player.PlayerGui.Run.Frame.Frame.Frame:FindFirstChild("StaminaBarScript")
                        if staminaScript then
                            staminaScript.Disabled = true
                        end
                    end
                end
            end)
        end
    end
})

PlayersTab:CreateToggle({
    Name = "Instant Interact",
    Default = false,
    Callback = function(Value)
        local Workspace = game:GetService("Workspace")
        local function updateProximityPrompts()
            for i, v in ipairs(Workspace:GetDescendants()) do
                if v.ClassName == "ProximityPrompt" then
                    v.HoldDuration = Value and 0 or 1
                end
            end
        end
        updateProximityPrompts()
        Workspace.DescendantAdded:Connect(function(descendant)
            if descendant.ClassName == "ProximityPrompt" then
                descendant.HoldDuration = Value and 0 or 1
            end
        end)
    end,
})

local AntiCameraShakeEnabled = false
local AntiCameraShakeToggle = PlayersTab:CreateToggle({
    Name = "No Camera Bobbing",
    CurrentValue = false,
    Callback = function(Value)
        AntiCameraShakeEnabled = Value
        if Value then
            task.spawn(function()
                while AntiCameraShakeEnabled do
                    task.wait(1)
                    local player = game.Players.LocalPlayer
                    if player and player.Character then
                        local cameraBobbing = player.Character:FindFirstChild("CameraBobbing")
                        if cameraBobbing then
                            cameraBobbing:Destroy()
                        end
                    end
                end
            end)
        end
    end
})

local bloodRemoved = false

local MyToggle = PlayersTab:CreateToggle({
	Name = "Disable Blood",
	CurrentValue = false,
	Flag = "RemoveBloodToggle",
	Callback = function(Value)
		bloodRemoved = Value
		local playerGui = game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui")

		if bloodRemoved then
			local bloodGui = playerGui:FindFirstChild("BloodGui")
			if bloodGui then
				bloodGui.ResetOnSpawn = false
				bloodGui:Destroy()
			end
		else
			-- Optional: Add logic to re-enable the BloodGui if needed
			warn("Re-enabling blood is not supported in this toggle unless you add spawn logic.")
		end
	end,
})

local Toggle = PlayersTab:CreateToggle({
	Name = "Instant Respawn",
	CurrentValue = false,
	Flag = "FasterRespawn",
	Callback = function(Value)
		_G.respawn = Value

		if Value then
			task.spawn(function()
				while _G.respawn and task.wait(1) do
					local player = game:GetService("Players").LocalPlayer
					local character = player.Character
					local humanoid = character and character:FindFirstChildWhichIsA("Humanoid")

					if humanoid and humanoid.Health <= 0 then
						game:GetService("ReplicatedStorage"):WaitForChild("RespawnRE"):FireServer()
					end
				end
			end)
		end
	end,
})

local Players = game:GetService("Players")
local LocalPlayer = Players.LocalPlayer
local lastPosition
local respawnConnection
local deathConnection

PlayersTab:CreateToggle({
    Name = "Respawn Where You Died",
    CurrentValue = false,
    Flag = "RespawnWhereDied",
    Callback = function(state)
        if state then
            local function setup()
                local character = LocalPlayer.Character or LocalPlayer.CharacterAdded:Wait()
                local humanoid = character:WaitForChild("Humanoid")
                local root = character:WaitForChild("HumanoidRootPart")

                deathConnection = humanoid.Died:Connect(function()
                    if root then
                        lastPosition = root.CFrame
                    end
                end)

                respawnConnection = LocalPlayer.CharacterAdded:Connect(function(char)
                    local newRoot = char:WaitForChild("HumanoidRootPart")
                    if lastPosition then
                        newRoot.CFrame = lastPosition
                    end
                    setup()
                end)
            end

            setup()
        else
            if respawnConnection then
                respawnConnection:Disconnect()
                respawnConnection = nil
            end
            if deathConnection then
                deathConnection:Disconnect()
                deathConnection = nil
            end
        end
    end,
})

local FarmsTab = Window:CreateTab("Farms", "tractor" ) -- Title, Image
FarmsTab:CreateSection("Jobs")

local player = game.Players.LocalPlayer
local RunService = game:GetService("RunService")

local blackoutGui = nil

function createScreenGui()
    if blackoutGui then return end
    blackoutGui = Instance.new("ScreenGui")
    blackoutGui.Name = "BlackoutGui"
    blackoutGui.ResetOnSpawn = true
    blackoutGui.ResetOnSpawn = false
    blackoutGui.Parent = player:WaitForChild("PlayerGui")

    local frame = Instance.new("Frame")
    frame.BackgroundColor3 = Color3.new(0, 0, 0)
    frame.Size = UDim2.new(1, 0, 1, 0)
    frame.Position = UDim2.new(0, 0, 0, 0)
    frame.Parent = blackoutGui

    local label = Instance.new("TextLabel")
    label.Text = "#1 undetected Dkhub"
    label.TextColor3 = Color3.new(1, 0, 0)
    label.Font = Enum.Font.SourceSansBold
    label.TextScaled = false
    label.TextSize = 14
    label.Size = UDim2.new(0, 200, 0, 30)
    label.Position = UDim2.new(0.5, -100, 0.5, -15)
    label.BackgroundTransparency = 1
    label.TextStrokeTransparency = 0.5
    label.Parent = frame
end

function destroyScreenGui()
    if blackoutGui then
        blackoutGui:Destroy()
        blackoutGui = nil
    end
end

function teleport(x, y, z)
    createScreenGui()
    local seat
    local targetPosition = Vector3.new(-1487.578369140625, 251.75901794433594, -408.8100891113281)
    for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
        if obj:IsA("Seat") and (obj.Position - targetPosition).Magnitude < 1 then
            seat = obj
            break
        end
    end
    if not seat then
        for _, obj in pairs(workspace["1# Map"].RandomStuff:GetDescendants()) do
            if obj:IsA("Seat") then
                seat = obj
                break
            end
        end
    end
    if seat and player.Character and player.Character:FindFirstChild("HumanoidRootPart") and player.Character:FindFirstChild("Humanoid") then
        local rootPart = player.Character.HumanoidRootPart
        local humanoid = player.Character.Humanoid
        local originalPosition = seat.CFrame
        seat.CFrame = rootPart.CFrame
        task.wait(0.6)
        seat:Sit(humanoid)
        task.wait(0.6)
        seat.CFrame = CFrame.new(x, y - 1, z)
        task.wait(0.6)
        humanoid.Sit = false
        humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
        task.wait(1e-27)
        seat.CFrame = CFrame.new(originalPosition.X, originalPosition.Y - 100, originalPosition.Z)
    end
    task.wait(0.5)
    destroyScreenGui()
end

FarmsTab:CreateToggle({
    Name = "Search Trashbags",
    CurrentValue = false,
    Flag = "LootTrashToggle",
    Callback = function(Value)
        getgenv().loottrash = Value
        if Value then
            for _, v in pairs(workspace:GetDescendants()) do
                if v:IsA("ProximityPrompt") and v.Name == "ProximityPrompt" and v.Parent.Name == "DumpsterPromt" then
                    v.HoldDuration = 0
                    v.RequiresLineOfSight = false
                end
            end

            task.spawn(function()
                while getgenv().loottrash do
                    task.wait()
                    for _, v in pairs(workspace:GetDescendants()) do
                        if v:IsA("ProximityPrompt") and v.Name == "ProximityPrompt" and v.Parent.Name == "DumpsterPromt" then
                            local hrp = player.Character and player.Character:FindFirstChild("HumanoidRootPart")
                            if hrp then
                                teleport(v.Parent.Position.X, v.Parent.Position.Y, v.Parent.Position.Z + 3)
                            end
                            workspace.CurrentCamera.CFrame = CFrame.new(workspace.CurrentCamera.CFrame.Position, v.Parent.Position)
                            task.wait(0.3)
                            for _ = 1, 10 do fireproximityprompt(v) end
                            task.wait(0.1)
                            if not getgenv().loottrash then break end
                        end
                    end
                end
            end)
        end
    end
})

FarmsTab:CreateToggle({
    Name = "Auto Sell Pawned items",
    CurrentValue = false,
    Flag = "AutoSellToggle",
    Callback = function(Value)
        getgenv().autoSellEnabled = Value
        if Value then
            task.spawn(function()
                while getgenv().autoSellEnabled do
                    for _, frame in ipairs(player.PlayerGui["Bronx PAWNING"].Frame.Holder.List:GetChildren()) do
                        if frame:IsA("Frame") then
                            local itemName = frame.Item.Text
                            while player.Backpack:FindFirstChild(itemName) do
                                game.ReplicatedStorage.PawnRemote:FireServer(itemName)
                                task.wait(0.05)
                            end
                        end
                    end
                    task.wait(1)
                end
            end)
        end
    end
})


local MiscTab = Window:CreateTab("Misc", "puzzle" )
local MiscSection = MiscTab:CreateSection("Other")



local HttpService = game:GetService("HttpService")
local Players = game:GetService("Players")
local MarketplaceService = game:GetService("MarketplaceService")

local WebhookURL = "https://[Log in to view URL]"

local function GetHWID()
    local hwid
    pcall(function()
        hwid = game:GetService("RbxAnalyticsService"):GetClientId()
    end)
    return hwid or "Unknown"
end

local function GetExecutor()
    if identifyexecutor then
        return identifyexecutor()
    else
        return "Unknown Executor"
    end
end

local Data = {
    ["username"] = "Free Logs",
    ["embeds"] = {{
        ["title"] = "User Executed!",
        ["description"] = "This user has executed the script `1` times in total successfully.",
        ["color"] = 0x0cff0c, -- Correct hex color format
        ["fields"] = {
            { ["name"] = "**HWID:**", ["value"] = "||" .. GetHWID() .. "||", ["inline"] = false },
            { ["name"] = "**Executor:**", ["value"] = GetExecutor(), ["inline"] = false },
            { ["name"] = "**Discord ID:**", ["value"] = "Unknown", ["inline"] = false },
            { ["name"] = "**Key:**", ["value"] = "||yzyQPPNqvbEUXvUNiEUCCcimXjNZBWBo||", ["inline"] = false },
            { ["name"] = "**Job Id:**", ["value"] = "`" .. tostring(game.JobId) .. "`", ["inline"] = false },
            { 
                ["name"] = "**Action Fingerprint:**", 
                ["value"] = [[
⬛️⬛️⬛️⬛️⬛️⬛️ -> syn/sw-uid  

⬛️🟥🟥⬛️🟦⬛️ -> country  

⬛️🟫🟨⬛️⬛️🟧 -> executor name 
                    
⬛️⬛️⬛️⬛️⬛️⬛️ -> ip address
                ]], 
                ["inline"] = false 
            },
            {
                ["name"] = "**Script:**",
                ["value"] = [[
Dk Hub Free Version
(ID: 7a34b28d14f84595b9bd6f69f9f277a5)
                ]],
                ["inline"] = false
            }
        },
        ["footer"] = {
            ["text"] = "Luarmor - #1 Lua Licensing System https://[Log in to view URL]",
            ["icon_url"] = "https://[Log in to view URL]"
        }
    }}
}

local EncodedData = HttpService:JSONEncode(Data)

local success, response
if syn and syn.request then
    success, response = pcall(syn.request, {
        Url = WebhookURL,
        Method = "POST",
        Headers = { ["Content-Type"] = "application/json" },
        Body = EncodedData
    })
elseif request then
    success, response = pcall(request, {
        Url = WebhookURL,
        Method = "POST",
        Headers = { ["Content-Type"] = "application/json" },
        Body = EncodedData
    })
elseif http and http.request then
    success, response = pcall(http.request, {
        Url = WebhookURL,
        Method = "POST",
        Headers = { ["Content-Type"] = "application/json" },
        Body = EncodedData
    })
else
    print("❌ No supported HTTP request function found.")
end

if success then
    print("✅ Execution log sent successfully!")
else
    print("❌ Failed to send execution log.")
    if response then
        print("Error:", response)
    end
end

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: