Hello,
I want to do so if someone click on a button his username will come up on a gui so everyone in the server can see,
This is the scirpt i using now;
script.Parent.RemoteEvent.OnServerEvent:connect(function(player) game:GetService("ServerStorage"):WaitForChild("Tool"):Clone().Parent = player.Backpack player.PlayerGui.ScreenGui.Frame.TextLabel.Text = player.Name
Local Script; script.Parent.MouseButton1Click:connect(function(plr) game:GetService("ReplicatedStorage"):WaitForChild("RemoteEvent"):FireServer() end)
I believe this may be the fix. If you have any issues with it or it doesn't fix the issue, let me know. Thanks!
script.Parent.RemoteEvent.OnServerEvent:connect(function(player) game:GetService("ServerStorage"):WaitForChild("Tool"):Clone().Parent = player.Backpack for Index, Plr in pairs (game:GetService("Players"):GetChildren()) do -- cycle through player's etc Plr.PlayerGui.ScreenGui.Frame.TextLabel.Text = player.Name. end
You could use an Event to fire all clients and send the player's name through a parameter.I think...