Added lava and water cells
This commit is contained in:
parent
ed3d3c78b5
commit
a8cf7fbb87
3 changed files with 15 additions and 5 deletions
|
@ -1551,8 +1551,9 @@ public class
|
||||||
//CentrifugeRecipes
|
//CentrifugeRecipes
|
||||||
|
|
||||||
//Plantball/Bio Chaff
|
//Plantball/Bio Chaff
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.grass, 16), null, new ItemStack(TechRebornAPI.recipeCompact.getItem("biochaff").getItem(), 8), new ItemStack(TechRebornAPI.recipeCompact.getItem("plantBall").getItem(), 8), new ItemStack(Items.clay_ball), new ItemStack(Blocks.sand, 8), 2500, 5));
|
//FIX with ic2
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.dirt, 16), null, new ItemStack(TechRebornAPI.recipeCompact.getItem("biochaff").getItem(), 4), new ItemStack(TechRebornAPI.recipeCompact.getItem("plantBall").getItem(), 4), new ItemStack(Items.clay_ball), new ItemStack(Blocks.sand, 8), 2500, 5));
|
// RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.grass, 16), null, new ItemStack(TechRebornAPI.recipeCompact.getItem("biochaff").getItem(), 8), new ItemStack(TechRebornAPI.recipeCompact.getItem("plantBall").getItem(), 8), new ItemStack(Items.clay_ball), new ItemStack(Blocks.sand, 8), 2500, 5));
|
||||||
|
// RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.dirt, 16), null, new ItemStack(TechRebornAPI.recipeCompact.getItem("biochaff").getItem(), 4), new ItemStack(TechRebornAPI.recipeCompact.getItem("plantBall").getItem(), 4), new ItemStack(Items.clay_ball), new ItemStack(Blocks.sand, 8), 2500, 5));
|
||||||
|
|
||||||
|
|
||||||
//Methane
|
//Methane
|
||||||
|
@ -1580,7 +1581,8 @@ public class
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Items.potato, 16), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Items.potato, 16), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Items.poisonous_potato, 12), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Items.poisonous_potato, 12), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Items.nether_wart, 1), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Items.nether_wart, 1), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(TechRebornAPI.recipeCompact.getItem("terraWart").getItem(), 16), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
//Fix with ic2
|
||||||
|
//RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(TechRebornAPI.recipeCompact.getItem("terraWart").getItem(), 16), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.brown_mushroom, 1), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.brown_mushroom, 1), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
||||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.red_mushroom, 1), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Blocks.red_mushroom, 1), TechRebornAPI.recipeCompact.getItem("cell"), ItemCells.getCellByName("methane", 1), null, null, null, 5000, 5));
|
||||||
|
|
||||||
|
|
|
@ -52,6 +52,8 @@ public class RecipeCompact implements IRecipeCompact {
|
||||||
recipes.put("diamondDrill", new ItemStack(ModItems.diamondDrill));
|
recipes.put("diamondDrill", new ItemStack(ModItems.diamondDrill));
|
||||||
recipes.put("miningDrill", new ItemStack(ModItems.ironDrill));
|
recipes.put("miningDrill", new ItemStack(ModItems.ironDrill));
|
||||||
recipes.put("solarPanel", new ItemStack(ModBlocks.solarPanel));
|
recipes.put("solarPanel", new ItemStack(ModBlocks.solarPanel));
|
||||||
|
recipes.put("waterCell", ItemCells.getCellByName("water"));
|
||||||
|
recipes.put("lavaCell", ItemCells.getCellByName("lava"));
|
||||||
inited = false;
|
inited = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -57,7 +57,7 @@ public class ItemCells extends ItemTextureBase implements IFluidContainerItem {
|
||||||
"mercury", "methane", "nitrocarbon", "nitroCoalfuel",
|
"mercury", "methane", "nitrocarbon", "nitroCoalfuel",
|
||||||
"nitroDiesel", "nitrogen", "nitrogenDioxide", "oil", "potassium",
|
"nitroDiesel", "nitrogen", "nitrogenDioxide", "oil", "potassium",
|
||||||
"seedOil", "silicon", "sodium", "sodiumPersulfate",
|
"seedOil", "silicon", "sodium", "sodiumPersulfate",
|
||||||
"sodiumSulfide", "sulfur", "sulfuricAcid", "tritium", "wolframium", "empty"};
|
"sodiumSulfide", "sulfur", "sulfuricAcid", "tritium", "wolframium", "empty", "lava", "water"};
|
||||||
|
|
||||||
|
|
||||||
public ItemCells() {
|
public ItemCells() {
|
||||||
|
@ -82,7 +82,9 @@ public class ItemCells extends ItemTextureBase implements IFluidContainerItem {
|
||||||
public void getSubItems(Item item, CreativeTabs creativeTabs, List list) {
|
public void getSubItems(Item item, CreativeTabs creativeTabs, List list) {
|
||||||
for (int meta = 0; meta < types.length; ++meta) {
|
for (int meta = 0; meta < types.length; ++meta) {
|
||||||
ItemStack stack = new ItemStack(item, 1, meta);
|
ItemStack stack = new ItemStack(item, 1, meta);
|
||||||
if(FluidRegistry.getFluid("fluid" +types[meta].toLowerCase()) != null){
|
if(types[meta].toLowerCase().equals("water") || types[meta].toLowerCase().equals("lava")){
|
||||||
|
this.fill(stack, new FluidStack(FluidRegistry.getFluid(types[meta].toLowerCase()), getCapacity(stack)), true);
|
||||||
|
} else if(FluidRegistry.getFluid("fluid" +types[meta].toLowerCase()) != null){
|
||||||
this.fill(stack, new FluidStack(FluidRegistry.getFluid("fluid" +types[meta].toLowerCase()), getCapacity(stack)), true);
|
this.fill(stack, new FluidStack(FluidRegistry.getFluid("fluid" +types[meta].toLowerCase()), getCapacity(stack)), true);
|
||||||
}
|
}
|
||||||
list.add(stack);
|
list.add(stack);
|
||||||
|
@ -107,9 +109,13 @@ public class ItemCells extends ItemTextureBase implements IFluidContainerItem {
|
||||||
if (resource == null || resource.amount != getCapacity(container)) {
|
if (resource == null || resource.amount != getCapacity(container)) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
if(types[container.getItemDamage()].toLowerCase().equals("water") || types[container.getItemDamage()].toLowerCase().equals("lava")){
|
||||||
|
|
||||||
|
} else
|
||||||
if(FluidRegistry.getFluid("fluid" +types[container.getItemDamage()].toLowerCase()) == null){
|
if(FluidRegistry.getFluid("fluid" +types[container.getItemDamage()].toLowerCase()) == null){
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (doFill)
|
if (doFill)
|
||||||
{
|
{
|
||||||
NBTTagCompound tag = container.getTagCompound();
|
NBTTagCompound tag = container.getTagCompound();
|
||||||
|
|
Loading…
Reference in a new issue