-- Script Local para Roblox - UI de Coordenadas local Players = game:GetService("Players") local UserInputService = game:GetService("UserInputService") local TweenService = game:GetService("TweenService") local player = Players.LocalPlayer local playerGui = player:WaitForChild("PlayerGui") -- Função para obter as coordenadas do jogador local function getPlayerCoordinates() if player.Character and player.Character:FindFirstChild("HumanoidRootPart") then local position = player.Character.HumanoidRootPart.Position return string.format("%.2f, %.2f, %.2f", position.X, position.Y, position.Z) end return "0, 0, 0" end -- Função para copiar texto para a área de transferência local function copyToClipboard(text) if setclipboard then setclipboard(text) elseif syn and syn.write_clipboard then syn.write_clipboard(text) else warn("Função de copiar não disponível neste executor") end end -- Função para criar a UI local function createCoordinatesUI() -- Verifica se já existe uma UI if playerGui:FindFirstChild("CoordinatesUI") then playerGui.CoordinatesUI:Destroy() end -- Criar ScreenGui local screenGui = Instance.new("ScreenGui") screenGui.Name = "CoordinatesUI" screenGui.Parent = playerGui -- Frame principal local mainFrame = Instance.new("Frame") mainFrame.Name = "MainFrame" mainFrame.Size = UDim2.new(0, 300, 0, 120) mainFrame.Position = UDim2.new(0.5, -150, 0.5, -60) mainFrame.BackgroundColor3 = Color3.new(0.1, 0.1, 0.1) mainFrame.BorderSizePixel = 2 mainFrame.BorderColor3 = Color3.new(0.3, 0.3, 0.3) mainFrame.Parent = screenGui -- Adicionar UICorner para bordas arredondadas local corner = Instance.new("UICorner") corner.CornerRadius = UDim.new(0, 8) corner.Parent = mainFrame -- Título local titleLabel = Instance.new("TextLabel") titleLabel.Name = "TitleLabel" titleLabel.Size = UDim2.new(1, 0, 0, 30) titleLabel.Position = UDim2.new(0, 0, 0, 0) titleLabel.BackgroundTransparency = 1 titleLabel.Text = "Coordenadas do Jogador" titleLabel.TextColor3 = Color3.new(1, 1, 1) titleLabel.TextScaled = true titleLabel.Font = Enum.Font.SourceSansBold titleLabel.Parent = mainFrame -- Label das coordenadas local coordsLabel = Instance.new("TextLabel") coordsLabel.Name = "CoordsLabel" coordsLabel.Size = UDim2.new(1, -20, 0, 40) coordsLabel.Position = UDim2.new(0, 10, 0, 35) coordsLabel.BackgroundColor3 = Color3.new(0.2, 0.2, 0.2) coordsLabel.BorderSizePixel = 1 coordsLabel.BorderColor3 = Color3.new(0.4, 0.4, 0.4) coordsLabel.Text = getPlayerCoordinates() coordsLabel.TextColor3 = Color3.new(0.8, 1, 0.8) coordsLabel.TextScaled = true coordsLabel.Font = Enum.Font.SourceSans coordsLabel.Parent = mainFrame -- UICorner para o label das coordenadas local coordsCorner = Instance.new("UICorner") coordsCorner.CornerRadius = UDim.new(0, 4) coordsCorner.Parent = coordsLabel -- Botão de copiar (📎) local copyButton = Instance.new("TextButton") copyButton.Name = "CopyButton" copyButton.Size = UDim2.new(0, 60, 0, 30) copyButton.Position = UDim2.new(0, 20, 0, 85) copyButton.BackgroundColor3 = Color3.new(0.2, 0.6, 0.2) copyButton.BorderSizePixel = 1 copyButton.BorderColor3 = Color3.new(0.4, 0.8, 0.4) copyButton.Text = "📎" copyButton.TextColor3 = Color3.new(1, 1, 1) copyButton.TextScaled = true copyButton.Font = Enum.Font.SourceSansBold copyButton.Parent = mainFrame -- UICorner para o botão de copiar local copyCorner = Instance.new("UICorner") copyCorner.CornerRadius = UDim.new(0, 4) copyCorner.Parent = copyButton -- Botão de fechar (❌) local closeButton = Instance.new("TextButton") closeButton.Name = "CloseButton" closeButton.Size = UDim2.new(0, 60, 0, 30) closeButton.Position = UDim2.new(0, 220, 0, 85) closeButton.BackgroundColor3 = Color3.new(0.8, 0.2, 0.2) closeButton.BorderSizePixel = 1 closeButton.BorderColor3 = Color3.new(1, 0.4, 0.4) closeButton.Text = "❌" closeButton.TextColor3 = Color3.new(1, 1, 1) closeButton.TextScaled = true closeButton.Font = Enum.Font.SourceSansBold closeButton.Parent = mainFrame -- UICorner para o botão de fechar local closeCorner = Instance.new("UICorner") closeCorner.CornerRadius = UDim.new(0, 4) closeCorner.Parent = closeButton -- Animação de entrada mainFrame.Size = UDim2.new(0, 0, 0, 0) local tweenInfo = TweenInfo.new(0.3, Enum.EasingStyle.Back, Enum.EasingDirection.Out) local tween = TweenService:Create(mainFrame, tweenInfo, {Size = UDim2.new(0, 300, 0, 120)}) tween:Play() -- Função do botão copiar copyButton.MouseButton1Click:Connect(function() local coords = getPlayerCoordinates() copyToClipboard(coords) -- Feedback visual copyButton.BackgroundColor3 = Color3.new(0.4, 0.8, 0.4) wait(0.2) copyButton.BackgroundColor3 = Color3.new(0.2, 0.6, 0.2) print("Coordenadas copiadas: " .. coords) end) -- Função do botão fechar closeButton.MouseButton1Click:Connect(function() local tweenOut = TweenService:Create(mainFrame, TweenInfo.new(0.2, Enum.EasingStyle.Back, Enum.EasingDirection.In), {Size = UDim2.new(0, 0, 0, 0)}) tweenOut:Play() tweenOut.Completed:Connect(function() screenGui:Destroy() end) end) -- Atualizar coordenadas em tempo real local connection connection = game:GetService("RunService").Heartbeat:Connect(function() if screenGui.Parent then coordsLabel.Text = getPlayerCoordinates() else connection:Disconnect() end end) end -- Detectar quando o jogador digita "local" no chat player.Chatted:Connect(function(message) if message:lower() == "local" then createCoordinatesUI() end end) print("Script de coordenadas carregado! Digite 'local' no chat para abrir a UI.")