Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

System chat message on touch?

This is really confusing me, how can I make a chat message when someone hits a certain part? For example, I need a message (" has made it to the end!") to be sent in the chat once someone gets to the end and touches the finish line.

Help would be greatly appreciated, as I've looked on the dev forum and on youtube with no luck.

1 answer

Of course you have to use StarterGui:SetCore() to do that. That script should be put in a local script:

script.Parent.Touched:Connect(function(hit)
	game.StarterGui:SetCore("ChatMakeSystemMessage",{
		Text = hit.Name, -- Text to send
		Font = Enum.Font.SourceSansBold, -- Font
		Color = Color3.new(255, 255, 255) -- Color
		FontSize = Enum.FontSize.Size96 -- Font size
	})
end)

1 comment

0

This would absolutely not work for other players. You need to use RemoteEvents and use a ServerScript to detected when the part is touched. Then, you have to use :FireAllClients() so that all players can get this event. Finally, use a LocalScript to recieve that event and use the :SetCore() function for the chat message. TLDR: use RemoteEvents

This discussion is preserved as it was. New answers, comments, and votes are closed.