You can write your topic however you want, but you need to answer these questions:
-
What do you want to achieve? Keep it simple and clear!
I would like to be able to change the name color. -
What is the issue? Include screenshots / videos if possible!
The name color doesn’t change and the name gets replace byColor:ToHex()
value.
The tag color is right tho.
In the else the name is right and it changes color.
local TextChatService = game:GetService("TextChatService")
local Players = game:GetService("Players")
local player = script.Parent.Parent
player.CharacterAdded:Wait()
local Tag = game.Workspace.Date.Giocatori:FindFirstChild("="..player.Name)
local Color
local function OnIncomingMessage(message: TextChatMessage): TextChatMessageProperties
local properties = Instance.new("TextChatMessageProperties")
Color = Tag:GetAttribute("Colore")
if Tag:GetAttribute("Intro") == false then
properties.PrefixText = string.format("<font color='#FFFFFF'><b>[Noob]</b></font> %s", Color:ToHex(), message.PrefixText)
else
properties.PrefixText = string.format("<font color='#%s'>%s</font>", Color:ToHex(), message.PrefixText)
end
return properties
end
TextChatService.OnIncomingMessage = OnIncomingMessage
-
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
found nothing.