game.Players.PlayerAdded:Connect(function(player) player.Chatted:Connect(function(msg) -- do stuff with msg and player end) end) code example
Example: roblox lua on player chatted
game.Players.PlayerAdded:Connect(function(player)
player.Chatted:Connect(function(msg)
-- do stuff with msg and player
end)
end)