public class ChatHandler
extends java.lang.Object
Constructor and Description |
---|
ChatHandler() |
Modifier and Type | Method and Description |
---|---|
static net.minecraft.util.text.TranslationTextComponent |
getMessage(java.lang.String string,
java.lang.Object... data)
Gets a translated message for later use.
|
static void |
sendBattleMessage(net.minecraft.entity.Entity user,
java.lang.String string,
java.lang.Object... data)
Sends a battle message to a player.
|
static void |
sendBattleMessage(net.minecraft.entity.Entity user,
net.minecraft.util.text.TranslationTextComponent chat)
Sends a battle message to a player.
|
static void |
sendBattleMessage(java.util.List<BattleParticipant> participants,
java.lang.String string,
java.lang.Object... data)
Sends a battle message to participants in a battle.
|
static void |
sendBattleMessage(java.util.List<BattleParticipant> participants,
net.minecraft.util.text.TranslationTextComponent message)
Sends a battle message to all participants in a battle.
|
static void |
sendChat(net.minecraft.entity.Entity entityLiving,
java.lang.String string,
java.lang.Object... data)
Sends a message to a player.
|
static void |
sendChat(net.minecraft.command.ICommandSource owner,
net.minecraft.command.ICommandSource owner2,
java.lang.String string,
java.lang.Object... data)
Sends a message to two players.
|
static void |
sendChat(net.minecraft.command.ICommandSource receiver,
net.minecraft.util.text.TranslationTextComponent message)
Sends a message to a player.
|
static void |
sendFormattedChat(net.minecraft.command.ICommandSource receiver,
net.minecraft.util.text.TextFormatting chatFormat,
java.lang.String string,
java.lang.Object... data)
Sends a formatted message to a player.
|
static void |
sendMessageToAllPlayers(net.minecraft.server.MinecraftServer minecraftServer,
java.lang.String string,
java.lang.Object... data)
Sends a message to all players on the server.
|
public static void sendChat(net.minecraft.entity.Entity entityLiving, java.lang.String string, java.lang.Object... data)
entityLiving
- The player to send the message to.string
- The message to send.data
- Additional arguments for the message.public static void sendChat(net.minecraft.command.ICommandSource receiver, net.minecraft.util.text.TranslationTextComponent message)
receiver
- The player to send the message to.message
- The message to send.public static void sendChat(net.minecraft.command.ICommandSource owner, net.minecraft.command.ICommandSource owner2, java.lang.String string, java.lang.Object... data)
owner
- A player to send the message to.owner2
- A player to send the message to.string
- The message to send.data
- Additional arguments for the message.public static void sendFormattedChat(net.minecraft.command.ICommandSource receiver, net.minecraft.util.text.TextFormatting chatFormat, java.lang.String string, java.lang.Object... data)
receiver
- The player to send the message to.chatFormat
- The format to apply to the message.string
- The message to send.data
- Additional arguments for the message.public static void sendBattleMessage(net.minecraft.entity.Entity user, java.lang.String string, java.lang.Object... data)
user
- The player to send the message to.string
- The message to send.data
- Additional arguments for the message.public static void sendBattleMessage(net.minecraft.entity.Entity user, net.minecraft.util.text.TranslationTextComponent chat)
user
- The player to send the message to.chat
- The message to send.public static void sendBattleMessage(java.util.List<BattleParticipant> participants, java.lang.String string, java.lang.Object... data)
participants
- The participants of the battle to send a message to.string
- The message to send.data
- Additional arguments for the message.public static void sendBattleMessage(java.util.List<BattleParticipant> participants, net.minecraft.util.text.TranslationTextComponent message)
participants
- The participants of the battle.message
- The message to send.public static net.minecraft.util.text.TranslationTextComponent getMessage(java.lang.String string, java.lang.Object... data)
string
- The base message.data
- Additional arguments for the message.public static void sendMessageToAllPlayers(net.minecraft.server.MinecraftServer minecraftServer, java.lang.String string, java.lang.Object... data)
minecraftServer
- string
- The message to send.