use of net.minecraft.server.v1_15_R1.PlayerConnection in project WLib by WizardlyBump17.
the class EntityAdapter method sendPacket.
@Override
public void sendPacket(Object... packets) {
if (!(entity instanceof Player))
return;
EntityPlayer player = ((CraftPlayer) entity).getHandle();
PlayerConnection connection = player.playerConnection;
for (Object packet : packets) {
if (!(packet instanceof Packet))
continue;
connection.sendPacket(((Packet<?>) packet));
}
}
use of net.minecraft.server.v1_15_R1.PlayerConnection in project WLib by WizardlyBump17.
the class EntityAdapter method sendPacket.
@Override
public void sendPacket(Object... packets) {
if (!(entity instanceof Player))
return;
EntityPlayer player = ((CraftPlayer) entity).getHandle();
PlayerConnection connection = player.playerConnection;
for (Object packet : packets) {
if (!(packet instanceof Packet))
continue;
connection.sendPacket(((Packet<?>) packet));
}
}
Aggregations