mirror of
https://github.com/GTNewHorizons/AE2FluidCraft-Rework.git
synced 2026-11-17 02:45:08 +00:00
ec2 style output rule and oc integration
This commit is contained in:
1 parent
19f9dee682
commit
e38869f07d
20 files changed
+503
-25
No files matched your search
@@ -168,7 +168,7 @@ public class TileFluidInterface extends TileInterface implements IFluidHandler,
|
||||
|
||||
@Override
|
||||
public FluidStack drain(ForgeDirection from, int maxDrain, boolean doDrain) {
|
||||
return invFluids.drain(from, maxDrain, doDrain);
|
||||
return invFluids.drain(from.ordinal(), maxDrain, doDrain);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -43,10 +43,6 @@ public class TileFluidPatternEncoder extends AEBaseTile implements IAEAppEngInve
|
||||
|
||||
@Override
|
||||
public void getDrops(final World w, final int x, final int y, final int z, final List<ItemStack> drops ) {
|
||||
getDrops(w, new BlockPos(x, y, z), drops);
|
||||
}
|
||||
|
||||
public void getDrops(World world, BlockPos pos, List<ItemStack> drops) {
|
||||
for (ItemStack stack : patternInv) {
|
||||
if (stack != null) {
|
||||
drops.add(stack);
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
package com.glodblock.github.common.tile;
|
||||
|
||||
import appeng.items.misc.ItemEncodedPattern;
|
||||
import appeng.tile.AEBaseInvTile;
|
||||
import appeng.tile.inventory.AppEngInternalInventory;
|
||||
import appeng.tile.inventory.InvOperation;
|
||||
import net.minecraft.inventory.IInventory;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
public class TileOCPatternEditor extends AEBaseInvTile {
|
||||
|
||||
private final AppEngInternalInventory invItems = new AppEngInternalInventory(this, 16);
|
||||
|
||||
@Override
|
||||
public IInventory getInternalInventory() {
|
||||
return invItems;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onChangeInventory(IInventory inv, int slot, InvOperation mc, ItemStack removed, ItemStack added) {
|
||||
markForUpdate();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int[] getAccessibleSlotsBySide(ForgeDirection whichSide) {
|
||||
return new int[]{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15};
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isItemValidForSlot( final int i, final ItemStack itemstack ) {
|
||||
return itemstack == null || itemstack.getItem() instanceof ItemEncodedPattern;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user