Search in sources :

Example 16 with PacketPlayOutPlayerInfo

use of net.minecraft.server.v1_12_R1.PacketPlayOutPlayerInfo in project Citizens2 by CitizensDev.

the class NMSImpl method sendTabListRemove.

@Override
public void sendTabListRemove(Player recipient, Player listPlayer) {
    Preconditions.checkNotNull(recipient);
    Preconditions.checkNotNull(listPlayer);
    EntityPlayer entity = ((CraftPlayer) listPlayer).getHandle();
    NMSImpl.sendPacket(recipient, new PacketPlayOutPlayerInfo(PacketPlayOutPlayerInfo.EnumPlayerInfoAction.REMOVE_PLAYER, entity));
}
Also used : EntityPlayer(net.minecraft.server.v1_10_R1.EntityPlayer) CraftPlayer(org.bukkit.craftbukkit.v1_10_R1.entity.CraftPlayer) PacketPlayOutPlayerInfo(net.minecraft.server.v1_10_R1.PacketPlayOutPlayerInfo)

Example 17 with PacketPlayOutPlayerInfo

use of net.minecraft.server.v1_12_R1.PacketPlayOutPlayerInfo in project Citizens2 by CitizensDev.

the class NMSImpl method sendTabListAdd.

@Override
public void sendTabListAdd(Player recipient, Player listPlayer) {
    Preconditions.checkNotNull(recipient);
    Preconditions.checkNotNull(listPlayer);
    EntityPlayer entity = ((CraftPlayer) listPlayer).getHandle();
    NMSImpl.sendPacket(recipient, new PacketPlayOutPlayerInfo(PacketPlayOutPlayerInfo.EnumPlayerInfoAction.ADD_PLAYER, entity));
}
Also used : EntityPlayer(net.minecraft.server.v1_8_R3.EntityPlayer) CraftPlayer(org.bukkit.craftbukkit.v1_8_R3.entity.CraftPlayer) PacketPlayOutPlayerInfo(net.minecraft.server.v1_8_R3.PacketPlayOutPlayerInfo)

Example 18 with PacketPlayOutPlayerInfo

use of net.minecraft.server.v1_12_R1.PacketPlayOutPlayerInfo in project Citizens2 by CitizensDev.

the class NMSImpl method sendTabListRemove.

@Override
public void sendTabListRemove(Player recipient, Player listPlayer) {
    Preconditions.checkNotNull(recipient);
    Preconditions.checkNotNull(listPlayer);
    EntityPlayer entity = ((CraftPlayer) listPlayer).getHandle();
    NMSImpl.sendPacket(recipient, new PacketPlayOutPlayerInfo(PacketPlayOutPlayerInfo.EnumPlayerInfoAction.REMOVE_PLAYER, entity));
}
Also used : EntityPlayer(net.minecraft.server.v1_8_R3.EntityPlayer) CraftPlayer(org.bukkit.craftbukkit.v1_8_R3.entity.CraftPlayer) PacketPlayOutPlayerInfo(net.minecraft.server.v1_8_R3.PacketPlayOutPlayerInfo)

Example 19 with PacketPlayOutPlayerInfo

use of net.minecraft.server.v1_12_R1.PacketPlayOutPlayerInfo in project Citizens2 by CitizensDev.

the class NMSImpl method sendTabListRemove.

@Override
public void sendTabListRemove(Player recipient, Collection<? extends SkinnableEntity> skinnableNPCs) {
    Preconditions.checkNotNull(recipient);
    Preconditions.checkNotNull(skinnableNPCs);
    EntityPlayer[] entities = new EntityPlayer[skinnableNPCs.size()];
    int i = 0;
    for (SkinnableEntity skinnable : skinnableNPCs) {
        entities[i] = (EntityPlayer) skinnable;
        i++;
    }
    NMSImpl.sendPacket(recipient, new PacketPlayOutPlayerInfo(PacketPlayOutPlayerInfo.EnumPlayerInfoAction.REMOVE_PLAYER, entities));
}
Also used : SkinnableEntity(net.citizensnpcs.npc.skin.SkinnableEntity) EntityPlayer(net.minecraft.server.v1_11_R1.EntityPlayer) PacketPlayOutPlayerInfo(net.minecraft.server.v1_11_R1.PacketPlayOutPlayerInfo) PathPoint(net.minecraft.server.v1_11_R1.PathPoint)

Example 20 with PacketPlayOutPlayerInfo

use of net.minecraft.server.v1_12_R1.PacketPlayOutPlayerInfo in project Citizens2 by CitizensDev.

the class NMSImpl method sendTabListRemove.

@Override
public void sendTabListRemove(Player recipient, Collection<? extends SkinnableEntity> skinnableNPCs) {
    Preconditions.checkNotNull(recipient);
    Preconditions.checkNotNull(skinnableNPCs);
    EntityPlayer[] entities = new EntityPlayer[skinnableNPCs.size()];
    int i = 0;
    for (SkinnableEntity skinnable : skinnableNPCs) {
        entities[i] = (EntityPlayer) skinnable;
        i++;
    }
    NMSImpl.sendPacket(recipient, new PacketPlayOutPlayerInfo(PacketPlayOutPlayerInfo.EnumPlayerInfoAction.REMOVE_PLAYER, entities));
}
Also used : SkinnableEntity(net.citizensnpcs.npc.skin.SkinnableEntity) EntityPlayer(net.minecraft.server.v1_12_R1.EntityPlayer) PacketPlayOutPlayerInfo(net.minecraft.server.v1_12_R1.PacketPlayOutPlayerInfo) PathPoint(net.minecraft.server.v1_12_R1.PathPoint)

Aggregations

PacketPlayOutPlayerInfo (net.minecraft.server.v1_10_R1.PacketPlayOutPlayerInfo)5 PacketPlayOutPlayerInfo (net.minecraft.server.v1_11_R1.PacketPlayOutPlayerInfo)5 PacketPlayOutPlayerInfo (net.minecraft.server.v1_8_R3.PacketPlayOutPlayerInfo)5 GameProfile (com.mojang.authlib.GameProfile)4 UUID (java.util.UUID)4 SkinnableEntity (net.citizensnpcs.npc.skin.SkinnableEntity)4 EntityPlayer (net.minecraft.server.v1_10_R1.EntityPlayer)4 EntityPlayer (net.minecraft.server.v1_11_R1.EntityPlayer)4 EntityPlayer (net.minecraft.server.v1_8_R3.EntityPlayer)4 Player (org.bukkit.entity.Player)4 BukkitRunnable (org.bukkit.scheduler.BukkitRunnable)4 EntityPlayer (net.minecraft.server.v1_12_R1.EntityPlayer)3 PacketPlayOutPlayerInfo (net.minecraft.server.v1_12_R1.PacketPlayOutPlayerInfo)3 CraftPlayer (org.bukkit.craftbukkit.v1_10_R1.entity.CraftPlayer)3 CraftPlayer (org.bukkit.craftbukkit.v1_11_R1.entity.CraftPlayer)3 CraftPlayer (org.bukkit.craftbukkit.v1_8_R3.entity.CraftPlayer)3 PacketPlayOutPlayerInfo (net.minecraft.server.v1_9_R2.PacketPlayOutPlayerInfo)2 CraftPlayer (org.bukkit.craftbukkit.v1_12_R1.entity.CraftPlayer)2 PacketPlayOutEntityDestroy (net.minecraft.server.v1_10_R1.PacketPlayOutEntityDestroy)1 PacketPlayOutNamedEntitySpawn (net.minecraft.server.v1_10_R1.PacketPlayOutNamedEntitySpawn)1