of     1   

Extuls
#139505407Monday, July 07, 2014 5:33 AM GMT

game.Players.PlayerAdded:connect(function(plr) plr.Chatted:connect(function(msg, rec) PlayerChat(msg, rec, plr) end) end) I have a chat GUI that connects users' chats to it through those three lines of code. For some reason that I don't know, a player's chat will just disconnect from the chat GUI for a reason I don't know. Could anyone tell me why from those three lines of code? Or could something in the function cause it to be disconnecting?
Casualist
#139505628Monday, July 07, 2014 5:36 AM GMT

There shouldn't be a problem with that, the event should remain connected until you call :disconnect() on it, or they leave. Since neither is occurring my guess is that PlayerChat hosts the problem.
Extuls
#139505957Monday, July 07, 2014 5:40 AM GMT

Anything you can think of that could cause a problem like that? The function is pretty lengthy, and would be annoying to read here.

    of     1