-- Xeno ReChat - Key Protected + Server-Wide (Everyone using script sees messages) -- Key: XENOSTAYSFOREVER -- Toggle: F10 -- Credits: Prayansh & Aizen local Players = game:GetService("Players") local TweenService = game:GetService("TweenService") local UserInputService = game:GetService("UserInputService") local RunService = game:GetService("RunService") local Debris = game:GetService("Debris") local HttpService = game:GetService("HttpService") local player = Players.LocalPlayer local playerGui = player:WaitForChild("PlayerGui") local CHAT_KEY = "XENOSTAYSFOREVER" local TOGGLE_KEY = Enum.KeyCode.F10 local chatGui, mainFrame, messagesFrame, inputBox local toggled = false local lastSendTime = 0 local messagesSeen = {} -- Workspace folder for shared messages (all script users see) local chatFolder = workspace:FindFirstChild("XenoReChatFolder") if not chatFolder then chatFolder = Instance.new("Folder") chatFolder.Name = "XenoReChatFolder" chatFolder.Parent = workspace end -- Create UI after key local function createChatUI() if chatGui then chatGui:Destroy() end chatGui = Instance.new("ScreenGui") chatGui.Name = "XenoReChat" chatGui.ResetOnSpawn = false chatGui.Parent = playerGui mainFrame = Instance.new("Frame") mainFrame.Size = UDim2.new(0, 380, 0, 280) mainFrame.Position = UDim2.new(0.5, -190, 0.5, -140) mainFrame.BackgroundColor3 = Color3.fromRGB(20, 20, 25) mainFrame.BorderSizePixel = 0 mainFrame.Visible = true mainFrame.Parent = chatGui local corner = Instance.new("UICorner") corner.CornerRadius = UDim.new(0, 10) corner.Parent = mainFrame -- Title local titleBar = Instance.new("Frame") titleBar.Size = UDim2.new(1, 0, 0, 35) titleBar.BackgroundColor3 = Color3.fromRGB(30, 30, 40) titleBar.BorderSizePixel = 0 titleBar.Parent = mainFrame local titleLabel = Instance.new("TextLabel") titleLabel.Size = UDim2.new(1, -40, 1, 0) titleLabel.Position = UDim2.new(0, 12, 0, 0) titleLabel.BackgroundTransparency = 1 titleLabel.Text = "Xeno ReChat | By Prayansh & Aizen" titleLabel.TextColor3 = Color3.fromRGB(100, 180, 255) titleLabel.Font = Enum.Font.GothamBold titleLabel.TextSize = 16 titleLabel.TextXAlignment = Enum.TextXAlignment.Left titleLabel.Parent = titleBar -- Close btn local closeBtn = Instance.new("TextButton") closeBtn.Size = UDim2.new(0, 28, 0, 28) closeBtn.Position = UDim2.new(1, -34, 0, 4) closeBtn.BackgroundColor3 = Color3.fromRGB(220, 60, 60) closeBtn.Text = "×" closeBtn.TextColor3 = Color3.new(1,1,1) closeBtn.Font = Enum.Font.GothamBold closeBtn.TextSize = 18 closeBtn.Parent = titleBar local closeCorner = Instance.new("UICorner") closeCorner.CornerRadius = UDim.new(0, 6) closeCorner.Parent = closeBtn closeBtn.MouseButton1Click:Connect(function() chatGui.Enabled = false end) -- Messages messagesFrame = Instance.new("ScrollingFrame") messagesFrame.Size = UDim2.new(1, -16, 1, -80) messagesFrame.Position = UDim2.new(0, 8, 0, 40) messagesFrame.BackgroundTransparency = 1 messagesFrame.ScrollBarThickness = 6 messagesFrame.CanvasSize = UDim2.new(0,0,0,0) messagesFrame.AutomaticCanvasSize = Enum.AutomaticSize.Y messagesFrame.Parent = mainFrame local layout = Instance.new("UIListLayout") layout.Padding = UDim.new(0, 6) layout.Parent = messagesFrame -- Input local inputFrame = Instance.new("Frame") inputFrame.Size = UDim2.new(1, -16, 0, 36) inputFrame.Position = UDim2.new(0, 8, 1, -44) inputFrame.BackgroundColor3 = Color3.fromRGB(30, 30, 40) inputFrame.BorderSizePixel = 0 inputFrame.Parent = mainFrame local inputCorner = Instance.new("UICorner") inputCorner.CornerRadius = UDim.new(0, 8) inputCorner.Parent = inputFrame inputBox = Instance.new("TextBox") inputBox.Size = UDim2.new(1, -80, 1, -8) inputBox.Position = UDim2.new(0, 8, 0, 4) inputBox.BackgroundTransparency = 1 inputBox.TextColor3 = Color3.new(1,1,1) inputBox.PlaceholderText = "Type message... (Enter to send)" inputBox.PlaceholderColor3 = Color3.fromRGB(140,140,160) inputBox.TextSize = 15 inputBox.Font = Enum.Font.Gotham inputBox.ClearTextOnFocus = false inputBox.TextXAlignment = Enum.TextXAlignment.Left inputBox.Parent = inputFrame local sendBtn = Instance.new("TextButton") sendBtn.Size = UDim2.new(0, 60, 0, 28) sendBtn.Position = UDim2.new(1, -68, 0, 4) sendBtn.BackgroundColor3 = Color3.fromRGB(60, 180, 80) sendBtn.Text = "Send" sendBtn.TextColor3 = Color3.new(1,1,1) sendBtn.Font = Enum.Font.GothamBold sendBtn.TextSize = 14 sendBtn.Parent = inputFrame local sendCorner = Instance.new("UICorner") sendCorner.CornerRadius = UDim.new(0, 6) sendCorner.Parent = sendBtn -- Send function local function sendMessage() local text = inputBox.Text if text == "" or #text > 200 then return end local now = tick() if now - lastSendTime < 2 then return end -- cooldown lastSendTime = now local fullMsg = player.Name .. ": " .. text local guid = HttpService:GenerateGUID(false) local val = Instance.new("StringValue") val.Name = guid val.Value = fullMsg val.Parent = chatFolder Debris:AddItem(val, 180) -- expire after 3 min inputBox.Text = "" inputBox:ReleaseFocus() end sendBtn.MouseButton1Click:Connect(sendMessage) inputBox.FocusLost:Connect(function(enter) if enter then sendMessage() end end) -- Draggable local dragging, dragStart, startPos titleBar.InputBegan:Connect(function(inp) if inp.UserInputType == Enum.UserInputType.MouseButton1 then dragging = true dragStart = inp.Position startPos = mainFrame.Position end end) titleBar.InputChanged:Connect(function(inp) if dragging and inp.UserInputType == Enum.UserInputType.MouseMovement then local delta = inp.Position - dragStart mainFrame.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y) end end) UserInputService.InputEnded:Connect(function(inp) if inp.UserInputType == Enum.UserInputType.MouseButton1 then dragging = false end end) -- Pulse icon local icon = Instance.new("Frame") icon.Size = UDim2.new(0, 18, 0, 18) icon.Position = UDim2.new(1, -26, 0, 9) icon.BackgroundColor3 = Color3.fromRGB(80, 180, 255) icon.BorderSizePixel = 0 icon.Parent = titleBar local ic = Instance.new("UICorner") ic.CornerRadius = UDim.new(1,0) ic.Parent = icon TweenService:Create(icon, TweenInfo.new(1.4, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut, -1, true), { Size = UDim2.new(0, 24, 0, 24), Position = UDim2.new(1, -32, 0, 6) }):Play() -- Message listener RunService.Heartbeat:Connect(function() for _, child in ipairs(chatFolder:GetChildren()) do if child:IsA("StringValue") and not messagesSeen[child.Name] then messagesSeen[child.Name] = true local lbl = Instance.new("TextLabel") lbl.BackgroundTransparency = 1 lbl.Size = UDim2.new(1,0,0,0) lbl.AutomaticSize = Enum.AutomaticSize.Y lbl.Text = child.Value lbl.TextColor3 = Color3.fromRGB(220,220,240) lbl.TextSize = 15 lbl.Font = Enum.Font.Gotham lbl.TextXAlignment = Enum.TextXAlignment.Left lbl.TextWrapped = true lbl.Parent = messagesFrame task.delay(0.05, function() messagesFrame.CanvasPosition = Vector2.new(0, messagesFrame.AbsoluteCanvasSize.Y) end) end end end) -- Cleanup seen chatFolder.ChildRemoved:Connect(function(c) if c:IsA("StringValue") then messagesSeen[c.Name] = nil end end) -- Limit total messages spawn(function() while chatGui.Parent do wait(30) local kids = chatFolder:GetChildren() while #kids > 80 do kids[1]:Destroy() kids = chatFolder:GetChildren() end end end) end -- Key window local function showKeyWindow() local kg = Instance.new("ScreenGui") kg.Name = "XenoKey" kg.Parent = playerGui local f = Instance.new("Frame") f.Size = UDim2.new(0,320,0,160) f.Position = UDim2.new(0.5,-160,0.5,-80) f.BackgroundColor3 = Color3.fromRGB(25,25,35) f.BorderSizePixel = 0 f.Parent = kg local c = Instance.new("UICorner") c.CornerRadius = UDim.new(0,12) c.Parent = f local l = Instance.new("TextLabel") l.Size = UDim2.new(1,0,0,40) l.BackgroundTransparency = 1 l.Text = "Xeno ReChat Key" l.TextColor3 = Color3.fromRGB(120,200,255) l.Font = Enum.Font.GothamBold l.TextSize = 20 l.Parent = f local b = Instance.new("TextBox") b.Size = UDim2.new(0.9,0,0,36) b.Position = UDim2.new(0.05,0,0.4,0) b.BackgroundColor3 = Color3.fromRGB(35,35,45) b.TextColor3 = Color3.new(1,1,1) b.PlaceholderText = "Enter key..." b.Font = Enum.Font.Gotham b.TextSize = 16 b.Parent = f local bc = Instance.new("UICorner") bc.CornerRadius = UDim.new(0,8) bc.Parent = b b.FocusLost:Connect(function(en) if not en then return end if b.Text == CHAT_KEY then kg:Destroy() createChatUI() print("Xeno ReChat unlocked! Press F10 to toggle.") else b.Text = "Wrong key!" task.delay(1.5, function() if b.Parent then b.Text = "" end end) end end) b:CaptureFocus() end -- F10 toggle UserInputService.InputBegan:Connect(function(inp, gp) if gp then return end if inp.KeyCode == TOGGLE_KEY then if chatGui then chatGui.Enabled = not chatGui.Enabled end end end) -- Start showKeyWindow() print("Xeno ReChat ready | Key: XENOSTAYSFOREVER | Toggle: F10 | Messages visible to all users running the script in this server!")