public class TellRawMessage
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
TellRawMessage.ClickAction |
static class |
TellRawMessage.HoverAction |
| Constructor and Description |
|---|
TellRawMessage()
Creates a new Instance
|
TellRawMessage(java.lang.String text)
Creates a new Instance and adds some Text
|
| Modifier and Type | Method and Description |
|---|---|
TellRawMessage |
addClickEvent(TellRawMessage.ClickAction action,
java.lang.String value)
Adds a ClickEvent to the previously added
fragment
|
TellRawMessage |
addHoverEvent(TellRawMessage.HoverAction action,
java.lang.String value)
Adds a HoverEvent to the previously added
fragment
|
TellRawMessage |
addText(java.lang.String text)
Adds the specified Line of Text to your JSON Message
|
TellRawMessage |
addTranslation(java.lang.String key)
Adds a Text to the Message depending on the Users
Language
|
java.lang.String |
build()
Returns a String Object containing the previously
defined JSON fragments
|
TellRawMessage |
color(org.bukkit.ChatColor color)
Colors the previously added fragment
|
void |
send(org.bukkit.entity.Player... players)
Sends the JSON Message to the specified
Players
|
public TellRawMessage()
public TellRawMessage(java.lang.String text)
text - The Text you want to addpublic java.lang.String build()
public TellRawMessage addText(java.lang.String text)
text - The Text you want to addpublic TellRawMessage addTranslation(java.lang.String key)
key - The Key which is found in the .lang Filepublic TellRawMessage color(org.bukkit.ChatColor color)
color - The Color you want to addpublic TellRawMessage addClickEvent(TellRawMessage.ClickAction action, java.lang.String value)
action - The Action that will be runvalue - The Value for that Actionpublic TellRawMessage addHoverEvent(TellRawMessage.HoverAction action, java.lang.String value)
action - The Action that will be runvalue - The Value for that Actionpublic void send(org.bukkit.entity.Player... players)
throws java.lang.Exception
players - All Players who should receive the Messagejava.lang.Exception