-
Notifications
You must be signed in to change notification settings - Fork 755
/
ArmorExtendedContainer.java
58 lines (49 loc) · 1.98 KB
/
ArmorExtendedContainer.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
package tconstruct.armor.inventory;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.InventoryPlayer;
import net.minecraft.inventory.Slot;
import net.minecraft.item.ItemStack;
import tconstruct.armor.player.ArmorExtended;
import tconstruct.smeltery.inventory.ActiveContainer;
public class ArmorExtendedContainer extends ActiveContainer
{
public InventoryPlayer invPlayer;
public ArmorExtended armor;
public ArmorExtendedContainer(InventoryPlayer inventoryplayer, ArmorExtended armor)
{
invPlayer = inventoryplayer;
this.armor = armor;
this.addSlotToContainer(new SlotAccessory(armor, 0, 80, 17));
this.addSlotToContainer(new SlotAccessory(armor, 1, 80, 35));
this.addSlotToContainer(new SlotAccessory(armor, 2, 116, 17));
this.addSlotToContainer(new SlotAccessory(armor, 3, 116, 35));
this.addSlotToContainer(new SlotAccessory(armor, 4, 152, 53));
this.addSlotToContainer(new SlotAccessory(armor, 5, 152, 35));
this.addSlotToContainer(new SlotAccessory(armor, 6, 152, 17));
for (int playerArmor = 0; playerArmor < 4; ++playerArmor)
{
this.addSlotToContainer(new SlotArmorCopy(this, inventoryplayer, inventoryplayer.getSizeInventory() - 1 - playerArmor, 98, 8 + playerArmor * 18, playerArmor));
}
for (int column = 0; column < 3; column++)
{
for (int row = 0; row < 9; row++)
{
this.addSlotToContainer(new Slot(inventoryplayer, row + column * 9 + 9, 8 + row * 18, 84 + column * 18));
}
}
for (int column = 0; column < 9; column++)
{
this.addSlotToContainer(new Slot(inventoryplayer, column, 8 + column * 18, 142));
}
}
@Override
public boolean canInteractWith (EntityPlayer var1)
{
return true;
}
@Override
public ItemStack transferStackInSlot (EntityPlayer player, int slotID)
{
return null;
}
}