public class ChatExtensions extends Object
| Constructor and Description |
|---|
ChatExtensions(ProtocolManager manager) |
| Modifier and Type | Method and Description |
|---|---|
void |
broadcastMessageSilently(String message,
String permission)
Broadcast a message without invoking any packet listeners.
|
static PacketContainer[] |
createChatPackets(String message)
Construct chat packet to send in order to display a given message.
|
void |
sendMessageSilently(org.bukkit.command.CommandSender receiver,
String message)
Send a message without invoking the packet listeners.
|
static String[] |
toFlowerBox(String[] message,
String marginChar,
int marginWidth,
int marginHeight)
Print a flower box around a given message.
|
public ChatExtensions(ProtocolManager manager)
public void sendMessageSilently(org.bukkit.command.CommandSender receiver,
String message)
throws InvocationTargetException
receiver - - the receiver.message - - the message to send.InvocationTargetException - If we were unable to send the message.public static PacketContainer[] createChatPackets(String message)
message - - the message to send.public void broadcastMessageSilently(String message, String permission) throws InvocationTargetException
message - - message to send.permission - - permission required to receieve the message. NULL to target everyone.InvocationTargetException - If we were unable to send the message.public static String[] toFlowerBox(String[] message, String marginChar, int marginWidth, int marginHeight)
message - - the message to print.marginChar - - the character to use as margin.marginWidth - - the width (in characters) of the left and right margin.marginHeight - - the height (in characters) of the top and buttom margin.Copyright © 2012–2017 Comphenix and dmulloy2. Licensed under the GNU GPL v2.