Chatted Event Doesn't Fire With Team And Whisper Chat

According to the wiki, the chatted event should fire when a player uses the whisper chat or team chat, but it doesn’t seem to work (and appears to crash in studio for team chat in play solo).

Local script I use:

game.Players.LocalPlayer.Chatted:connect(function(Text,Recipient) print(Text.." ; "..tostring(Recipient)) end)

1 Like

I think teamchat only fires it if it’s a server script monitoring it – not sure about whispering.

Wasn’t working when I did it using the command line from the console.

This has been the case for a long time now, I think the Wiki is outdated. I don’t think it’s a bug.

What are your needs exactly? Could you consider capturing key inputs as a workaround, or even a custom chat system?

It would be great to have it fire again when in TeamChat. I was working on something for a group, everything was done except some chat stuff but I still want to use the default .Chatted (for other scripts where I don’t have control over for example).

As far as I can understand from the notes (The recipient value is the player to who the message is whispered, or nil when it’s a message sent to the team or to everyone.) it should fire upon TeamChat / Whisper (but this isn’t the case obviously). Maybe unlocking game.Players.PlayerChatted for scripts would be great to do server sided stuff. Afaik it’s used in the corescripts, Core-Scripts/CoreScriptsRoot/Modules/Chat.lua at master · Roblox/Core-Scripts · GitHub but not accessible from scripts etc.