use of net.minecraft.server.v1_16_R3.PacketPlayOutCloseWindow in project TheAPI by TheDevTec.
the class v1_8_R1 method closeGUI.
@Override
public void closeGUI(Player player, Object container, boolean closePacket) {
if (closePacket)
BukkitLoader.getPacketHandler().send(player, new PacketPlayOutCloseWindow(BukkitLoader.getNmsProvider().getContainerId(container)));
EntityPlayer nmsPlayer = (EntityPlayer) getPlayer(player);
nmsPlayer.activeContainer = nmsPlayer.defaultContainer;
((Container) container).transferTo(nmsPlayer.activeContainer, (CraftPlayer) player);
}
use of net.minecraft.server.v1_16_R3.PacketPlayOutCloseWindow in project TheAPI by TheDevTec.
the class v1_16_R1 method closeGUI.
@Override
public void closeGUI(Player player, Object container, boolean closePacket) {
if (closePacket)
BukkitLoader.getPacketHandler().send(player, new PacketPlayOutCloseWindow(BukkitLoader.getNmsProvider().getContainerId(container)));
EntityPlayer nmsPlayer = (EntityPlayer) getPlayer(player);
nmsPlayer.activeContainer = nmsPlayer.defaultContainer;
((Container) container).transferTo(nmsPlayer.activeContainer, (CraftPlayer) player);
}
use of net.minecraft.server.v1_16_R3.PacketPlayOutCloseWindow in project TheAPI by TheDevTec.
the class v1_8_R2 method closeGUI.
@Override
public void closeGUI(Player player, Object container, boolean closePacket) {
if (closePacket)
BukkitLoader.getPacketHandler().send(player, new PacketPlayOutCloseWindow(BukkitLoader.getNmsProvider().getContainerId(container)));
EntityPlayer nmsPlayer = (EntityPlayer) getPlayer(player);
nmsPlayer.activeContainer = nmsPlayer.defaultContainer;
((Container) container).transferTo(nmsPlayer.activeContainer, (CraftPlayer) player);
}
use of net.minecraft.server.v1_16_R3.PacketPlayOutCloseWindow in project TheAPI by TheDevTec.
the class v1_11_R1 method closeGUI.
@Override
public void closeGUI(Player player, Object container, boolean closePacket) {
if (closePacket)
BukkitLoader.getPacketHandler().send(player, new PacketPlayOutCloseWindow(BukkitLoader.getNmsProvider().getContainerId(container)));
EntityPlayer nmsPlayer = (EntityPlayer) getPlayer(player);
nmsPlayer.activeContainer = nmsPlayer.defaultContainer;
((Container) container).transferTo(nmsPlayer.activeContainer, (CraftPlayer) player);
}
use of net.minecraft.server.v1_16_R3.PacketPlayOutCloseWindow in project TheAPI by TheDevTec.
the class v1_16_R2 method closeGUI.
@Override
public void closeGUI(Player player, Object container, boolean closePacket) {
if (closePacket)
BukkitLoader.getPacketHandler().send(player, new PacketPlayOutCloseWindow(BukkitLoader.getNmsProvider().getContainerId(container)));
EntityPlayer nmsPlayer = (EntityPlayer) getPlayer(player);
nmsPlayer.activeContainer = nmsPlayer.defaultContainer;
((Container) container).transferTo(nmsPlayer.activeContainer, (CraftPlayer) player);
}
Aggregations