if(ID==Lib.GUIID_Refinery && te instanceof TileEntityRefinery)
gui = new GuiRefinery(player.inventory, (TileEntityRefinery) te);
if(ID==Lib.GUIID_ArcFurnace && te instanceof TileEntityArcFurnace)
gui = new GuiArcFurnace(player.inventory, (TileEntityArcFurnace) te);
if(ID==Lib.GUIID_Assembler && te instanceof TileEntityAssembler)
<BUG>gui = new GuiAssembler(player.inventory, (TileEntityAssembler) te);
if(gui!=null)</BUG>
((IGuiTile)te).onGuiOpened(player, true);
return gui;
}

if(ID==Lib.GUIID_Refinery && te instanceof TileEntityRefinery)
gui = new GuiRefinery(player.inventory, (TileEntityRefinery) te);
if(ID==Lib.GUIID_ArcFurnace && te instanceof TileEntityArcFurnace)
gui = new GuiArcFurnace(player.inventory, (TileEntityArcFurnace) te);
if(ID==Lib.GUIID_Assembler && te instanceof TileEntityAssembler)
gui = new GuiAssembler(player.inventory, (TileEntityAssembler) te);
if(ID==Lib.GUIID_AutoWorkbench && te instanceof TileEntityAutoWorkbench)
gui = new GuiAutoWorkbench(player.inventory, (TileEntityAutoWorkbench) te);
if(gui!=null)
((IGuiTile)te).onGuiOpened(player, true);
return gui;
