
Key Required
Notifier
Lua Script•88 lines (3371 chars)
-- Configurações e Serviços
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Players = game:GetService("Players")
local CoreGui = game:GetService("CoreGui")
local TweenService = game:GetService("TweenService")
local LocalPlayer = Players.LocalPlayer
local MessageEvent = ReplicatedStorage:WaitForChild("MessageEvent")
-- Criar a interface GUI protetora contra resets
local ScreenGui = Instance.new("ScreenGui")
ScreenGui.Name = "ObbyNotifierGUI_Fixed"
ScreenGui.ResetOnSpawn = false
ScreenGui.Parent = CoreGui
-- Container principal para empilhar as notificações
local MainContainer = Instance.new("Frame")
MainContainer.Name = "NotificationContainer"
MainContainer.Size = UDim2.new(0, 300, 0, 500)
MainContainer.Position = UDim2.new(1, -320, 0.4, -250) -- Ajustado um pouco mais para cima
MainContainer.BackgroundTransparency = 1
MainContainer.Parent = ScreenGui
-- Layout para empilhar automaticamente de baixo para cima
local UIListLayout = Instance.new("UIListLayout")
UIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
UIListLayout.Padding = UDim.new(0, 8)
UIListLayout.VerticalAlignment = Enum.VerticalAlignment.Bottom
UIListLayout.Parent = MainContainer
-- Função para criar o card de notificação visual
local function createNotification(message, color)
local Frame = Instance.new("Frame")
Frame.Size = UDim2.new(1, 0, 0, 60)
Frame.BackgroundColor3 = Color3.fromRGB(20, 20, 20)
Frame.BackgroundTransparency = 0.15
Frame.BorderSizePixel = 0
local UICorner = Instance.new("UICorner")
UICorner.CornerRadius = UDim.new(0, 8)
UICorner.Parent = Frame
local UIStroke = Instance.new("UIStroke")
UIStroke.Color = color or Color3.new(0, 1, 0)
UIStroke.Thickness = 2
UIStroke.Parent = Frame
local TextLabel = Instance.new("TextLabel")
TextLabel.Size = UDim2.new(1, -20, 1, -20)
TextLabel.Position = UDim2.new(0, 10, 0, 10)
TextLabel.BackgroundTransparency = 1
TextLabel.Text = message
TextLabel.TextColor3 = Color3.new(1, 1, 1)
TextLabel.Font = Enum.Font.GothamSemibold
TextLabel.TextSize = 13
TextLabel.TextWrapped = true
TextLabel.TextXAlignment = Enum.TextXAlignment.Left
TextLabel.Parent = Frame
-- Efeito de surgimento animado
Frame.Size = UDim2.new(1, 0, 0, 0)
TextLabel.TextTransparency = 1
Frame.Parent = MainContainer
TweenService:Create(Frame, TweenInfo.new(0.25), {Size = UDim2.new(1, 0, 0, 60)}):Play()
TweenService:Create(TextLabel, TweenInfo.new(0.25), {TextTransparency = 0}):Play()
-- Auto destruir após 6 segundos
task.delay(6, function()
TweenService:Create(Frame, TweenInfo.new(0.25), {Size = UDim2.new(1, 0, 0, 0)}):Play()
TweenService:Create(TextLabel, TweenInfo.new(0.25), {TextTransparency = 1}):Play()
task.wait(0.25)
Frame:Destroy()
end)
end
-- Ouvir absolutamente TODAS as notificações de vitória enviadas pelo evento
local Connection
Connection = MessageEvent.OnClientEvent:Connect(function(text, font, color)
-- Removemos a verificação rígida de texto ("completed").
-- Agora aceita qualquer mensagem enviada no formato padrão de anúncio do jogo.
if text and text ~= "" then
createNotification(text, color)
end
end)
-- Notificação inicial
createNotification("[Sistema] Monitor de Fases Ativado!", Color3.fromRGB(255, 170, 0))Features & Information
notifies who beated a level
Community Comments (0)
No comments yet for this script.
