本文整理匯總了Java中net.minecraft.network.packet.Packet100OpenWindow類的典型用法代碼示例。如果您正苦於以下問題:Java Packet100OpenWindow類的具體用法?Java Packet100OpenWindow怎麽用?Java Packet100OpenWindow使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
Packet100OpenWindow類屬於net.minecraft.network.packet包,在下文中一共展示了Packet100OpenWindow類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: func_71030_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_71030_a(IMerchant p_71030_1_, String p_71030_2_) {
this.func_71117_bO();
this.field_71070_bA = new ContainerMerchant(this.field_71071_by, p_71030_1_, this.field_70170_p);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
InventoryMerchant var3 = ((ContainerMerchant)this.field_71070_bA).func_75174_d();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 6, p_71030_2_ == null?"":p_71030_2_, var3.func_70302_i_(), p_71030_2_ != null));
MerchantRecipeList var4 = p_71030_1_.func_70934_b(this);
if(var4 != null) {
try {
ByteArrayOutputStream var5 = new ByteArrayOutputStream();
DataOutputStream var6 = new DataOutputStream(var5);
var6.writeInt(this.field_71139_cq);
var4.func_77200_a(var6);
this.field_71135_a.func_72567_b(new Packet250CustomPayload("MC|TrList", var5.toByteArray()));
} catch (IOException var7) {
var7.printStackTrace();
}
}
}
示例2: displayGUIMerchant
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void displayGUIMerchant(IMerchant par1IMerchant, String par2Str)
{
this.incrementWindowID();
this.openContainer = new ContainerMerchant(this.inventory, par1IMerchant, this.worldObj);
this.openContainer.windowId = this.currentWindowId;
this.openContainer.addCraftingToCrafters(this);
InventoryMerchant inventorymerchant = ((ContainerMerchant)this.openContainer).getMerchantInventory();
this.playerNetServerHandler.sendPacketToPlayer(new Packet100OpenWindow(this.currentWindowId, 6, par2Str == null ? "" : par2Str, inventorymerchant.getSizeInventory(), par2Str != null));
MerchantRecipeList merchantrecipelist = par1IMerchant.getRecipes(this);
if (merchantrecipelist != null)
{
try
{
ByteArrayOutputStream bytearrayoutputstream = new ByteArrayOutputStream();
DataOutputStream dataoutputstream = new DataOutputStream(bytearrayoutputstream);
dataoutputstream.writeInt(this.currentWindowId);
merchantrecipelist.writeRecipiesToStream(dataoutputstream);
this.playerNetServerHandler.sendPacketToPlayer(new Packet250CustomPayload("MC|TrList", bytearrayoutputstream.toByteArray()));
}
catch (IOException ioexception)
{
ioexception.printStackTrace();
}
}
}
示例3: func_71058_b
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_71058_b(int p_71058_1_, int p_71058_2_, int p_71058_3_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 1, "Crafting", 9, true));
this.field_71070_bA = new ContainerWorkbench(this.field_71071_by, this.field_70170_p, p_71058_1_, p_71058_2_, p_71058_3_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例4: func_71002_c
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_71002_c(int p_71002_1_, int p_71002_2_, int p_71002_3_, String p_71002_4_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 4, p_71002_4_ == null?"":p_71002_4_, 9, p_71002_4_ != null));
this.field_71070_bA = new ContainerEnchantment(this.field_71071_by, this.field_70170_p, p_71002_1_, p_71002_2_, p_71002_3_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例5: func_82244_d
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_82244_d(int p_82244_1_, int p_82244_2_, int p_82244_3_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 8, "Repairing", 9, true));
this.field_71070_bA = new ContainerRepair(this.field_71071_by, this.field_70170_p, p_82244_1_, p_82244_2_, p_82244_3_, this);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例6: func_71007_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_71007_a(IInventory p_71007_1_) {
if(this.field_71070_bA != this.field_71069_bz) {
this.func_71053_j();
}
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 0, p_71007_1_.func_70303_b(), p_71007_1_.func_70302_i_(), p_71007_1_.func_94042_c()));
this.field_71070_bA = new ContainerChest(this.field_71071_by, p_71007_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例7: func_94064_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_94064_a(TileEntityHopper p_94064_1_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 9, p_94064_1_.func_70303_b(), p_94064_1_.func_70302_i_(), p_94064_1_.func_94042_c()));
this.field_71070_bA = new ContainerHopper(this.field_71071_by, p_94064_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例8: func_96125_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_96125_a(EntityMinecartHopper p_96125_1_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 9, p_96125_1_.func_70303_b(), p_96125_1_.func_70302_i_(), p_96125_1_.func_94042_c()));
this.field_71070_bA = new ContainerHopper(this.field_71071_by, p_96125_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例9: func_71042_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_71042_a(TileEntityFurnace p_71042_1_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 2, p_71042_1_.func_70303_b(), p_71042_1_.func_70302_i_(), p_71042_1_.func_94042_c()));
this.field_71070_bA = new ContainerFurnace(this.field_71071_by, p_71042_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例10: func_71006_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_71006_a(TileEntityDispenser p_71006_1_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, p_71006_1_ instanceof TileEntityDropper?10:3, p_71006_1_.func_70303_b(), p_71006_1_.func_70302_i_(), p_71006_1_.func_94042_c()));
this.field_71070_bA = new ContainerDispenser(this.field_71071_by, p_71006_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例11: func_71017_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_71017_a(TileEntityBrewingStand p_71017_1_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 5, p_71017_1_.func_70303_b(), p_71017_1_.func_70302_i_(), p_71017_1_.func_94042_c()));
this.field_71070_bA = new ContainerBrewingStand(this.field_71071_by, p_71017_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例12: func_82240_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_82240_a(TileEntityBeacon p_82240_1_) {
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 7, p_82240_1_.func_70303_b(), p_82240_1_.func_70302_i_(), p_82240_1_.func_94042_c()));
this.field_71070_bA = new ContainerBeacon(this.field_71071_by, p_82240_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例13: func_110298_a
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void func_110298_a(EntityHorse p_110298_1_, IInventory p_110298_2_) {
if(this.field_71070_bA != this.field_71069_bz) {
this.func_71053_j();
}
this.func_71117_bO();
this.field_71135_a.func_72567_b(new Packet100OpenWindow(this.field_71139_cq, 11, p_110298_2_.func_70303_b(), p_110298_2_.func_70302_i_(), p_110298_2_.func_94042_c(), p_110298_1_.field_70157_k));
this.field_71070_bA = new ContainerHorseInventory(this.field_71071_by, p_110298_2_, p_110298_1_);
this.field_71070_bA.field_75152_c = this.field_71139_cq;
this.field_71070_bA.func_75132_a(this);
}
示例14: displayGUIWorkbench
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
/**
* Displays the crafting GUI for a workbench.
*/
public void displayGUIWorkbench(int par1, int par2, int par3)
{
this.incrementWindowID();
this.playerNetServerHandler.sendPacketToPlayer(new Packet100OpenWindow(this.currentWindowId, 1, "Crafting", 9, true));
this.openContainer = new ContainerWorkbench(this.inventory, this.worldObj, par1, par2, par3);
this.openContainer.windowId = this.currentWindowId;
this.openContainer.addCraftingToCrafters(this);
}
示例15: displayGUIEnchantment
import net.minecraft.network.packet.Packet100OpenWindow; //導入依賴的package包/類
public void displayGUIEnchantment(int par1, int par2, int par3, String par4Str)
{
this.incrementWindowID();
this.playerNetServerHandler.sendPacketToPlayer(new Packet100OpenWindow(this.currentWindowId, 4, par4Str == null ? "" : par4Str, 9, par4Str != null));
this.openContainer = new ContainerEnchantment(this.inventory, this.worldObj, par1, par2, par3);
this.openContainer.windowId = this.currentWindowId;
this.openContainer.addCraftingToCrafters(this);
}