game.Players.PlayerAdded:Connect(function(Player)
game:GetService("StarterGui"):SetCore("ChatMakeSystemMessage",{
Text = "[SERVER] "..Player.Name.." has joined the game!";
Color = Color3.new(0,1,0);
Font = Enum.Font.SourceSans;
FontSize = Enum.FontSize.Size24;
})
end)
COMMUNITY QUESTION
Why doesn't this create the message?
1 answer
Put it in a LocalScript, running on the client, use RemoteEvents if necessary, e.g.
-- Client script
game.Workspace:WaitForChild("MakeAChat").OnClientEvent:Connect(function(msg)
game:GetService("StarterGui"):SetCore("ChatMakeSystemMessage",{
Text = "[SERVER]: " .. msg;
Color = Color3.new(0,1,0);
Font = Enum.Font.SourceSans;
FontSize = Enum.FontSize.Size24;
})
end)
-- Server script
local remote = Instance.new("RemoteEvent")
remote.Parent = workspace
remote.Name = "MakeAChat"
game.Players.PlayerAdded:Connect(function(plr)
remote:FireClient(plr, "Why, hello there!") -- Only sends message to player
remote:FireAllClients(plr .. " has joined the game!") -- Sends message to everyone
end)
The upside to this, is you can send a message to only one client at a time, or to everyone by using FireAllClients()
1 comment
0
Nicely done.
This discussion is preserved as it was. New answers, comments, and votes are closed.

2 comments
This feature will only work in a LocalScript (or a ModuleScript running on the client)
http://wiki.roblox.com/index.php?title=SetCore#ChatMakeSystemMessage