parent
03752e43d9
commit
031035bd7d
1 changed files with 29 additions and 27 deletions
|
@ -6,7 +6,6 @@
|
|||
* License 1.0, or MMPL. Please check the contents of the license located in
|
||||
* http://www.mod-buildcraft.com/MMPL-1.0.txt
|
||||
*/
|
||||
|
||||
package net.minecraft.src.buildcraft.factory;
|
||||
|
||||
import net.minecraft.src.EntityPlayer;
|
||||
|
@ -35,8 +34,9 @@ public class ContainerRefinery extends BuildCraftContainer {
|
|||
}
|
||||
}
|
||||
|
||||
for (int i1 = 0; i1 < 9; i1++)
|
||||
for (int i1 = 0; i1 < 9; i1++) {
|
||||
addSlot(new Slot(inventory, i1, 8 + i1 * 18, 181));
|
||||
}
|
||||
|
||||
this.refinery = refinery;
|
||||
}
|
||||
|
@ -50,18 +50,20 @@ public class ContainerRefinery extends BuildCraftContainer {
|
|||
/**
|
||||
* @param slot
|
||||
* @ param liquidId
|
||||
* @param liquidMeta (for future use)
|
||||
param liquidMeta (for future use)
|
||||
*/
|
||||
public void setFilter(int slot, int liquidId, int liquidMeta) {
|
||||
|
||||
refinery.setFilter(slot, liquidId);
|
||||
|
||||
if (APIProxy.isRemote()) {
|
||||
PacketPayload payload = new PacketPayload(3, 0, 0);
|
||||
payload.intPayload[0] = slot;
|
||||
payload.intPayload[1] = liquidId;
|
||||
payload.intPayload[2] = liquidMeta;
|
||||
CoreProxy.sendToServer(new PacketUpdate(PacketIds.REFINERY_FILTER_SET, refinery.xCoord, refinery.yCoord, refinery.zCoord, payload).getPacket());
|
||||
}
|
||||
}
|
||||
|
||||
public ItemStack getFilter(int slot) {
|
||||
int liquidId = refinery.getFilter(slot);
|
||||
|
@ -80,8 +82,8 @@ public class ContainerRefinery extends BuildCraftContainer {
|
|||
@Override
|
||||
public void updateCraftingResults() {
|
||||
super.updateCraftingResults();
|
||||
for(int i = 0; i < crafters.size(); i++)
|
||||
for (int i = 0; i < crafters.size(); i++) {
|
||||
refinery.sendGUINetworkData(this, (ICrafting) crafters.get(i));
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue