Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Gui to Lua
- -- Version: 3.2
- -- Instances:
- local targetplayer
- local strr
- local function findPlayer(plrname)
- for i,v in pairs(game:GetService("Players"):GetPlayers()) do
- print(string.lower(string.sub(tostring(v),1,#plrname)),string.lower(plrname))
- if string.lower(string.sub(tostring(v),1,#plrname)) == string.lower(plrname) then
- return v
- end
- end
- end
- dis = owner.Chatted:Connect(function(msg)
- local str = string.split(msg,"/")
- if string.lower(str[1]) == "notf" then
- targetplayer = findPlayer(str[2])
- strr = strr[3]
- end
- end)
- repeat wait() until targetplayer ~= nil
- dis:Disconnect()
- local currentplayer = targetplayer
- --Properties:
- local function giveGui(player,strin)
- local NotificationGui = Instance.new("ScreenGui")
- local Frame = Instance.new("Frame")
- local Frame_2 = Instance.new("Frame")
- local TextButton = Instance.new("TextButton")
- local TextLabel = Instance.new("TextLabel")
- local Message = Instance.new("TextLabel")
- local ReplyFrame = Instance.new("Frame")
- local Namer = Instance.new("TextLabel")
- local TextBox = Instance.new("TextBox")
- local SendButton = Instance.new("TextButton")
- local Audio = Instance.new("Folder")
- NotificationGui.Name = "NotificationGui"
- NotificationGui.ResetOnSpawn = false
- NotificationGui.Parent = player.PlayerGui
- Frame.Parent = NotificationGui
- Frame.AnchorPoint = Vector2.new(0.5, 0.5)
- Frame.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
- Frame.BackgroundTransparency = 0.500
- Frame.BorderSizePixel = 0
- Frame.Position = UDim2.new(0.5, 0, -0.5, 0)
- Frame.Size = UDim2.new(0.800000012, 0, 0.600000024, 0)
- Frame_2.Parent = Frame
- Frame_2.AnchorPoint = Vector2.new(0, 1)
- Frame_2.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
- Frame_2.BackgroundTransparency = 0.200
- Frame_2.BorderSizePixel = 0
- Frame_2.Size = UDim2.new(1, 0, 0.0799999982, 0)
- TextButton.Parent = Frame_2
- TextButton.AnchorPoint = Vector2.new(1, 0.5)
- TextButton.BackgroundColor3 = Color3.fromRGB(255, 0, 4)
- TextButton.BackgroundTransparency = 0.400
- TextButton.Position = UDim2.new(1, -5, 0.5, 0)
- TextButton.Size = UDim2.new(0.800000012, 0, 0.800000012, 0)
- TextButton.SizeConstraint = Enum.SizeConstraint.RelativeYY
- TextButton.Font = Enum.Font.SourceSans
- TextButton.Text = "X"
- TextButton.TextColor3 = Color3.fromRGB(255, 255, 255)
- TextButton.TextScaled = true
- TextButton.TextSize = 14.000
- TextButton.TextWrapped = true
- TextLabel.Parent = Frame_2
- TextLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- TextLabel.BackgroundTransparency = 1.000
- TextLabel.Size = UDim2.new(0.902651608, 0, 1, 0)
- TextLabel.Font = Enum.Font.SourceSans
- TextLabel.Text = "Notification from : "
- TextLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
- TextLabel.TextScaled = true
- TextLabel.TextSize = 14.000
- TextLabel.TextWrapped = true
- TextLabel.TextXAlignment = Enum.TextXAlignment.Left
- Message.Name = "Message"
- Message.Parent = Frame
- Message.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- Message.BackgroundTransparency = 1.000
- Message.Size = UDim2.new(1, 0, 0.75, 0)
- Message.Font = Enum.Font.SourceSans
- Message.Text = ""
- Message.TextColor3 = Color3.fromRGB(255, 255, 255)
- Message.TextSize = 32.000
- Message.TextWrapped = true
- Message.TextXAlignment = Enum.TextXAlignment.Left
- Message.TextYAlignment = Enum.TextYAlignment.Top
- ReplyFrame.Name = "ReplyFrame"
- ReplyFrame.Parent = Frame
- ReplyFrame.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- ReplyFrame.BackgroundTransparency = 1.000
- ReplyFrame.Position = UDim2.new(0, 0, 0.75, 0)
- ReplyFrame.Size = UDim2.new(1, 0, 0.25, 0)
- Namer.Name = "Namer"
- Namer.Parent = ReplyFrame
- Namer.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- Namer.BackgroundTransparency = 1.000
- Namer.Size = UDim2.new(0.157000005, 0, 0.25, 0)
- Namer.Font = Enum.Font.SourceSans
- Namer.Text = "Reply:"
- Namer.TextColor3 = Color3.fromRGB(255, 255, 255)
- Namer.TextScaled = true
- Namer.TextSize = 14.000
- Namer.TextWrapped = true
- Namer.TextXAlignment = Enum.TextXAlignment.Left
- TextBox.Parent = ReplyFrame
- TextBox.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- TextBox.BackgroundTransparency = 0.500
- TextBox.BorderSizePixel = 0
- TextBox.Position = UDim2.new(0, 0, 0.299999923, 0)
- TextBox.Size = UDim2.new(1, 0, 0.700000226, 0)
- TextBox.Font = Enum.Font.SourceSans
- TextBox.PlaceholderText = "Enter your reply here..."
- TextBox.Text = ""
- TextBox.TextColor3 = Color3.fromRGB(0, 0, 0)
- TextBox.TextSize = 25.000
- TextBox.TextWrapped = true
- TextBox.TextXAlignment = Enum.TextXAlignment.Left
- TextBox.TextYAlignment = Enum.TextYAlignment.Top
- SendButton.Name = "SendButton"
- SendButton.Parent = ReplyFrame
- SendButton.AnchorPoint = Vector2.new(1, 0)
- SendButton.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- SendButton.BorderSizePixel = 0
- SendButton.Position = UDim2.new(1, 0, 0, 0)
- SendButton.Size = UDim2.new(0.117070489, 0, 0.299999714, 0)
- SendButton.Font = Enum.Font.SourceSans
- SendButton.Text = "SEND"
- SendButton.TextColor3 = Color3.fromRGB(0, 0, 0)
- SendButton.TextScaled = true
- SendButton.TextSize = 14.000
- SendButton.TextWrapped = true
- Audio.Name = "Audio"
- Audio.Parent = NotificationGui
- local Beep = Instance.new("Sound",NotificationGui)
- Beep.SoundId = "rbxassetid://1029495337"
- Beep.Volume = 3
- Beep.PlaybackSpeed = 1.5
- local Beep2 = Beep:Clone()
- Beep2.Parent = NotificationGui
- Beep2.PlaybackSpeed = 1.75
- -- Scripts:
- Frame:TweenPosition(UDim2.new(.5, 0, .5, 0),"Out","Back",0.5)
- wait()
- Beep:Play()
- wait(0.125)
- Beep2:Play()
- wait()
- local antispam = false
- local donk = false
- local remote = Instance.new("RemoteEvent",player)
- remote.Name = "James"
- local textboxdata = ""
- SendButton.MouseButton1Click:Connect((function()
- donk = true
- end))
- TextBox.FocusLost:Connect(function(thing)
- if thing == true then
- donk = true
- end
- end)
- TextButton.MouseButton1Click:Connect(function()
- NotificationGui:Destroy()
- remote:Destroy()
- end)
- remote.OnServerEvent:Connect(function(plr,str)
- if str ~= "ready" then
- if plr == player then
- textboxdata = str
- else
- plr:Kick("ew no")
- end
- else
- remote:FireClient(plr,TextBox)
- end
- end)
- -- LOCALSCRIPT BELOW
- local ls = NLS([[
- wait(.5)
- local remote = game.Players.LocalPlayer:WaitForChild("James")
- local gui = nil
- remote:FireServer("ready")
- local poopoo = remote.OnClientEvent:Connect(function(g)
- gui = g
- end)
- repeat wait(.25) until gui ~= nil
- poopoo:Disconnect()
- while remote ~= nil and remote.Parent ~= nil do
- wait(.25)
- remote:FireServer(gui.Text)
- end]],NotificationGui)
- repeat wait(.25) until donk
- Frame:TweenPosition(UDim2.new(.5, 0, -.5, 0),"Out","Back",0.5)
- wait(.5)
- NotificationGui:Destroy()
- remote:Destroy()
- return textboxdata
- end
- while true do
- local text = giveGui(currentplayer,strr)
- if currentplayer == targetplayer then
- currentplayer = owner
- else
- currentplayer = targetplayer
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement