Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Sorry, the font size is only suitable for my screen.
- local p = game.Players.LocalPlayer
- local g = p:WaitForChild("PlayerGui"):FindFirstChild("NoteUI")
- if not g then
- g = Instance.new("ScreenGui")
- g.Name = "NoteUI"
- g.DisplayOrder = 100
- g.Parent = p:WaitForChild("PlayerGui")
- g.ResetOnSpawn = false
- end
- local f = g:FindFirstChild("NoteFrame")
- if not f then
- f = Instance.new("Frame")
- f.Name = "Note"
- f.Parent = g
- f.Visible = false
- f.BackgroundTransparency = 0
- f.BorderSizePixel = 0
- f.BackgroundColor3 = Color3.new(0, 0, 0)
- f.Size = UDim2.new(0.6, 0, 0.6, 0)
- f.Position = UDim2.new(0.05, 0, 0.05, 0)
- local pd = Instance.new("UIAspectRatioConstraint", f)
- pd.AspectRatio = 0.750916949152
- local s = Instance.new("UIScale", f)
- s.Scale = 1
- end
- local t = f:FindFirstChild("TextLabel")
- if not t then
- t = Instance.new("TextLabel")
- t.Name = "the"
- t.Parent = f
- t.Visible = true
- t.BackgroundTransparency = 1
- t.BorderSizePixel = 0
- t.TextColor3 = Color3.new(1, 1, 1)
- t.Font = Enum.Font.Code
- t.TextSize = 18
- t.TextWrapped = true
- t.TextXAlignment = Enum.TextXAlignment.Left
- t.TextYAlignment = Enum.TextYAlignment.Top
- t.Size = UDim2.new(1, 0, 1, 0)
- t.Position = UDim2.new(0, 0, 0, 0)
- end
- local u = f:FindFirstChild("UIDTextLabel")
- if not u then
- u = Instance.new("TextLabel")
- u.Name = "UID"
- u.Parent = f
- u.Visible = true
- u.BackgroundTransparency = 1
- u.BorderSizePixel = 0
- u.TextColor3 = Color3.new(1, 1, 1)
- u.Font = Enum.Font.Code
- u.TextSize = 7
- u.TextWrapped = false
- u.TextXAlignment = Enum.TextXAlignment.Left
- u.TextYAlignment = Enum.TextYAlignment.Bottom
- u.Size = UDim2.new(0.5, 0, 0.07, 0)
- u.Position = UDim2.new(0, 0, 0.92, 0)
- end
- local sig = f:FindFirstChild("SignatureTextLabel")
- if not sig then
- sig = Instance.new("TextLabel")
- sig.Name = "Signature"
- sig.Parent = f
- sig.Visible = true
- sig.BackgroundTransparency = 1
- sig.BorderSizePixel = 0
- sig.TextColor3 = Color3.new(1, 1, 1)
- sig.Font = Enum.Font.Code
- sig.TextSize = 13
- sig.TextWrapped = false
- sig.TextScaled = true
- sig.TextXAlignment = Enum.TextXAlignment.Left
- sig.TextYAlignment = Enum.TextYAlignment.Bottom
- sig.Size = UDim2.new(1, 0, 0.07, 0)
- sig.Position = UDim2.new(0, 0, 0.87, 0)
- end
- local c = f:FindFirstChild("CopyIDTextLabel")
- if not c then
- c = Instance.new("TextLabel")
- c.Name = "CopyID"
- c.Parent = f
- c.Visible = true
- c.BackgroundTransparency = 1
- c.BorderSizePixel = 0
- c.TextColor3 = Color3.new(1, 1, 1)
- c.Font = Enum.Font.Code
- c.TextSize = 11
- c.TextWrapped = false
- c.TextXAlignment = Enum.TextXAlignment.Right
- c.TextYAlignment = Enum.TextYAlignment.Bottom
- c.Size = UDim2.new(0.5, 0, 0.07, 0)
- c.Position = UDim2.new(0.5, 0, 0.92, 0)
- end
- local mc = nil
- local nc = nil
- local function gb(col)
- local r = col.R
- local g = col.G
- local b = col.B
- local br = (r * 0.299 + g * 0.587 + b * 0.114) * 100
- return br
- end
- local function ac()
- local br = gb(f.BackgroundColor3)
- if br < 25 then
- local w = Color3.new(1, 1, 1)
- u.TextColor3 = w
- sig.TextColor3 = w
- c.TextColor3 = w
- elseif br > 95 then
- local bl = Color3.new(0, 0, 0)
- u.TextColor3 = bl
- sig.TextColor3 = bl
- c.TextColor3 = bl
- else
- local d = Color3.new(0, 0, 0)
- u.TextColor3 = d
- sig.TextColor3 = d
- c.TextColor3 = d
- end
- end
- local function sp(n, pn, e, sf)
- local p = n:FindFirstChild(pn)
- if p and p:IsA(e) then
- sf(p)
- else
- local cn
- cn = n.ChildAdded:Connect(function(ch)
- if ch.Name == pn and ch:IsA(e) then
- cn:Disconnect()
- sf(ch)
- end
- end)
- end
- end
- local function oe(n)
- f.Visible = true
- nc = {}
- sp(n, "Message", "StringValue", function(m)
- t.Text = m.Value
- if mc then
- mc:Disconnect()
- end
- mc = m.Changed:Connect(function()
- t.Text = m.Value
- end)
- end)
- sp(n, "PaperColor", "StringValue", function(pc)
- local s, col = pcall(function()
- return Color3.fromHex(pc.Value)
- end)
- if s then
- f.BackgroundColor3 = col
- ac()
- else
- warn("Invalid PaperColor value:", pc.Value)
- end
- table.insert(nc, pc.Changed:Connect(function()
- local s, col = pcall(function()
- return Color3.fromHex(pc.Value)
- end)
- if s then
- f.BackgroundColor3 = col
- ac()
- else
- warn("Invalid PaperColor value:", pc.Value)
- end
- end))
- end)
- sp(n, "TextColor", "StringValue", function(tc)
- local s, col = pcall(function()
- return Color3.fromHex(tc.Value)
- end)
- if s then
- t.TextColor3 = col
- else
- warn("Invalid TextColor value:", tc.Value)
- end
- table.insert(nc, tc.Changed:Connect(function()
- local s, col = pcall(function()
- return Color3.fromHex(tc.Value)
- end)
- if s then
- t.TextColor3 = col
- else
- warn("Invalid TextColor value:", tc.Value)
- end
- end))
- end)
- sp(n, "TextFontId", "StringValue", function(tf)
- local ff = Font.new(tf.Value)
- t.FontFace = ff
- table.insert(nc, tf.Changed:Connect(function()
- local ff = Font.new(tf.Value)
- t.FontFace = ff
- u.FontFace = ff
- end))
- end)
- sp(n, "TextFontSize", "IntValue", function(ts)
- local size = (ts.Value / 50.3) * 18
- t.TextSize = size
- table.insert(nc, ts.Changed:Connect(function()
- local size = (ts.Value / 50.3) * 18
- t.TextSize = size
- end))
- end)
- sp(n, "UID", "StringValue", function(uid)
- u.Text = uid.Value
- table.insert(nc, uid.Changed:Connect(function()
- u.Text = uid.Value
- end))
- end)
- sp(n, "Signature", "StringValue", function(sg)
- sig.Text = sg.Value
- table.insert(nc, sg.Changed:Connect(function()
- sig.Text = sg.Value
- end))
- end)
- sp(n, "CopyID", "IntValue", function(cid)
- local v = cid.Value
- if v == 1 then
- c.Text = "Original. 1"
- else
- c.Text = "Copy. " .. tostring(v)
- end
- table.insert(nc, cid.Changed:Connect(function()
- local v = cid.Value
- if v == 1 then
- c.Text = "Original. 1"
- else
- c.Text = "Copy. " .. tostring(v)
- end
- end))
- end)
- end
- local function ou()
- if mc then
- mc:Disconnect()
- mc = nil
- end
- if nc then
- for _, conn in ipairs(nc) do
- conn:Disconnect()
- end
- nc = nil
- end
- f.Visible = false
- end
- local function ca(ch)
- ch.ChildAdded:Connect(function(c)
- if c:IsA("Tool") and c.Name == "Note" then
- oe(c)
- end
- end)
- ch.ChildRemoved:Connect(function(c)
- if c:IsA("Tool") and c.Name == "Note" then
- ou()
- end
- end)
- for _, c in ipairs(ch:GetChildren()) do
- if c:IsA("Tool") and c.Name == "Note" then
- oe(c)
- break
- end
- end
- end
- p.CharacterAdded:Connect(ca)
- if p.Character then
- ca(p.Character)
- end
Advertisement
Advertisement