Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static String vorschreib(String text, String courser, String vorschreibtext){
- String chat = "{\"text\":\""+text+"\",\"clickEvent\":{\"action\":\"suggest_command\",\"value\":\""+vorschreibtext+"\"},\"hoverEvent\":{\"action\":\"show_text\",\"value\":{\"text\":\"\",\"extra\":[{\"text\":\""+courser+"\"}]}}}";
- return chat;
- }
- public static String ausfhren(String text, String courser, String ausfhrtext){
- String chat = "{\"text\":\""+text+"\",\"clickEvent\":{\"action\":\"run_command\",\"value\":\""+ausfhrtext+"\"},\"hoverEvent\":{\"action\":\"show_text\",\"value\":{\"text\":\"\",\"extra\":[{\"text\":\""+courser+"\"}]}}}";
- return chat;
- }
- public static String nrmltext(String text){
- String chat = "{\"text\":\""+text+"\"}";
- return chat;
- }
- public static void sendMessage(Player p, String serializer){
- IChatBaseComponent chat = ChatSerializer.a("[\"\","+serializer+"]");
- PacketPlayOutChat packet = new PacketPlayOutChat(chat);
- ((CraftPlayer)p).getHandle().playerConnection.sendPacket(packet);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement