Search in sources :

Example 1 with PacketPlayOutAnimation

use of net.minecraft.network.protocol.game.PacketPlayOutAnimation in project PublicCrafters by BananaPuncher714.

the class ContainerManager_v1_17_1 method animate.

@Override
public void animate(Player player) {
    EntityPlayer NMSPlayer = ((CraftPlayer) player).getHandle();
    broadcastPacket(player, new PacketPlayOutAnimation(NMSPlayer, ThreadLocalRandom.current().nextInt(2) == 1 ? 0 : 3));
}
Also used : EntityPlayer(net.minecraft.server.level.EntityPlayer) CraftPlayer(org.bukkit.craftbukkit.v1_17_R1.entity.CraftPlayer) PacketPlayOutAnimation(net.minecraft.network.protocol.game.PacketPlayOutAnimation)

Example 2 with PacketPlayOutAnimation

use of net.minecraft.network.protocol.game.PacketPlayOutAnimation in project PublicCrafters by BananaPuncher714.

the class ContainerManager_v1_17_R1 method animate.

@Override
public void animate(Player player) {
    EntityPlayer NMSPlayer = ((CraftPlayer) player).getHandle();
    broadcastPacket(player, new PacketPlayOutAnimation(NMSPlayer, ThreadLocalRandom.current().nextInt(2) == 1 ? 0 : 3));
}
Also used : EntityPlayer(net.minecraft.server.level.EntityPlayer) CraftPlayer(org.bukkit.craftbukkit.v1_17_R1.entity.CraftPlayer) PacketPlayOutAnimation(net.minecraft.network.protocol.game.PacketPlayOutAnimation)

Example 3 with PacketPlayOutAnimation

use of net.minecraft.network.protocol.game.PacketPlayOutAnimation in project PublicCrafters by BananaPuncher714.

the class ContainerManager_v1_18_R2 method animate.

@Override
public void animate(Player player) {
    EntityPlayer NMSPlayer = ((CraftPlayer) player).getHandle();
    broadcastPacket(player, new PacketPlayOutAnimation(NMSPlayer, ThreadLocalRandom.current().nextInt(2) == 1 ? 0 : 3));
}
Also used : EntityPlayer(net.minecraft.server.level.EntityPlayer) CraftPlayer(org.bukkit.craftbukkit.v1_18_R2.entity.CraftPlayer) PacketPlayOutAnimation(net.minecraft.network.protocol.game.PacketPlayOutAnimation)

Example 4 with PacketPlayOutAnimation

use of net.minecraft.network.protocol.game.PacketPlayOutAnimation in project PublicCrafters by BananaPuncher714.

the class ContainerManager_v1_18_R1 method animate.

@Override
public void animate(Player player) {
    EntityPlayer NMSPlayer = ((CraftPlayer) player).getHandle();
    broadcastPacket(player, new PacketPlayOutAnimation(NMSPlayer, ThreadLocalRandom.current().nextInt(2) == 1 ? 0 : 3));
}
Also used : EntityPlayer(net.minecraft.server.level.EntityPlayer) CraftPlayer(org.bukkit.craftbukkit.v1_18_R1.entity.CraftPlayer) PacketPlayOutAnimation(net.minecraft.network.protocol.game.PacketPlayOutAnimation)

Aggregations

PacketPlayOutAnimation (net.minecraft.network.protocol.game.PacketPlayOutAnimation)4 EntityPlayer (net.minecraft.server.level.EntityPlayer)4 CraftPlayer (org.bukkit.craftbukkit.v1_17_R1.entity.CraftPlayer)2 CraftPlayer (org.bukkit.craftbukkit.v1_18_R1.entity.CraftPlayer)1 CraftPlayer (org.bukkit.craftbukkit.v1_18_R2.entity.CraftPlayer)1