本文整理汇总了Java中net.minecraft.network.play.server.S30PacketWindowItems类的典型用法代码示例。如果您正苦于以下问题:Java S30PacketWindowItems类的具体用法?Java S30PacketWindowItems怎么用?Java S30PacketWindowItems使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
S30PacketWindowItems类属于net.minecraft.network.play.server包,在下文中一共展示了S30PacketWindowItems类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: handleWindowItems
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
/**
* Handles the placement of a specified ItemStack in a specified container/inventory slot
*/
public void handleWindowItems(S30PacketWindowItems packetIn)
{
PacketThreadUtil.checkThreadAndEnqueue(packetIn, this, this.gameController);
EntityPlayer entityplayer = this.gameController.thePlayer;
if (packetIn.func_148911_c() == 0)
{
entityplayer.inventoryContainer.putStacksInSlots(packetIn.getItemStacks());
}
else if (packetIn.func_148911_c() == entityplayer.openContainer.windowId)
{
entityplayer.openContainer.putStacksInSlots(packetIn.getItemStacks());
}
}
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:18,代码来源:NetHandlerPlayClient.java
示例2: handleWindowItems
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
/**
* Handles the placement of a specified ItemStack in a specified
* container/inventory slot
*/
public void handleWindowItems(S30PacketWindowItems packetIn) {
PacketThreadUtil.checkThreadAndEnqueue(packetIn, this, this.gameController);
EntityPlayer entityplayer = this.gameController.thePlayer;
if (packetIn.func_148911_c() == 0) {
entityplayer.inventoryContainer.putStacksInSlots(packetIn.getItemStacks());
} else if (packetIn.func_148911_c() == entityplayer.openContainer.windowId) {
entityplayer.openContainer.putStacksInSlots(packetIn.getItemStacks());
}
}
开发者ID:SkidJava,项目名称:BaseClient,代码行数:15,代码来源:NetHandlerPlayClient.java
示例3: handleWindowItems
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
/**
* Handles the placement of a specified ItemStack in a specified container/inventory slot
*/
public void handleWindowItems(S30PacketWindowItems p_147241_1_)
{
EntityClientPlayerMP var2 = this.gameController.thePlayer;
if (p_147241_1_.func_148911_c() == 0)
{
var2.inventoryContainer.putStacksInSlots(p_147241_1_.func_148910_d());
}
else if (p_147241_1_.func_148911_c() == var2.openContainer.windowId)
{
var2.openContainer.putStacksInSlots(p_147241_1_.func_148910_d());
}
}
开发者ID:MinecraftModdedClients,项目名称:Resilience-Client-Source,代码行数:17,代码来源:NetHandlerPlayClient.java
示例4: sendContainerAndContentsToPlayer
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
public void sendContainerAndContentsToPlayer(Container p_71110_1_, List p_71110_2_)
{
this.playerNetServerHandler.sendPacket(new S30PacketWindowItems(p_71110_1_.windowId, p_71110_2_));
this.playerNetServerHandler.sendPacket(new S2FPacketSetSlot(-1, -1, this.inventory.getItemStack()));
if (p_71110_1_.getBukkitView() == null) return; // Cauldron - allow vanilla mods to bypass
// CraftBukkit start - Send a Set Slot to update the crafting result slot
if (java.util.EnumSet.of(InventoryType.CRAFTING, InventoryType.WORKBENCH).contains(p_71110_1_.getBukkitView().getType()))
{
this.playerNetServerHandler.sendPacket(new S2FPacketSetSlot(p_71110_1_.windowId, 0, p_71110_1_.getSlot(0).getStack()));
}
// CraftBukkit end
}
开发者ID:xtrafrancyz,项目名称:Cauldron,代码行数:15,代码来源:EntityPlayerMP.java
示例5: handleWindowItems
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
public void handleWindowItems(S30PacketWindowItems p_147241_1_)
{
EntityClientPlayerMP entityclientplayermp = this.gameController.thePlayer;
if (p_147241_1_.func_148911_c() == 0)
{
entityclientplayermp.inventoryContainer.putStacksInSlots(p_147241_1_.func_148910_d());
}
else if (p_147241_1_.func_148911_c() == entityclientplayermp.openContainer.windowId)
{
entityclientplayermp.openContainer.putStacksInSlots(p_147241_1_.func_148910_d());
}
}
开发者ID:xtrafrancyz,项目名称:Cauldron,代码行数:14,代码来源:NetHandlerPlayClient.java
示例6: updateCraftingInventory
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
/**
* update the crafting window inventory with the items in the list
*/
public void updateCraftingInventory(Container containerToSend, List<ItemStack> itemsList)
{
this.playerNetServerHandler.sendPacket(new S30PacketWindowItems(containerToSend.windowId, itemsList));
this.playerNetServerHandler.sendPacket(new S2FPacketSetSlot(-1, -1, this.inventory.getItemStack()));
}
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:9,代码来源:EntityPlayerMP.java
示例7: sendContainerAndContentsToPlayer
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
public void sendContainerAndContentsToPlayer(Container par1Container, List par2List)
{
this.playerNetServerHandler.sendPacket(new S30PacketWindowItems(par1Container.windowId, par2List));
this.playerNetServerHandler.sendPacket(new S2FPacketSetSlot(-1, -1, this.inventory.getItemStack()));
}
开发者ID:MinecraftModdedClients,项目名称:Resilience-Client-Source,代码行数:6,代码来源:EntityPlayerMP.java
示例8: sendContainerAndContentsToPlayer
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
public void sendContainerAndContentsToPlayer(Container p_71110_1_, List p_71110_2_)
{
this.playerNetServerHandler.sendPacket(new S30PacketWindowItems(p_71110_1_.windowId, p_71110_2_));
this.playerNetServerHandler.sendPacket(new S2FPacketSetSlot(-1, -1, this.inventory.getItemStack()));
}
开发者ID:xtrafrancyz,项目名称:Cauldron,代码行数:6,代码来源:EntityPlayerMP.java
示例9: handleWindowItems
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
/**
* Handles the placement of a specified ItemStack in a specified container/inventory slot
*/
void handleWindowItems(S30PacketWindowItems packetIn);
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:5,代码来源:INetHandlerPlayClient.java
示例10: handleWindowItems
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
/**
* Handles the placement of a specified ItemStack in a specified container/inventory slot
*/
void handleWindowItems(S30PacketWindowItems var1);
开发者ID:MinecraftModdedClients,项目名称:Resilience-Client-Source,代码行数:5,代码来源:INetHandlerPlayClient.java
示例11: handleWindowItems
import net.minecraft.network.play.server.S30PacketWindowItems; //导入依赖的package包/类
void handleWindowItems(S30PacketWindowItems p_147241_1_);
开发者ID:xtrafrancyz,项目名称:Cauldron,代码行数:2,代码来源:INetHandlerPlayClient.java
注:本文中的net.minecraft.network.play.server.S30PacketWindowItems类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论