Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I use ChatSettings.BackGroundColor?

Asked by
Subbix -5
7 years ago

Hello, I have a quite odd question as I've been trying to manipulate ROBLOX's chat settings and customize it. I've tried this way which for an odd reason doesn't have any errors.

In basic sense I'm trying to change the background color of the chat area, I tried to change the text instead which I ultimately failed in the same way.

ServerScript in ServerScriptService

01local Players = game:GetService("Players")
02local ChatService = game:GetService("Chat")
03local ClientChatModules = ChatService:WaitForChild("ClientChatModules")
04local ChatSettings = require(ClientChatModules:WaitForChild("ChatSettings"))
05 
06 
07local whitelist = {
08    [191277713] = true;
09}
10 
11 
12Players.PlayerAdded:Connect(function(plr)
13    plr.Chatted:connect(function(msg)
14        if not whitelist[plr.UserId] then
15            ChatSettings.BackGroundColor = Color3.new(1, 1, 1)
16        else
17            ChatSettings.BackGroundColor = Color3.new(255, 255, 0)
18        end
19    end)
20end)

Answer this question