This commit is contained in:
Aidan Brady 2014-08-01 22:28:18 -04:00
commit 8f6cf7e1c9
3 changed files with 62 additions and 0 deletions

View file

@ -0,0 +1,26 @@
package mekanism.common.teleportation;
import mekanism.api.gas.GasTank;
import net.minecraft.item.ItemStack;
import net.minecraftforge.fluids.FluidTank;
public class SharedInventory
{
public String name;
public double storedEnergy;
public FluidTank storedFluid;
public GasTank storedGas;
public ItemStack storedItem;
public SharedInventory(String freq)
{
name = freq;
storedEnergy = 0;
storedFluid = new FluidTank(1000);
storedGas = new GasTank(1000);
storedItem = null;
}
}

View file

@ -0,0 +1,27 @@
package mekanism.common.teleportation;
import java.util.HashMap;
public class SharedInventoryManager
{
public static HashMap<String, SharedInventory> inventories = new HashMap<String, SharedInventory>();
public static SharedInventory getInventory(String frequency)
{
if(frequency.length() <= 0)
{
return null;
}
SharedInventory inv = inventories.get(frequency);
if(inv == null)
{
inv = new SharedInventory(frequency);
inventories.put(frequency, inv);
}
return inv;
}
}

View file

@ -0,0 +1,9 @@
package mekanism.common.tile;
public class TileEntityEntangledInventory extends TileEntityElectricBlock
{
public TileEntityEntangledInventory()
{
super("Entangled", 0);
}
}