Universal Script 📌
19.2k Views
36 Executions

Notification System

Universal Script 📌
vqmpjay
vqmpjayPublished 10
2 years ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

a very simple notification system that can also have a button

View Raw
--[[ 
Vadrifts notification system v2 (dsc.gg/vadriftz)

Example usage:
Notification w/out a button:
local NotificationSystem = loadstring(game:HttpGet("https://raw.githubusercontent.com/vqmpjayZ/utils/refs/heads/main/Notification-SystemV2.lua"))()  <-- boot up the notification system

NotificationSystem:Notify("Title", "This is a notification.", 5) <-- "Title" is the title of the notification; "This is a notification message." <-- is the notifications text; 5 <-- length of the notification
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Notification w/ a button:
local NotificationSystem = loadstring(game:HttpGet("https://raw.githubusercontent.com/vqmpjayZ/utils/refs/heads/main/Notification-SystemV2.lua"))()

NotificationSystem:Notify("Title", "This is a notification with a button.", 10, "Click me", function() <-- "Click me" is the button and its text
    print("Button was clicked!") <-- the script that gets executed when the button is clicked
end)
--]]

local NotificationSystem = {}

local TweenService = game:GetService("TweenService")
local CoreGui = game:GetService("CoreGui")

local ScreenGui = Instance.new("ScreenGui")
ScreenGui.Name = "NotificationSystem"
ScreenGui.Parent = CoreGui

local NotificationFrame = Instance.new("Frame")
NotificationFrame.Name = "NotificationFrame"
NotificationFrame.Size = UDim2.new(0, 300, 1, 0)
NotificationFrame.Position = UDim2.new(1, -300, 0, 0)
NotificationFrame.BackgroundTransparency = 1
NotificationFrame.Parent = ScreenGui

local UIListLayout = Instance.new("UIListLayout")
UIListLayout.Parent = NotificationFrame
UIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
UIListLayout.Padding = UDim.new(0, 5)
UIListLayout.VerticalAlignment = Enum.VerticalAlignment.Bottom

local function CreateNotification(title, text, duration, buttonText, buttonCallback)


Comments

1
Log in to join the conversation. Login
dketkonan's profile picture
dketkonan2 years ago(edited)

cool.

1

Tags

More universal scripts

See all
Script hub
1.6M
2.0M
Bumped 2 hours ago
Key System

Script hub

#12 this week

Verified script badgeSnowy Hub 500+ Games & 25600+ Features

Script hub
269.0k
114.4k
Bumped 2 hours ago
Key System
Script hub
171.2k
1.4M
Bumped 5 hours ago
Key System
Script hub
16.6k
3.2k
Bumped 7 hours ago
Key System
Paid
Script hub
17.2k
87.3k
Bumped 7 hours ago