Fix incorrect casts in gui code.
Caused by removed IInventory implementations.
This commit is contained in:
parent
0cd627ce0d
commit
f074c0ad6a
4 changed files with 5 additions and 5 deletions
|
@ -87,7 +87,7 @@ public class SimpleInventory implements IInventory, INBTTagable {
|
|||
|
||||
@Override
|
||||
public boolean isUseableByPlayer(EntityPlayer entityplayer) {
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
package buildcraft.transport;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.inventory.IInventory;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import buildcraft.core.GuiIds;
|
||||
|
@ -13,6 +12,7 @@ import buildcraft.transport.gui.GuiDiamondPipe;
|
|||
import buildcraft.transport.gui.GuiEmeraldPipe;
|
||||
import buildcraft.transport.gui.GuiFilteredBuffer;
|
||||
import buildcraft.transport.gui.GuiGateInterface;
|
||||
import buildcraft.transport.pipes.PipeItemsEmerald;
|
||||
import buildcraft.transport.pipes.PipeLogicDiamond;
|
||||
import cpw.mods.fml.common.network.IGuiHandler;
|
||||
|
||||
|
@ -43,7 +43,7 @@ public class GuiHandler implements IGuiHandler {
|
|||
return new ContainerDiamondPipe(player.inventory, ((PipeLogicDiamond) pipe.pipe.logic).getFilters());
|
||||
|
||||
case GuiIds.PIPE_EMERALD_ITEM:
|
||||
return new ContainerEmeraldPipe(player.inventory, (IInventory) pipe.pipe);
|
||||
return new ContainerEmeraldPipe(player.inventory, ((PipeItemsEmerald) pipe.pipe).getFilters());
|
||||
|
||||
case GuiIds.GATES:
|
||||
return new ContainerGateInterface(player.inventory, pipe.pipe);
|
||||
|
|
|
@ -23,7 +23,7 @@ public class GuiDiamondPipe extends GuiBuildCraft {
|
|||
PipeLogicDiamond filterInventory;
|
||||
|
||||
public GuiDiamondPipe(IInventory playerInventory, TileGenericPipe tile) {
|
||||
super(new ContainerDiamondPipe(playerInventory, (IInventory) tile.pipe.logic), (IInventory) tile.pipe.logic);
|
||||
super(new ContainerDiamondPipe(playerInventory, ((PipeLogicDiamond)tile.pipe.logic).getFilters()), ((PipeLogicDiamond)tile.pipe.logic).getFilters());
|
||||
this.playerInventory = playerInventory;
|
||||
this.filterInventory = (PipeLogicDiamond) tile.pipe.logic;
|
||||
xSize = 175;
|
||||
|
|
|
@ -23,7 +23,7 @@ public class GuiEmeraldPipe extends GuiBuildCraft {
|
|||
PipeItemsEmerald filterInventory;
|
||||
|
||||
public GuiEmeraldPipe(IInventory playerInventory, TileGenericPipe tile) {
|
||||
super(new ContainerEmeraldPipe(playerInventory, (IInventory) tile.pipe), (IInventory) tile.pipe);
|
||||
super(new ContainerEmeraldPipe(playerInventory, ((PipeItemsEmerald) tile.pipe).getFilters()), ((PipeItemsEmerald) tile.pipe).getFilters());
|
||||
this.playerInventory = playerInventory;
|
||||
this.filterInventory = (PipeItemsEmerald) tile.pipe;
|
||||
xSize = 175;
|
||||
|
|
Loading…
Reference in a new issue