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

How do I make ‘[Owner] [MAD] Whatever I say’ when I say something in chat?

2 answers

Scripting helpers is not a request site! (I'll provide the code though) Here's the code :

local players = game:GetService("Players")
local chatservice = require(game.ServerScriptService:WaitForChild("ChatServiceRunner"):WaitForChild("ChatService"))
game.Players.PlayerAdded:Connect(function(plr)
 	if plr.UserId ==1367449480 then
chatservice.SpeakerAdded:Connect(function(playerName)
		local speaker = chatservice:GetSpeaker(playerName)
		speaker:SetExtraData("Tags",{{TagText = "MAD", TagColor = Color3.fromRGB(255,0,0)}})
		end)
	end
end)

6 comments

0

You can only set one. Trying to set another one will replace the previous one.

0

To mimic it having 2 tags you can just make it from "MAD" to "MAD [Owner"

0

Regular script either in workspace or ServerScriptService.

0

There’s a error: Workspace.Script:9: Expected ‘)’ (to close ‘(‘ at line 5),got ‘end’. And: ServerScriptService.Script:9: Expected ‘)’ (to close ‘(‘ at line 5),got ‘end’

0

try replace end in line 8 with end)

0

I did that but it still didn’t work :(. But no worry’s, I got one with a table and inside of the table it have the Id and the color and the text and stuff.

i got this:

local players = game:GetService("Players")
local chatService = require(game.ServerScriptService:WaitForChild("ChatServiceRunner"):WaitForChild("ChatService"))

local tags = {
	[1367449480] = {TagText = "Owner", TagColor = Color3.fromRGB(255,0,0)},
}

chatService.SpeakerAdded:Connect(function(playerName)
	local speaker = chatService:GetSpeaker(playerName)
	local player = game.Players[playerName]
	
	if tags[player.UserId] then
		speaker:SetExtraData("Tags",{tags[player.UserId]})
	end
end)

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