PocketMine-MP 5.15.1 git-5ef247620a7c6301a849b54e5ef1009217729fc8
pocketmine\player\chat\ChatFormatter Interface Reference
+ Inheritance diagram for pocketmine\player\chat\ChatFormatter:
+ Collaboration diagram for pocketmine\player\chat\ChatFormatter:

Public Member Functions

 format (string $username, string $message)
 

Detailed Description

Formats chat messages for broadcasting. Used in PlayerChatEvent.

Definition at line 31 of file ChatFormatter.php.

Member Function Documentation

◆ format()

pocketmine\player\chat\ChatFormatter::format ( string  $username,
string  $message 
)

Returns the formatted message to broadcast. This can return a plain string (which will be used as-is) or a Translatable (which will be translated into each recipient's language).

Implemented in pocketmine\player\chat\LegacyRawChatFormatter, and pocketmine\player\chat\StandardChatFormatter.


The documentation for this interface was generated from the following file: