Functions/DarkRP/Server/talkToRange

From DarkRP
Function
Function name DarkRP.talkToRange(Player ply, string playerName, string message, number size)
Description:
Send a chat message to people close to a player.
Returns: nil
Part of Library: DarkRP
Realm:
BBCode Link: [b][url=http://wiki.darkrp.com/index.php?title=Functions/DarkRP/Server/talkToRange]DarkRP.talkToRange[/url][/b]

Function parameters[edit]

  1. ply (Player)
  2. The sender of the message.

  3. playerName (string)
  4. The name of the sender of the message.

  5. message (string)
  6. The actual message.

  7. size (number)
  8. The radius of the circle in which players can see the message in chat.


Function return values[edit]

This function does not return any value.

Example Code[edit]

concommand.Add("mecommand", function(ply,_,text)
    DarkRP.talkToRange(ply, ply:Nick() .. " " .. text, "", GAMEMODE.Config.meDistance)
end)

Result of Code: Pavetr performed some /me action