[SOLVED] I am trying to add tags into chat. What am I doing wrong?
Asked by
5 years ago Edited 5 years ago
01 | local ChatService = require(game:GetService( "ServerScriptService" ):WaitForChild( "ChatServiceRunner" ):WaitForChild( "ChatService" )) |
04 | local owners = { QuikSilver 09 = true , flameman 0987 = true } |
05 | local devs = { ThetaBird = true , dogbrainxd = true } |
08 | local ownerTag = { TagText = "OWNER" , TagColor = Color 3. fromRGB( 42 , 145 , 255 ) } |
09 | local VIPTag = { TagText = "VIP" , TagColor = Color 3. fromRGB( 255 , 206 , 7 ) } |
10 | local FANTag = { TagText = "Fan" , TagColor = Color 3. fromRGB( 43 , 255 , 43 ) } |
13 | game:GetService( "Players" ).PlayerAdded:Connect( function (player) |
14 | print ( "player JOINED" ) |
16 | if owners [ player.Name ] then |
18 | local speaker = ChatService:GetSpeaker(player.Name) |
19 | speaker:SetExtraData( "Tags" , ownerTag) |
20 | elseif player:WaitForChild( "Gamepasses" ):WaitForChild( "VIP" ).Value then |
21 | local speaker = ChatService:GetSpeaker(player.Name) |
22 | speaker:SetExtraData( "Tags" , VIPTag) |
23 | elseif player:IsInGroup( 4515569 ) then |
24 | local speaker = ChatService:GetSpeaker(player.Name) |
25 | speaker:SetExtraData( "Tags" , FANTag) |
I believe the issue is this line local ChatService = require(game:GetService("ServerScriptService"):WaitForChild("ChatServiceRunner"):WaitForChild("ChatService"))
I have commented it out and my PlayerAdded function runs just fine. I just do not know what to do considering I am getting no errors. Any help would be great, thanks.