ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Shared functions
  3. clearChatBox

Function

clearChatBox

Server and clientChat and consoleIdentical to MTA:SA

Clears the chat box. On the server it clears the chat for one player or, with no argument, for everyone.

Syntax

Server

bool clearChatBox([element clearFor = root])

Client

bool clearChatBox()

Arguments

clearForelement, optional = root
A player, or an element whose players get an empty chat (server only).

Returns

true on success.

Example

addCommandHandler("cc", function(player)
    clearChatBox()
    outputChatBox("Czat wyczyścił " .. getPlayerName(player), root, 255, 200, 0)
end)

See also