Chatted (Event)/player: Difference between revisions

From Legacy Roblox Wiki
Jump to navigationJump to search
>NXTBoy
New page: {{Event |name = Chatted |arguments = String ''message'', Instance ''recipient'' |description = Fired when the owning player types a chat in chat bar or selects a phrase in...
>MrNicNac
No edit summary
Line 1: Line 1:
<onlyinclude>
{{Event
{{Event
|name        = Chatted
|name        = Chatted
Line 4: Line 5:
|description = Fired when the owning player types a chat in chat bar or selects a phrase in safe chat menu.
|description = Fired when the owning player types a chat in chat bar or selects a phrase in safe chat menu.
|object      = Player
|object      = Player
}}
}}</onlyinclude>
{{clear floats}}
 
== Usage ==
This is an example of connecting the chatted event to all incoming players.
<pre>
Game.Players.PlayerAdded:connect(function(player)
  player.Chatted:connect(function(msg)
    if msg == "reset" then
      player.Character:BreakJoints()
    end
  end)
end)
</pre>

Revision as of 22:21, 23 June 2011

Chatted ( String message, Instance recipient )
Description Fired when the owning player types a chat in chat bar or selects a phrase in safe chat menu.
Member of: Player


Usage

This is an example of connecting the chatted event to all incoming players.

Game.Players.PlayerAdded:connect(function(player)
  player.Chatted:connect(function(msg)
    if msg == "reset" then
      player.Character:BreakJoints()
    end
  end)
end)