Esp Items
Key Required

Esp Items

AnomicMiniMonkeyGoodMiniMonkeyGood 174 views 387 executesUpdated Jul 31, 2026
Unrated
00
Lua Script•584 lines (21628 chars)
-- ROBLOX SERVICES
local UserInputService = game:GetService("UserInputService")
local RunService = game:GetService("RunService")
local Players = game:GetService("Players")
local Workspace = game:GetService("Workspace")

local player = Players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")
local camera = Workspace.CurrentCamera

-- GLOBAL SYSTEM STATES & CONFIGS
local systemActive = true
local highlightsEnabled = true
local espEnabled = true
local focusedModel = nil 
local MAX_RENDER_DISTANCE = 1000 -- Maximum distance to render ESP
local activeTab = "Items" -- "Items" ou "Vehicles"

local trackedEntities = {}
local scriptConnections = {}

-- WAIT FOR FOLDERS
local entitiesFolder = Workspace:WaitForChild("Entities", 10)
local vehiclesFolder = Workspace:WaitForChild("PlayerVehicles", 10)

if not entitiesFolder then warn("Folder 'Entities' not found in Workspace!") end
if not vehiclesFolder then warn("Folder 'PlayerVehicles' not found in Workspace!") end

-- MAIN INTERFACE SETTINGS
local screenGui = Instance.new("ScreenGui")
screenGui.Name = "EntityTrackerSupremo"
screenGui.IgnoreGuiInset = true
screenGui.ResetOnSpawn = false
screenGui.Parent = playerGui

-- DIRECTIONAL ARROW FOR FOCUSED TARGET
local pointerContainer = Instance.new("Frame")
pointerContainer.Name = "PointerContainer"
pointerContainer.Size = UDim2.new(0, 0, 0, 0)
pointerContainer.Position = UDim2.new(0.5, 0, 0.5, 0)
pointerContainer.BackgroundTransparency = 1
pointerContainer.Visible = false
pointerContainer.Parent = screenGui

local pointerIcon = Instance.new("TextLabel")
pointerIcon.Size = UDim2.new(0, 50, 0, 50)
pointerIcon.Position = UDim2.new(0.5, -25, 0, -200)
pointerIcon.BackgroundTransparency = 1
pointerIcon.Text = "▲"
pointerIcon.TextColor3 = Color3.fromRGB(255, 255, 255)
pointerIcon.Font = Enum.Font.GothamBlack
pointerIcon.TextSize = 45
pointerIcon.TextStrokeColor3 = Color3.fromRGB(0, 0, 0)
pointerIcon.TextStrokeTransparency = 0.3
pointerIcon.Parent = pointerContainer

local mainFrame = Instance.new("Frame")
mainFrame.Size = UDim2.new(0, 390, 0, 500)
mainFrame.Position = UDim2.new(0, 40, 0, 40)
mainFrame.BackgroundColor3 = Color3.fromRGB(15, 15, 22)
mainFrame.BorderSizePixel = 0
mainFrame.Parent = screenGui

Instance.new("UICorner", mainFrame).CornerRadius = UDim.new(0, 12)
local mainStroke = Instance.new("UIStroke", mainFrame)
mainStroke.Color = Color3.fromRGB(60, 60, 80)
mainStroke.Thickness = 2

-- DRAG BAR
local dragBar = Instance.new("TextLabel")
dragBar.Size = UDim2.new(1, -45, 0, 40)
dragBar.BackgroundColor3 = Color3.fromRGB(22, 22, 32)
dragBar.Text = "  RADAR V2 (SEPARATED TABS)"
dragBar.TextColor3 = Color3.fromRGB(222, 255, 154)
dragBar.TextXAlignment = Enum.TextXAlignment.Left
dragBar.Font = Enum.Font.GothamBold
dragBar.TextSize = 12
dragBar.Parent = mainFrame
Instance.new("UICorner", dragBar).CornerRadius = UDim.new(0, 12)

-- CLOSE BUTTON (X)
local closeBtn = Instance.new("TextButton")
closeBtn.Size = UDim2.new(0, 32, 0, 32)
closeBtn.Position = UDim2.new(1, -38, 0, 4)
closeBtn.BackgroundColor3 = Color3.fromRGB(230, 50, 50)
closeBtn.Text = "X"
closeBtn.TextColor3 = Color3.new(1, 1, 1)
closeBtn.Font = Enum.Font.GothamBlack
closeBtn.TextSize = 14
closeBtn.Parent = mainFrame
Instance.new("UICorner", closeBtn).CornerRadius = UDim.new(0, 8)

-- CONTROL PANEL
local controlPanel = Instance.new("Frame")
controlPanel.Size = UDim2.new(1, -20, 0, 40)
controlPanel.Position = UDim2.new(0, 10, 0, 48)
controlPanel.BackgroundTransparency = 1
controlPanel.Parent = mainFrame

local hlToggle = Instance.new("TextButton")
hlToggle.Size = UDim2.new(0, 170, 0, 32)
hlToggle.BackgroundColor3 = Color3.fromRGB(40, 180, 100)
hlToggle.Text = "HIGHLIGHTS: ON"
hlToggle.Font = Enum.Font.GothamBold
hlToggle.TextSize = 11
hlToggle.TextColor3 = Color3.new(1, 1, 1)
hlToggle.Parent = controlPanel
Instance.new("UICorner", hlToggle).CornerRadius = UDim.new(0, 6)

local espToggle = Instance.new("TextButton")
espToggle.Size = UDim2.new(0, 170, 0, 32)
espToggle.Position = UDim2.new(1, -170, 0, 0)
espToggle.BackgroundColor3 = Color3.fromRGB(40, 180, 100)
espToggle.Text = "TEXT ESP: ON"
espToggle.Font = Enum.Font.GothamBold
espToggle.TextSize = 11
espToggle.TextColor3 = Color3.new(1, 1, 1)
espToggle.Parent = controlPanel
Instance.new("UICorner", espToggle).CornerRadius = UDim.new(0, 6)

-- TABS SYSTEM
local tabContainer = Instance.new("Frame")
tabContainer.Size = UDim2.new(1, -20, 0, 30)
tabContainer.Position = UDim2.new(0, 10, 0, 95)
tabContainer.BackgroundTransparency = 1
tabContainer.Parent = mainFrame

local itemsTabBtn = Instance.new("TextButton")
itemsTabBtn.Size = UDim2.new(0.5, -5, 1, 0)
itemsTabBtn.BackgroundColor3 = Color3.fromRGB(80, 80, 110)
itemsTabBtn.Text = "ITEMS"
itemsTabBtn.Font = Enum.Font.GothamBold
itemsTabBtn.TextSize = 12
itemsTabBtn.TextColor3 = Color3.new(1, 1, 1)
itemsTabBtn.Parent = tabContainer
Instance.new("UICorner", itemsTabBtn).CornerRadius = UDim.new(0, 6)

local vehiclesTabBtn = Instance.new("TextButton")
vehiclesTabBtn.Size = UDim2.new(0.5, -5, 1, 0)
vehiclesTabBtn.Position = UDim2.new(0.5, 5, 0, 0)
vehiclesTabBtn.BackgroundColor3 = Color3.fromRGB(35, 35, 45)
vehiclesTabBtn.Text = "VEHICLES"
vehiclesTabBtn.Font = Enum.Font.GothamBold
vehiclesTabBtn.TextSize = 12
vehiclesTabBtn.TextColor3 = Color3.new(1, 1, 1)
vehiclesTabBtn.Parent = tabContainer
Instance.new("UICorner", vehiclesTabBtn).CornerRadius = UDim.new(0, 6)

-- SCROLL LISTS 
local scrollItems = Instance.new("ScrollingFrame")
scrollItems.Size = UDim2.new(1, -20, 1, -140)
scrollItems.Position = UDim2.new(0, 10, 0, 130)
scrollItems.BackgroundTransparency = 1
scrollItems.ScrollBarThickness = 5
scrollItems.ScrollBarImageColor3 = Color3.fromRGB(100, 100, 130)
scrollItems.CanvasSize = UDim2.new(0, 0, 0, 0)
scrollItems.Parent = mainFrame

local scrollVehicles = Instance.new("ScrollingFrame")
scrollVehicles.Size = UDim2.new(1, -20, 1, -140)
scrollVehicles.Position = UDim2.new(0, 10, 0, 130)
scrollVehicles.BackgroundTransparency = 1
scrollVehicles.ScrollBarThickness = 5
scrollVehicles.ScrollBarImageColor3 = Color3.fromRGB(100, 100, 130)
scrollVehicles.CanvasSize = UDim2.new(0, 0, 0, 0)
scrollVehicles.Visible = false
scrollVehicles.Parent = mainFrame

local layoutItems = Instance.new("UIListLayout", scrollItems)
layoutItems.SortOrder = Enum.SortOrder.LayoutOrder
layoutItems.Padding = UDim.new(0, 8)

local layoutVehicles = Instance.new("UIListLayout", scrollVehicles)
layoutVehicles.SortOrder = Enum.SortOrder.LayoutOrder
layoutVehicles.Padding = UDim.new(0, 8)

-- UPDATE INTERNAL COLORS & UI STATES
local function refreshVisuals()
    for model, data in pairs(trackedEntities) do
        local isFocused = (focusedModel == model)
        local baseColor = data.CustomColor
        local isCorrectTab = (data.Category == activeTab)
        
        -- O highlight só funciona se pertencer à aba atual
        if data.HighlightObj then
            data.HighlightObj.FillColor = Color3.fromRGB(255, 170, 0)
            data.HighlightObj.Enabled = (isFocused and highlightsEnabled and isCorrectTab)
        end
        
        -- Atualiza as cores do ESP
        if data.EspObj then
            local textLabel = data.EspObj:FindFirstChild("TextLabel")
            if textLabel then
                textLabel.TextColor3 = isFocused and Color3.fromRGB(255, 170, 0) or baseColor
                textLabel.TextSize = isFocused and 14 or 11
            end
            
            -- Se não for da aba correta, força o ESP a desligar imediatamente
            if not isCorrectTab then
                data.EspObj.Enabled = false
            end
        end

        -- Atualiza os botões da UI (Garante que botões desmarcados voltem ao normal)
        if data.UIEntry then
            local btn = data.UIEntry:FindFirstChild("TextButton")
            if btn then
                if isFocused then
                    btn.Text = "🌟 FOCUSED"
                    btn.BackgroundColor3 = baseColor
                else
                    btn.Text = "🎯 FOCUS"
                    btn.BackgroundColor3 = Color3.fromRGB(45, 45, 60)
                end
            end
        end
    end
end

-- TAB LOGIC
itemsTabBtn.MouseButton1Click:Connect(function()
    activeTab = "Items"
    scrollItems.Visible = true
    scrollVehicles.Visible = false
    itemsTabBtn.BackgroundColor3 = Color3.fromRGB(80, 80, 110)
    vehiclesTabBtn.BackgroundColor3 = Color3.fromRGB(35, 35, 45)
    focusedModel = nil -- Reseta o focus ao trocar de aba
    refreshVisuals()
end)

vehiclesTabBtn.MouseButton1Click:Connect(function()
    activeTab = "Vehicles"
    scrollItems.Visible = false
    scrollVehicles.Visible = true
    itemsTabBtn.BackgroundColor3 = Color3.fromRGB(35, 35, 45)
    vehiclesTabBtn.BackgroundColor3 = Color3.fromRGB(80, 80, 110)
    focusedModel = nil -- Reseta o focus ao trocar de aba
    refreshVisuals()
end)

-- BULLETPROOF MANUAL RESIZING SYSTEM
table.insert(scriptConnections, layoutItems:GetPropertyChangedSignal("AbsoluteContentSize"):Connect(function()
    scrollItems.CanvasSize = UDim2.new(0, 0, 0, layoutItems.AbsoluteContentSize.Y + 15)
end))
table.insert(scriptConnections, layoutVehicles:GetPropertyChangedSignal("AbsoluteContentSize"):Connect(function()
    scrollVehicles.CanvasSize = UDim2.new(0, 0, 0, layoutVehicles.AbsoluteContentSize.Y + 15)
end))

-- EXTRACT PREDOMINANT COLOR
local function getPredominantColor(model)
    local dominantColor = Color3.fromRGB(0, 255, 180)
    for _, desc in pairs(model:GetChildren()) do
        if desc:IsA("BasePart") then
            dominantColor = desc.Color
            break
        end
    end
    return dominantColor
end

-- LOGIC TO DRAG THE GUI
local dragging, dragInput, dragStart, startPos
dragBar.InputBegan:Connect(function(input)
    if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
        dragging = true
        dragStart = input.Position
        startPos = mainFrame.Position
        input.Changed:Connect(function()
            if input.UserInputState == Enum.UserInputState.End then dragging = false end
        end)
    end
end)
UserInputService.InputChanged:Connect(function(input)
    if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then
        dragInput = input
    end
end)
table.insert(scriptConnections, RunService.Heartbeat:Connect(function()
    if dragging and dragInput then
        local delta = dragInput.Position - dragStart
        mainFrame.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y)
    end
end))

-- VIEWPORT FRAME SETUP
local function setupSmartViewport(vp, sourceObject)
    local cam = Instance.new("Camera")
    cam.FieldOfView = 50
    vp.CurrentCamera = cam
    cam.Parent = vp

    local clone = sourceObject:Clone()
    for _, child in pairs(clone:GetDescendants()) do
        if child:IsA("LuaSourceContainer") or child:IsA("ProximityPrompt") or child:IsA("BillboardGui") then
            child:Destroy()
        end
    end
    clone.Parent = vp

    local size
    if clone:IsA("Model") then
        local originCFrame, modelSize = clone:GetBoundingBox()
        size = modelSize
        clone:PivotTo(CFrame.new(0, 0, 0))
    else
        size = clone.Size
        clone.CFrame = CFrame.new(0, 0, 0)
    end

    local maxDim = math.max(size.X, size.Y, size.Z)
    local distance = (maxDim / 2) / math.tan(math.rad(cam.FieldOfView / 2))
    
    cam.CFrame = CFrame.new(Vector3.new(distance * 1.2, maxDim * 0.5, distance * 1.2), Vector3.new(0, 0, 0))
end

-- REMOVE FROM LIST
local function removeEntityFromList(model)
    local data = trackedEntities[model]
    if data then
        if data.HighlightObj then data.HighlightObj:Destroy() end
        if data.EspObj then data.EspObj:Destroy() end
        if data.UIEntry then data.UIEntry:Destroy() end
        if data.CleanupConnections then
            for _, c in pairs(data.CleanupConnections) do c:Disconnect() end
        end
        
        trackedEntities[model] = nil
        if focusedModel == model then focusedModel = nil end
    end
end

-- ADD ELEMENTS ASYNCHRONOUSLY
local function addEntityToList(model, category)
    if not systemActive or trackedEntities[model] then return end
    
    task.defer(function()
        if not model:IsDescendantOf(Workspace) then return end

        local entityNameText = "Unidentified"
        local foundValueObj = nil
        local adornTarget = nil

        if category == "Vehicles" then
            entityNameText = model.Name
            adornTarget = model.PrimaryPart or model:FindFirstChildWhichIsA("BasePart")
        else
            local handle = model:WaitForChild("Handle", 3)
            adornTarget = handle or model.PrimaryPart or model:FindFirstChildWhichIsA("BasePart")
            if not adornTarget then return end

            if handle then
                local toolBG = handle:WaitForChild("ToolBG", 2)
                if toolBG and toolBG:IsA("BillboardGui") then
                    local toolName = toolBG:WaitForChild("ToolName", 2)
                    if toolName and toolName:IsA("StringValue") then
                        foundValueObj = toolName
                        if toolName.Value ~= "" then
                            entityNameText = tostring(toolName.Value)
                        end
                    end
                end
            end
        end

        if not adornTarget then return end
        local objectDominantColor = getPredominantColor(model)

        -- Create Highlight
        local hl = Instance.new("Highlight")
        hl.FillColor = Color3.fromRGB(255, 170, 0)
        hl.OutlineColor = Color3.fromRGB(255, 255, 255)
        hl.FillTransparency = 0.5
        hl.Enabled = false 
        hl.Parent = model

        -- Create ESP
        local bbg = Instance.new("BillboardGui")
        bbg.Size = UDim2.new(0, 200, 0, 40)
        bbg.AlwaysOnTop = true
        bbg.StudsOffset = Vector3.new(0, 4, 0)
        bbg.Enabled = false 
        
        local lbl = Instance.new("TextLabel")
        lbl.Size = UDim2.new(1, 0, 1, 0)
        lbl.BackgroundTransparency = 1
        lbl.Text = entityNameText
        lbl.TextColor3 = objectDominantColor
        lbl.Font = Enum.Font.GothamBold
        lbl.TextSize = 11
        lbl.TextStrokeTransparency = 0.2
        lbl.Parent = bbg
        bbg.Parent = adornTarget

        -- UI Creation
        local entryName = model:GetDebugId() .. "_entry"
        local entry = Instance.new("Frame")
        entry.Name = entryName
        entry.Size = UDim2.new(1, -12, 0, 75) 
        entry.BackgroundColor3 = Color3.fromRGB(24, 24, 30)
        entry.LayoutOrder = -os.clock()
        entry.Parent = (category == "Vehicles") and scrollVehicles or scrollItems
        Instance.new("UICorner", entry).CornerRadius = UDim.new(0, 8)

        local data = {
            Model = model,
            Category = category, -- Guardando a qual aba pertence
            TargetPart = adornTarget,
            NameValueObj = foundValueObj,
            FallbackName = entityNameText,
            CustomColor = objectDominantColor, 
            HighlightObj = hl,
            EspObj = bbg,
            UIEntry = entry,
            CleanupConnections = {}
        }
        trackedEntities[model] = data

        local vp = Instance.new("ViewportFrame")
        vp.Size = UDim2.new(0, 65, 0, 65)
        vp.Position = UDim2.new(0, 5, 0.5, -32.5)
        vp.BackgroundTransparency = 1
        vp.Parent = entry
        task.spawn(setupSmartViewport, vp, model)

        local nameLabel = Instance.new("TextLabel")
        nameLabel.Size = UDim2.new(1, -180, 0, 30)
        nameLabel.Position = UDim2.new(0, 80, 0, 5)
        nameLabel.Text = entityNameText:sub(1, 20)
        nameLabel.TextColor3 = objectDominantColor
        nameLabel.BackgroundTransparency = 1
        nameLabel.Font = Enum.Font.GothamBold
        nameLabel.TextSize = 13
        nameLabel.TextXAlignment = Enum.TextXAlignment.Left
        nameLabel.Parent = entry

        -- ATUALIZAÇÃO DINÂMICA
        if foundValueObj then
            table.insert(data.CleanupConnections, foundValueObj:GetPropertyChangedSignal("Value"):Connect(function()
                local newName = tostring(foundValueObj.Value)
                if newName ~= "" then
                    data.FallbackName = newName
                    nameLabel.Text = newName:sub(1, 20)
                end
            end))
        end

        local focusBtn = Instance.new("TextButton")
        focusBtn.Size = UDim2.new(0, 85, 0, 26)
        focusBtn.Position = UDim2.new(1, -95, 0, 40)
        focusBtn.BackgroundColor3 = Color3.fromRGB(45, 45, 60)
        focusBtn.Text = "🎯 FOCUS"
        focusBtn.Font = Enum.Font.GothamBold
        focusBtn.TextSize = 10
        focusBtn.TextColor3 = Color3.new(1, 1, 1)
        focusBtn.Parent = entry
        local strokeBtn = Instance.new("UIStroke", focusBtn)
        strokeBtn.Color = objectDominantColor
        strokeBtn.Thickness = 1
        Instance.new("UICorner", focusBtn).CornerRadius = UDim.new(0, 6)

        focusBtn.MouseButton1Click:Connect(function()
            if focusedModel == model then
                focusedModel = nil
            else
                focusedModel = model
            end
            refreshVisuals()
        end)

        table.insert(data.CleanupConnections, model.Destroying:Connect(function() removeEntityFromList(model) end))
    end)
end

-- INTERFACE CONTROLS
hlToggle.MouseButton1Click:Connect(function()
    highlightsEnabled = not highlightsEnabled
    hlToggle.BackgroundColor3 = highlightsEnabled and Color3.fromRGB(40, 180, 100) or Color3.fromRGB(180, 50, 50)
    hlToggle.Text = highlightsEnabled and "HIGHLIGHTS: ON" or "HIGHLIGHTS: OFF"
    refreshVisuals()
end)

espToggle.MouseButton1Click:Connect(function()
    espEnabled = not espEnabled
    espToggle.BackgroundColor3 = espEnabled and Color3.fromRGB(40, 180, 100) or Color3.fromRGB(180, 50, 50)
    espToggle.Text = espEnabled and "TEXT ESP: ON" or "TEXT ESP: OFF"
    refreshVisuals()
end)

-- OPTIMIZED DISTANCE / ESP LOOP
task.spawn(function()
    while systemActive do
        local char = player.Character
        local root = char and char:FindFirstChild("HumanoidRootPart")
        
        if root then
            for model, data in pairs(trackedEntities) do
                local targetPart = data.TargetPart
                if targetPart and targetPart:IsDescendantOf(Workspace) then
                    local dist = (root.Position - targetPart.Position).Magnitude
                    
                    -- NOVO: O ESP só aparece se o item pertencer à aba atual (activeTab)
                    if dist <= MAX_RENDER_DISTANCE and espEnabled and data.Category == activeTab then
                        data.EspObj.Enabled = true
                        
                        local baseText = data.FallbackName
                        if data.NameValueObj and data.NameValueObj.Parent then
                            baseText = tostring(data.NameValueObj.Value)
                        end
                        
                        data.EspObj.TextLabel.Text = string.format("[%s]", baseText)
                    else
                        data.EspObj.Enabled = false
                    end
                end
            end
        end
        task.wait(0.25)
    end
end)

-- SMOOTH POINTER LOOP
table.insert(scriptConnections, RunService.RenderStepped:Connect(function()
    if not systemActive then return end
    
    if focusedModel then
        local trackedData = trackedEntities[focusedModel]
        local targetPart = trackedData and trackedData.TargetPart
        
        if targetPart and targetPart:IsDescendantOf(Workspace) then
            pointerContainer.Visible = true
            pointerIcon.TextColor3 = trackedData.CustomColor
            
            local targetPos = targetPart.Position
            local relativeSpace = camera.CFrame:PointToObjectSpace(targetPos)
            local angle = math.atan2(relativeSpace.X, -relativeSpace.Z)
            
            pointerContainer.Rotation = math.deg(angle)
        else
            pointerContainer.Visible = false
        end
    else
        pointerContainer.Visible = false
    end
end))

-- INITIAL LOADING
task.spawn(function()
    if entitiesFolder then
        for i, child in pairs(entitiesFolder:GetChildren()) do
            if child:IsA("Model") then addEntityToList(child, "Items") end
            if i % 10 == 0 then task.wait() end 
        end
    end
    if vehiclesFolder then
        for i, child in pairs(vehiclesFolder:GetChildren()) do
            if child:IsA("Model") then addEntityToList(child, "Vehicles") end
            if i % 10 == 0 then task.wait() end 
        end
    end
end)

-- AUTO-UPDATE (Quando novos itens/veículos surgem)
if entitiesFolder then
    table.insert(scriptConnections, entitiesFolder.ChildAdded:Connect(function(child)
        task.wait(0.1)
        if child:IsA("Model") then addEntityToList(child, "Items") end
    end))
end

if vehiclesFolder then
    table.insert(scriptConnections, vehiclesFolder.ChildAdded:Connect(function(child)
        task.wait(0.1)
        if child:IsA("Model") then addEntityToList(child, "Vehicles") end
    end))
end

-- CLEANUP
closeBtn.MouseButton1Click:Connect(function()
    systemActive = false
    for _, conn in pairs(scriptConnections) do conn:Disconnect() end
    for model, _ in pairs(trackedEntities) do removeEntityFromList(model) end
    trackedEntities = {}
    screenGui:Destroy()
end)

Features & Information

This script allows you to locate items and vehicles

Community Comments (0)

No comments yet for this script.

More Scripts for Anomic