Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

spigot send player action bar message 1.8

public static void sendMessage(Player p, String message) {
	PacketPlayOutChat packet = new PacketPlayOutChat(ChatSerializer.a("{"text":"" + message.replace("&", "§") + ""}"), (byte) 2);
	((CraftPlayer) p).getHandle().playerConnection.sendPacket(packet);
}
Source by bukkit.org #
 
PREVIOUS NEXT
Tagged: #spigot #send #player #action #bar #message
ADD COMMENT
Topic
Name
4+4 =