I’m trying to turn the TextColor3 of a TextLabel into the same color as the TeamColor of the Team the Player is currently on. I’ve tried converting it to RGB, but it doesn’t seem to work.
Anybody have any ideas on how to get this to work?
local TeamColor = Player.Team.TeamColor
local TeamR = TeamColor.r
local TeamG = TeamColor.g
local TeamB = TeamColor.b
Looks like error comes from outside of that.
1: LocalPlayer only works in LocalScript, that only works in client.
2: Are you sure you are using Roblox’s team system?
I assume the text color becomes black, that’s because the .r, .g, .b values are normalized between 0 and 1, but Color3.fromRGB accepts values that are between 0 and 255. The solution is to either multiply with 255 or use Color3.new that accepts 0-1 values. Therefore: