Rich Text not working

This is a live score updater for a soccer game. I want to make the scores look different so you can tell whose is what teams.
Now for some reason, this is what it shows after it gets set.


it is not quite rich texted

Here is my code for the updater.

local textlabel = script.Parent
local scoreUpdate = game.ReplicatedStorage.RemoteEvents.ScoreUpdate

textlabel.RichText = true

scoreUpdate.OnClientEvent:Connect(function(rv,bv)
	local redvalue = tostring(rv)
	local bluevalue = tostring(bv)
	
	textlabel.Text = '<font color="#ff5050">'..redvalue..'</font> - <font color="#29dbff">'..bluevalue
end)

If you know why, please tell me! This is driving me CRAZY!

You forgot to add '</font> after .. bluevalue ..

local textlabel = script.Parent
local scoreUpdate = game.ReplicatedStorage.RemoteEvents.ScoreUpdate

-- Use RichText for Rich Text formatting
textlabel.RichText = true

scoreUpdate.OnClientEvent:Connect(function(rv, bv)
    local redvalue = tostring(rv)
    local bluevalue = tostring(bv)
    
    -- Set the Text with Rich Text formatting
    textlabel.Text = '<font color="#ff5050">' .. redvalue .. '</font> - <font color="#29dbff">' .. bluevalue .. '</font>'
end)

thank you!!!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.