rename storage proxy to external storage

This commit is contained in:
Raoul Van den Berge
2015-12-23 15:32:38 +01:00
parent 6d8321f2ce
commit 7574747c46
12 changed files with 70 additions and 70 deletions

View File

@@ -21,7 +21,7 @@ public class StorageCraft
public static final int CONTROLLER = 0; public static final int CONTROLLER = 0;
public static final int GRID = 1; public static final int GRID = 1;
public static final int DRIVE = 2; public static final int DRIVE = 2;
public static final int STORAGE_PROXY = 3; public static final int EXTERNAL_STORAGE = 3;
public static final int IMPORTER = 4; public static final int IMPORTER = 4;
public static final int EXPORTER = 5; public static final int EXPORTER = 5;
public static final int DETECTOR = 6; public static final int DETECTOR = 6;

View File

@@ -9,7 +9,7 @@ import storagecraft.block.BlockGrid;
import storagecraft.block.BlockImporter; import storagecraft.block.BlockImporter;
import storagecraft.block.BlockMachineCasing; import storagecraft.block.BlockMachineCasing;
import storagecraft.block.BlockSolderer; import storagecraft.block.BlockSolderer;
import storagecraft.block.BlockStorageProxy; import storagecraft.block.BlockExternalStorage;
public class StorageCraftBlocks public class StorageCraftBlocks
{ {
@@ -17,7 +17,7 @@ public class StorageCraftBlocks
public static final BlockCable CABLE = new BlockCable(); public static final BlockCable CABLE = new BlockCable();
public static final BlockGrid GRID = new BlockGrid(); public static final BlockGrid GRID = new BlockGrid();
public static final BlockDrive DRIVE = new BlockDrive(); public static final BlockDrive DRIVE = new BlockDrive();
public static final BlockStorageProxy STORAGE_PROXY = new BlockStorageProxy(); public static final BlockExternalStorage EXTERNAL_STORAGE = new BlockExternalStorage();
public static final BlockImporter IMPORTER = new BlockImporter(); public static final BlockImporter IMPORTER = new BlockImporter();
public static final BlockExporter EXPORTER = new BlockExporter(); public static final BlockExporter EXPORTER = new BlockExporter();
public static final BlockDetector DETECTOR = new BlockDetector(); public static final BlockDetector DETECTOR = new BlockDetector();

View File

@@ -8,22 +8,22 @@ import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess; import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World; import net.minecraft.world.World;
import storagecraft.StorageCraft; import storagecraft.StorageCraft;
import storagecraft.tile.TileStorageProxy; import storagecraft.tile.TileExternalStorage;
public class BlockStorageProxy extends BlockBase implements ITileEntityProvider public class BlockExternalStorage extends BlockBase implements ITileEntityProvider
{ {
private IIcon frontIcon; private IIcon frontIcon;
private IIcon sideIcon; private IIcon sideIcon;
public BlockStorageProxy() public BlockExternalStorage()
{ {
super("storageProxy"); super("externalStorage");
} }
@Override @Override
public TileEntity createNewTileEntity(World world, int meta) public TileEntity createNewTileEntity(World world, int meta)
{ {
return new TileStorageProxy(); return new TileExternalStorage();
} }
@Override @Override
@@ -31,7 +31,7 @@ public class BlockStorageProxy extends BlockBase implements ITileEntityProvider
{ {
if (!world.isRemote) if (!world.isRemote)
{ {
player.openGui(StorageCraft.INSTANCE, StorageCraft.GUI.STORAGE_PROXY, world, x, y, z); player.openGui(StorageCraft.INSTANCE, StorageCraft.GUI.EXTERNAL_STORAGE, world, x, y, z);
} }
return true; return true;
@@ -40,14 +40,14 @@ public class BlockStorageProxy extends BlockBase implements ITileEntityProvider
@Override @Override
public void registerBlockIcons(IIconRegister register) public void registerBlockIcons(IIconRegister register)
{ {
frontIcon = register.registerIcon("storagecraft:storageProxy"); frontIcon = register.registerIcon("storagecraft:externalStorage");
sideIcon = register.registerIcon("storagecraft:generic"); sideIcon = register.registerIcon("storagecraft:generic");
} }
@Override @Override
public IIcon getIcon(IBlockAccess world, int x, int y, int z, int side) public IIcon getIcon(IBlockAccess world, int x, int y, int z, int side)
{ {
TileStorageProxy tile = (TileStorageProxy) world.getTileEntity(x, y, z); TileExternalStorage tile = (TileExternalStorage) world.getTileEntity(x, y, z);
if (side == tile.getDirection().ordinal()) if (side == tile.getDirection().ordinal())
{ {

View File

@@ -2,9 +2,9 @@ package storagecraft.container;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
public class ContainerStorageProxy extends ContainerBase public class ContainerExternalStorage extends ContainerBase
{ {
public ContainerStorageProxy(EntityPlayer player) public ContainerExternalStorage(EntityPlayer player)
{ {
super(player); super(player);

View File

@@ -0,0 +1,43 @@
package storagecraft.gui;
import storagecraft.container.ContainerExternalStorage;
import storagecraft.gui.sidebutton.SideButtonRedstoneMode;
import storagecraft.tile.TileExternalStorage;
public class GuiExternalStorage extends GuiBase
{
private TileExternalStorage externalStorage;
public GuiExternalStorage(ContainerExternalStorage container, TileExternalStorage externalStorage)
{
super(container, 176, 131);
this.externalStorage = externalStorage;
}
@Override
public void init(int x, int y)
{
addSideButton(new SideButtonRedstoneMode(externalStorage));
}
@Override
public void update(int x, int y)
{
}
@Override
public void drawBackground(int x, int y, int mouseX, int mouseY)
{
bindTexture("gui/externalStorage.png");
drawTexturedModalRect(x, y, 0, 0, xSize, ySize);
}
@Override
public void drawForeground(int mouseX, int mouseY)
{
drawString(7, 7, t("gui.storagecraft:externalStorage"));
drawString(7, 39, t("container.inventory"));
}
}

View File

@@ -13,7 +13,7 @@ import storagecraft.container.ContainerExporter;
import storagecraft.container.ContainerGrid; import storagecraft.container.ContainerGrid;
import storagecraft.container.ContainerImporter; import storagecraft.container.ContainerImporter;
import storagecraft.container.ContainerSolderer; import storagecraft.container.ContainerSolderer;
import storagecraft.container.ContainerStorageProxy; import storagecraft.container.ContainerExternalStorage;
import storagecraft.tile.TileController; import storagecraft.tile.TileController;
import storagecraft.tile.TileDetector; import storagecraft.tile.TileDetector;
import storagecraft.tile.TileDrive; import storagecraft.tile.TileDrive;
@@ -21,7 +21,7 @@ import storagecraft.tile.TileExporter;
import storagecraft.tile.TileGrid; import storagecraft.tile.TileGrid;
import storagecraft.tile.TileImporter; import storagecraft.tile.TileImporter;
import storagecraft.tile.TileSolderer; import storagecraft.tile.TileSolderer;
import storagecraft.tile.TileStorageProxy; import storagecraft.tile.TileExternalStorage;
public class GuiHandler implements IGuiHandler public class GuiHandler implements IGuiHandler
{ {
@@ -35,8 +35,8 @@ public class GuiHandler implements IGuiHandler
return new ContainerGrid(player, (TileGrid) tile); return new ContainerGrid(player, (TileGrid) tile);
case StorageCraft.GUI.DRIVE: case StorageCraft.GUI.DRIVE:
return new ContainerDrive(player, (TileDrive) tile); return new ContainerDrive(player, (TileDrive) tile);
case StorageCraft.GUI.STORAGE_PROXY: case StorageCraft.GUI.EXTERNAL_STORAGE:
return new ContainerStorageProxy(player); return new ContainerExternalStorage(player);
case StorageCraft.GUI.IMPORTER: case StorageCraft.GUI.IMPORTER:
return new ContainerImporter(player, (TileImporter) tile); return new ContainerImporter(player, (TileImporter) tile);
case StorageCraft.GUI.EXPORTER: case StorageCraft.GUI.EXPORTER:
@@ -69,8 +69,8 @@ public class GuiHandler implements IGuiHandler
return new GuiGrid((ContainerGrid) getContainer(ID, player, tile), (TileGrid) tile); return new GuiGrid((ContainerGrid) getContainer(ID, player, tile), (TileGrid) tile);
case StorageCraft.GUI.DRIVE: case StorageCraft.GUI.DRIVE:
return new GuiDrive((ContainerDrive) getContainer(ID, player, tile), (TileDrive) tile); return new GuiDrive((ContainerDrive) getContainer(ID, player, tile), (TileDrive) tile);
case StorageCraft.GUI.STORAGE_PROXY: case StorageCraft.GUI.EXTERNAL_STORAGE:
return new GuiStorageProxy((ContainerStorageProxy) getContainer(ID, player, tile), (TileStorageProxy) tile); return new GuiExternalStorage((ContainerExternalStorage) getContainer(ID, player, tile), (TileExternalStorage) tile);
case StorageCraft.GUI.IMPORTER: case StorageCraft.GUI.IMPORTER:
return new GuiImporter((ContainerImporter) getContainer(ID, player, tile), (TileImporter) tile); return new GuiImporter((ContainerImporter) getContainer(ID, player, tile), (TileImporter) tile);
case StorageCraft.GUI.EXPORTER: case StorageCraft.GUI.EXPORTER:

View File

@@ -1,43 +0,0 @@
package storagecraft.gui;
import storagecraft.container.ContainerStorageProxy;
import storagecraft.gui.sidebutton.SideButtonRedstoneMode;
import storagecraft.tile.TileStorageProxy;
public class GuiStorageProxy extends GuiBase
{
private TileStorageProxy storageProxy;
public GuiStorageProxy(ContainerStorageProxy container, TileStorageProxy storageProxy)
{
super(container, 176, 131);
this.storageProxy = storageProxy;
}
@Override
public void init(int x, int y)
{
addSideButton(new SideButtonRedstoneMode(storageProxy));
}
@Override
public void update(int x, int y)
{
}
@Override
public void drawBackground(int x, int y, int mouseX, int mouseY)
{
bindTexture("gui/storageProxy.png");
drawTexturedModalRect(x, y, 0, 0, xSize, ySize);
}
@Override
public void drawForeground(int mouseX, int mouseY)
{
drawString(7, 7, t("gui.storagecraft:storageProxy"));
drawString(7, 39, t("container.inventory"));
}
}

View File

@@ -37,7 +37,7 @@ import storagecraft.tile.TileExporter;
import storagecraft.tile.TileGrid; import storagecraft.tile.TileGrid;
import storagecraft.tile.TileImporter; import storagecraft.tile.TileImporter;
import storagecraft.tile.TileSolderer; import storagecraft.tile.TileSolderer;
import storagecraft.tile.TileStorageProxy; import storagecraft.tile.TileExternalStorage;
import storagecraft.tile.solderer.SoldererRecipeCraftingGrid; import storagecraft.tile.solderer.SoldererRecipeCraftingGrid;
import storagecraft.tile.solderer.SoldererRecipeDrive; import storagecraft.tile.solderer.SoldererRecipeDrive;
import storagecraft.tile.solderer.SoldererRecipePrintedProcessor; import storagecraft.tile.solderer.SoldererRecipePrintedProcessor;
@@ -65,7 +65,7 @@ public class CommonProxy
GameRegistry.registerTileEntity(TileCable.class, "cable"); GameRegistry.registerTileEntity(TileCable.class, "cable");
GameRegistry.registerTileEntity(TileGrid.class, "grid"); GameRegistry.registerTileEntity(TileGrid.class, "grid");
GameRegistry.registerTileEntity(TileDrive.class, "drive"); GameRegistry.registerTileEntity(TileDrive.class, "drive");
GameRegistry.registerTileEntity(TileStorageProxy.class, "storageProxy"); GameRegistry.registerTileEntity(TileExternalStorage.class, "externalStorage");
GameRegistry.registerTileEntity(TileImporter.class, "importer"); GameRegistry.registerTileEntity(TileImporter.class, "importer");
GameRegistry.registerTileEntity(TileExporter.class, "exporter"); GameRegistry.registerTileEntity(TileExporter.class, "exporter");
GameRegistry.registerTileEntity(TileDetector.class, "detector"); GameRegistry.registerTileEntity(TileDetector.class, "detector");
@@ -75,7 +75,7 @@ public class CommonProxy
GameRegistry.registerBlock(StorageCraftBlocks.CABLE, ItemBlockCable.class, "cable"); GameRegistry.registerBlock(StorageCraftBlocks.CABLE, ItemBlockCable.class, "cable");
GameRegistry.registerBlock(StorageCraftBlocks.GRID, ItemBlockGrid.class, "grid"); GameRegistry.registerBlock(StorageCraftBlocks.GRID, ItemBlockGrid.class, "grid");
GameRegistry.registerBlock(StorageCraftBlocks.DRIVE, "drive"); GameRegistry.registerBlock(StorageCraftBlocks.DRIVE, "drive");
GameRegistry.registerBlock(StorageCraftBlocks.STORAGE_PROXY, "storageProxy"); GameRegistry.registerBlock(StorageCraftBlocks.EXTERNAL_STORAGE, "externalStorage");
GameRegistry.registerBlock(StorageCraftBlocks.IMPORTER, "importer"); GameRegistry.registerBlock(StorageCraftBlocks.IMPORTER, "importer");
GameRegistry.registerBlock(StorageCraftBlocks.EXPORTER, "exporter"); GameRegistry.registerBlock(StorageCraftBlocks.EXPORTER, "exporter");
GameRegistry.registerBlock(StorageCraftBlocks.DETECTOR, "detector"); GameRegistry.registerBlock(StorageCraftBlocks.DETECTOR, "detector");
@@ -198,8 +198,8 @@ public class CommonProxy
'A', new ItemStack(StorageCraftItems.PROCESSOR, 1, ItemProcessor.TYPE_ADVANCED) 'A', new ItemStack(StorageCraftItems.PROCESSOR, 1, ItemProcessor.TYPE_ADVANCED)
); );
// Storage Proxy // External Storage
GameRegistry.addRecipe(new ItemStack(StorageCraftBlocks.STORAGE_PROXY), GameRegistry.addRecipe(new ItemStack(StorageCraftBlocks.EXTERNAL_STORAGE),
"CED", "CED",
"HMH", "HMH",
"EPE", "EPE",

View File

@@ -9,7 +9,7 @@ import storagecraft.storage.IStorageProvider;
import storagecraft.storage.StorageItem; import storagecraft.storage.StorageItem;
import storagecraft.util.InventoryUtils; import storagecraft.util.InventoryUtils;
public class TileStorageProxy extends TileMachine implements IStorageProvider, IStorage public class TileExternalStorage extends TileMachine implements IStorageProvider, IStorage
{ {
public IInventory getInventory() public IInventory getInventory()
{ {

View File

@@ -3,7 +3,7 @@ itemGroup.storagecraft=StorageCraft
gui.storagecraft:controller=Controller gui.storagecraft:controller=Controller
gui.storagecraft:grid=Grid gui.storagecraft:grid=Grid
gui.storagecraft:drive=Drive gui.storagecraft:drive=Drive
gui.storagecraft:storageProxy=Storage Proxy gui.storagecraft:externalStorage=External Storage
gui.storagecraft:importer=Importer gui.storagecraft:importer=Importer
gui.storagecraft:exporter=Exporter gui.storagecraft:exporter=Exporter
gui.storagecraft:detector=Detector gui.storagecraft:detector=Detector
@@ -56,7 +56,7 @@ block.storagecraft:cable.1.name=Sensitive Cable
block.storagecraft:grid.0.name=Grid block.storagecraft:grid.0.name=Grid
block.storagecraft:grid.1.name=Crafting Grid block.storagecraft:grid.1.name=Crafting Grid
block.storagecraft:drive.name=Drive block.storagecraft:drive.name=Drive
block.storagecraft:storageProxy.name=Storage Proxy block.storagecraft:externalStorage.name=External Storage
block.storagecraft:importer.name=Importer block.storagecraft:importer.name=Importer
block.storagecraft:exporter.name=Exporter block.storagecraft:exporter.name=Exporter
block.storagecraft:detector.name=Detector block.storagecraft:detector.name=Detector

View File

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB