Changing bubble chat color

EDIT: To make sure that what I am looking for is a bit more clear, I am seeking a way to change the bubbles text color only and set so that it is only changed for certain group ranks.

Hi, I am working on a game that will have a moderation team for it, I have chat tags that display colored chat and colored tags. However I can not figure out how to have that same color also effect the default bubble chat. I have seen this in other games when in game moderation members speak, But have had no luck finding out how to implement this into my own game. Currently the chat tags are set up with group ranks. As shown below:

local Players = game:GetService("Players")

local ScriptService = game:GetService(“ServerScriptService”)
local ChatService = require(ScriptService:WaitForChild(“ChatServiceRunner”).ChatService)
local ranks = {
[“255”] = {TagText = “FOUNDER”, TagColor = Color3.fromRGB(233,30,99)},
[“254”] = {TagText = “CO FOUNDER”, TagColor = Color3.fromRGB(230,126,34)},
[“253”] = {TagText = “DEV”, TagColor = Color3.fromRGB(230,126,34)},
[“252”] = {TagText = “ADMINISTRATOR”, TagColor = Color3.fromRGB(46,204,113)},
[“251”] = {TagText = “MOD”, TagColor = Color3.fromRGB(32,102,148)},
[“100”] = {TagText = “Moderator-In-Training”, TagColor = Color3.fromRGB(76,188,206)},
}
local groupId = 4460143

ChatService.SpeakerAdded:Connect(function(SpeakerName)

if game.Players:FindFirstChild(SpeakerName) then 

	local plr = game.Players:FindFirstChild(SpeakerName) 

    local UserId = plr.UserId 
    local Speaker = ChatService:GetSpeaker(SpeakerName) 

    if plr.UserId == 99305466  then 

          Speaker:SetExtraData("Tags", {{TagText = "FOUNDER", TagColor = Color3.fromRGB(241,196,15)}}) 
          Speaker:SetExtraData("NameColor", Color3.fromRGB(241,196,15)) 

    elseif plr:IsInGroup(groupId) then 

        local rank = plr:GetRankInGroup(groupId)

        for i,tag in pairs(ranks) do 

            if i == tostring(rank) then 
                Speaker:SetExtraData("Tags", {{TagText = tag.TagText, TagColor = tag.TagColor}})
                Speaker:SetExtraData("NameColor", tag.TagColor) 
            end

        end   
 
    end

end

end)

Anyone know how this would be changed to allow bubble chat to set the color to in this case gold? Thank you in advance!

1 Like

In the future, please do make use of your search bar. It’ll help reveal questions that may have already been asked before. One of them may possess the answer you’re looking for.

Search query:
https://devforum.roblox.com/search?q=bubble%20chat%20color%20category%3A55

3 Likes

Thank you for your reply, I had searched in the main browser and have looked previously. I reviewed what you have posted however they did not solve my issue. I am looking to change the font color not the entire bubble, I am still unsure of how that would be done, and in a way for only certain group ranks. Not all players. Do you know how I would go about only changing the color of the text itself. I have been completely unable to find it anywhere. ( Only finding ones from 2012 that’s method no longer works ) Thanks again!

2 Likes