use of org.bukkit.craftbukkit.v1_5_R3.entity.CraftPlayer in project SpaciousLib by anhcraft.
the class ActionBar_1_11_R1 method send.
@Override
public void send(Player player, String text) {
PacketPlayOutChat title = new PacketPlayOutChat(IChatBaseComponent.ChatSerializer.a("{\"text\": \"" + ChatColor.translateAlternateColorCodes('&', text) + "\"}"), (byte) 2);
((CraftPlayer) player).getHandle().playerConnection.sendPacket(title);
}
use of org.bukkit.craftbukkit.v1_5_R3.entity.CraftPlayer in project SpaciousLib by anhcraft.
the class ActionBar_1_12_R1 method send.
@Override
public void send(Player player, String text) {
PacketPlayOutTitle title = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.ACTIONBAR, IChatBaseComponent.ChatSerializer.a("{\"text\": \"" + ChatColor.translateAlternateColorCodes('&', text) + "\"}"));
((CraftPlayer) player).getHandle().playerConnection.sendPacket(title);
}
use of org.bukkit.craftbukkit.v1_5_R3.entity.CraftPlayer in project SpaciousLib by anhcraft.
the class ActionBar_1_8_R1 method send.
@Override
public void send(World world, String text) {
for (Player player : world.getPlayers()) {
PacketPlayOutChat title = new PacketPlayOutChat(ChatSerializer.a("{\"text\": \"" + ChatColor.translateAlternateColorCodes('&', text) + "\"}"), (byte) 2);
((CraftPlayer) player).getHandle().playerConnection.sendPacket(title);
}
}
use of org.bukkit.craftbukkit.v1_5_R3.entity.CraftPlayer in project SpaciousLib by anhcraft.
the class ActionBar_1_8_R3 method send.
@Override
public void send(Player player, String text) {
PacketPlayOutChat title = new PacketPlayOutChat(IChatBaseComponent.ChatSerializer.a("{\"text\": \"" + ChatColor.translateAlternateColorCodes('&', text) + "\"}"), (byte) 2);
((CraftPlayer) player).getHandle().playerConnection.sendPacket(title);
}
use of org.bukkit.craftbukkit.v1_5_R3.entity.CraftPlayer in project SpaciousLib by anhcraft.
the class ActionBar_1_9_R1 method send.
@Override
public void send(Player player, String text) {
PacketPlayOutChat title = new PacketPlayOutChat(IChatBaseComponent.ChatSerializer.a("{\"text\": \"" + ChatColor.translateAlternateColorCodes('&', text) + "\"}"), (byte) 2);
((CraftPlayer) player).getHandle().playerConnection.sendPacket(title);
}
Aggregations