mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
Merge remote-tracking branch 'HbmMods/master'
This commit is contained in:
commit
78445883bb
@ -76,19 +76,4 @@ public class MachineSolidifier extends BlockDummyable implements ITooltipProvide
|
||||
EnumChatFormatting.DARK_GRAY + "" + EnumChatFormatting.ITALIC + "> to display more info");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getRenderType() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isOpaqueCube() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean renderAsNormalBlock() {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@ -34,7 +34,7 @@ public class WeaponConfig {
|
||||
|
||||
final String CATEGORY_DROPS = "10_dangerous_drops";
|
||||
dropCell = CommonConfig.createConfigBool(config, CATEGORY_DROPS, "10.00_dropCell", "Whether antimatter cells should explode when dropped", true);
|
||||
dropSing = CommonConfig.createConfigBool(config, CATEGORY_DROPS, "10.01_dropBHole", "Whether singularities and blaack holes should spawn when dropped", true);
|
||||
dropSing = CommonConfig.createConfigBool(config, CATEGORY_DROPS, "10.01_dropBHole", "Whether singularities and black holes should spawn when dropped", true);
|
||||
dropStar = CommonConfig.createConfigBool(config, CATEGORY_DROPS, "10.02_dropStar", "Whether rigged star blaster cells should explode when dropped", true);
|
||||
dropCrys = CommonConfig.createConfigBool(config, CATEGORY_DROPS, "10.04_dropCrys", "Whether xen crystals should move blocks when dropped", true);
|
||||
dropDead = CommonConfig.createConfigBool(config, CATEGORY_DROPS, "10.05_dropDead", "Whether dead man's explosives should explode when dropped", true);
|
||||
|
||||
@ -145,7 +145,7 @@ public class WorldConfig {
|
||||
geyserVapor = CommonConfig.createConfigInt(config, CATEGORY_DUNGEON, "4.19_geyserVaporSpawn", "Spawn vapor geyser on every nTH chunk", 500);
|
||||
meteorStructure = CommonConfig.createConfigInt(config, CATEGORY_DUNGEON, "4.20_meteorSpawn", "Spawn meteor dungeon on every nTH chunk", 15000);
|
||||
capsuleStructure = CommonConfig.createConfigInt(config, CATEGORY_DUNGEON, "4.21_capsuleSpawn", "Spawn landing capsule on every nTH chunk", 100);
|
||||
arcticStructure = CommonConfig.createConfigInt(config, CATEGORY_DUNGEON, "4.22_arcticVaultSpawn", "Spawn artic code vault on every nTH chunk", 500);
|
||||
arcticStructure = CommonConfig.createConfigInt(config, CATEGORY_DUNGEON, "4.22_arcticVaultSpawn", "Spawn arctic code vault on every nTH chunk", 500);
|
||||
jungleStructure = CommonConfig.createConfigInt(config, CATEGORY_DUNGEON, "4.23_jungleDungeonSpawn", "Spawn jungle dungeon on every nTH chunk", 2000);
|
||||
pyramidStructure = CommonConfig.createConfigInt(config, CATEGORY_DUNGEON, "4.24_pyramidSpawn", "Spawn pyramid on every nTH chunk", 4000);
|
||||
|
||||
|
||||
@ -98,8 +98,9 @@ public class SmeltingRecipes {
|
||||
|
||||
GameRegistry.addSmelting(ModItems.powder_coal, DictFrame.fromOne(ModItems.coke, EnumCokeType.COAL), 1.0F);
|
||||
GameRegistry.addSmelting(ModItems.briquette_lignite, DictFrame.fromOne(ModItems.coke, EnumCokeType.LIGNITE), 1.0F);
|
||||
GameRegistry.addSmelting(DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRUDE), new ItemStack(ModItems.powder_coal), 1.0F);
|
||||
GameRegistry.addSmelting(DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRACK), new ItemStack(ModItems.powder_coal), 1.0F);
|
||||
|
||||
GameRegistry.addSmelting(DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRACK), DictFrame.fromOne(ModItems.coke, EnumCokeType.PETROLEUM), 1.0F);
|
||||
GameRegistry.addSmelting(DictFrame.fromOne(ModItems.oil_tar, EnumTarType.COAL), DictFrame.fromOne(ModItems.coke, EnumCokeType.COAL), 1.0F);
|
||||
|
||||
GameRegistry.addSmelting(ModItems.combine_scrap, new ItemStack(ModItems.ingot_combine_steel), 1.0F);
|
||||
GameRegistry.addSmelting(ModItems.tank_waste, new ItemStack(ModItems.tank_waste), 0.0F);
|
||||
|
||||
@ -878,6 +878,9 @@ public class GUIHandler implements IGuiHandler {
|
||||
if(entity instanceof TileEntityMachineLiquefactor) {
|
||||
return new GUILiquefactor(player.inventory, (TileEntityMachineLiquefactor) entity);
|
||||
}
|
||||
if(entity instanceof TileEntityMachineSolidifier) {
|
||||
return new GUISolidifier(player.inventory, (TileEntityMachineSolidifier) entity);
|
||||
}
|
||||
|
||||
if(entity instanceof TileEntityMachineRadiolysis) {
|
||||
return new GUIRadiolysis(player.inventory, (TileEntityMachineRadiolysis) entity);
|
||||
|
||||
@ -186,14 +186,14 @@ public class FluidTank {
|
||||
return;
|
||||
}
|
||||
|
||||
if(slots[in].getItem() == ModItems.inf_water && this.type.getName().equals(Fluids.WATER.name())) {
|
||||
if(slots[in].getItem() == ModItems.inf_water && type == Fluids.WATER) {
|
||||
this.fluid -= 50;
|
||||
if(this.fluid < 0)
|
||||
this.fluid = 0;
|
||||
return;
|
||||
}
|
||||
|
||||
if(slots[in].getItem() == ModItems.inf_water_mk2 && this.type.getName().equals(Fluids.WATER.name())) {
|
||||
if(slots[in].getItem() == ModItems.inf_water_mk2 && type == Fluids.WATER) {
|
||||
this.fluid -= 500;
|
||||
if(this.fluid < 0)
|
||||
this.fluid = 0;
|
||||
@ -221,27 +221,32 @@ public class FluidTank {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void setType(int in, ItemStack[] slots) {
|
||||
setType(in, in, slots);
|
||||
}
|
||||
|
||||
//Changes tank type
|
||||
public void setType(int in, int out, ItemStack[] slots) {
|
||||
|
||||
if(in == out && slots[in] != null && slots[in].getItem() instanceof ItemFluidIdentifier) {
|
||||
FluidType newType = ItemFluidIdentifier.getType(slots[in]);
|
||||
if(slots[in] != null && slots[in].getItem() instanceof ItemFluidIdentifier) {
|
||||
|
||||
if(type != newType) {
|
||||
type = newType;
|
||||
fluid = 0;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if(slots[in] != null && slots[out] == null && slots[in].getItem() instanceof ItemFluidIdentifier) {
|
||||
FluidType newType = ItemFluidIdentifier.getType(slots[in]);
|
||||
if(!type.getName().equals(newType.getName())) {
|
||||
type = newType;
|
||||
slots[out] = slots[in].copy();
|
||||
slots[in] = null;
|
||||
fluid = 0;
|
||||
if(in == out) {
|
||||
FluidType newType = ItemFluidIdentifier.getType(slots[in]);
|
||||
|
||||
if(type != newType) {
|
||||
type = newType;
|
||||
fluid = 0;
|
||||
}
|
||||
|
||||
} else if(slots[out] == null) {
|
||||
FluidType newType = ItemFluidIdentifier.getType(slots[in]);
|
||||
if(type != newType) {
|
||||
type = newType;
|
||||
slots[out] = slots[in].copy();
|
||||
slots[in] = null;
|
||||
fluid = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -61,6 +61,7 @@ public class OreDictManager {
|
||||
|
||||
public static final String KEY_OIL_TAR = "oiltar";
|
||||
public static final String KEY_CRACK_TAR = "cracktar";
|
||||
public static final String KEY_COAL_TAR = "coaltar";
|
||||
|
||||
/*
|
||||
* PREFIXES
|
||||
@ -288,7 +289,7 @@ public class OreDictManager {
|
||||
GRAPHITE .ingot(ingot_graphite) .block(block_graphite);
|
||||
DURA .ingot(ingot_dura_steel) .dust(powder_dura_steel) .block(block_dura_steel);
|
||||
POLYMER .ingot(ingot_polymer) .dust(powder_polymer);
|
||||
BAKELITE .ingot(ingot_bakelite);
|
||||
BAKELITE .ingot(ingot_bakelite) .dust(powder_bakelite);
|
||||
MAGTUNG .ingot(ingot_magnetized_tungsten) .dust(powder_magnetized_tungsten) .block(block_magnetized_tungsten);
|
||||
CMB .ingot(ingot_combine_steel) .dust(powder_combine_steel) .plate(plate_combine_steel) .block(block_combine_steel);
|
||||
DESH .nugget(nugget_desh) .ingot(ingot_desh) .dust(powder_desh) .block(block_desh);
|
||||
@ -365,15 +366,16 @@ public class OreDictManager {
|
||||
/*
|
||||
* COLLECTIONS
|
||||
*/
|
||||
ANY_PLASTIC .ingot(ingot_polymer, ingot_bakelite).dust(powder_polymer);
|
||||
ANY_PLASTIC .ingot(ingot_polymer, ingot_bakelite).dust(powder_polymer, powder_bakelite);
|
||||
ANY_GUNPOWDER .dust(Items.gunpowder, ballistite, cordite);
|
||||
ANY_SMOKELESS .dust(ballistite, cordite);
|
||||
ANY_COKE .gem(fromAll(coke, EnumCokeType.class));
|
||||
ANY_CONCRETE .any(concrete, concrete_smooth, concrete_colored, concrete_asbestos, ducrete, ducrete_smooth);
|
||||
ANY_COKE .gem(fromAll(coke, EnumCokeType.class));
|
||||
ANY_TAR .any(fromAll(oil_tar, EnumTarType.class));
|
||||
|
||||
OreDictionary.registerOre(KEY_OIL_TAR, fromOne(oil_tar, EnumTarType.CRUDE));
|
||||
OreDictionary.registerOre(KEY_CRACK_TAR, fromOne(oil_tar, EnumTarType.CRACK));
|
||||
OreDictionary.registerOre(KEY_COAL_TAR, fromOne(oil_tar, EnumTarType.COAL));
|
||||
|
||||
OreDictionary.registerOre(getReflector(), neutron_reflector);
|
||||
OreDictionary.registerOre("oreRareEarth", ore_rare);
|
||||
|
||||
@ -49,7 +49,7 @@ public class ContainerLiquefactor extends Container {
|
||||
ItemStack var5 = var4.getStack();
|
||||
var3 = var5.copy();
|
||||
|
||||
if(index <= 2) {
|
||||
if(index <= 3) {
|
||||
if(!this.mergeItemStack(var5, 4, this.inventorySlots.size(), true)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@ -51,7 +51,7 @@ public class ContainerSolidifier extends Container {
|
||||
ItemStack var5 = var4.getStack();
|
||||
var3 = var5.copy();
|
||||
|
||||
if(index <= 2) {
|
||||
if(index <= 4) {
|
||||
if(!this.mergeItemStack(var5, 5, this.inventorySlots.size(), true)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@ -20,7 +20,10 @@ public class Fluids {
|
||||
public static FluidType DEUTERIUM;
|
||||
public static FluidType TRITIUM;
|
||||
public static FluidType OIL;
|
||||
public static FluidType CRACKOIL;
|
||||
public static FluidType COALOIL;
|
||||
public static FluidType HOTOIL;
|
||||
public static FluidType HOTCRACKOIL;
|
||||
public static FluidType HEAVYOIL;
|
||||
public static FluidType BITUMEN;
|
||||
public static FluidType SMEAR;
|
||||
@ -29,12 +32,17 @@ public class Fluids {
|
||||
public static FluidType PETROIL;
|
||||
public static FluidType LUBRICANT;
|
||||
public static FluidType NAPHTHA;
|
||||
public static FluidType NAPHTHA_CRACK;
|
||||
public static FluidType DIESEL;
|
||||
public static FluidType DIESEL_CRACK;
|
||||
public static FluidType LIGHTOIL;
|
||||
public static FluidType LIGHTOIL_CRACK;
|
||||
public static FluidType KEROSENE;
|
||||
public static FluidType GAS;
|
||||
public static FluidType PETROLEUM;
|
||||
public static FluidType LPG;
|
||||
public static FluidType AROMATICS; //anything from benzene to phenol and toluene
|
||||
public static FluidType UNSATURATEDS; //collection of various basic unsaturated compounds like ethylene, acetylene and whatnot
|
||||
public static FluidType BIOGAS;
|
||||
public static FluidType BIOFUEL;
|
||||
public static FluidType NITAN;
|
||||
@ -52,10 +60,11 @@ public class Fluids {
|
||||
public static FluidType XENON;
|
||||
public static FluidType BALEFIRE;
|
||||
public static FluidType MERCURY;
|
||||
public static FluidType PAIN;
|
||||
public static FluidType PAIN; //tantalite solution
|
||||
public static FluidType WASTEFLUID;
|
||||
public static FluidType WASTEGAS;
|
||||
public static FluidType GASOLINE;
|
||||
public static FluidType GASOLINE; //gasoline, leaded
|
||||
public static FluidType COALGAS; //coal-based gasoline
|
||||
public static FluidType SPENTSTEAM;
|
||||
public static FluidType FRACKSOL;
|
||||
public static FluidType PLASMA_DT;
|
||||
@ -66,7 +75,7 @@ public class Fluids {
|
||||
public static FluidType PLASMA_BF;
|
||||
public static FluidType CARBONDIOXIDE;
|
||||
public static FluidType HELIUM3;
|
||||
public static FluidType DEATH;
|
||||
public static FluidType DEATH; //osmiridium solution
|
||||
public static FluidType ETHANOL;
|
||||
public static FluidType HEAVYWATER;
|
||||
|
||||
@ -110,6 +119,7 @@ public class Fluids {
|
||||
LUBRICANT = new FluidType("LUBRICANT",0x606060, 10, 1, 1, 2, 1, 0, EnumSymbol.NONE, "hbmfluid.lubricant");
|
||||
NAPHTHA = new FluidType("NAPHTHA",0x595744, 5, 2, 1, 2, 1, 0, EnumSymbol.NONE, "hbmfluid.naphtha");
|
||||
DIESEL = new FluidType("DIESEL",0xf2eed5, 11, 1, 1, 1, 2, 0, EnumSymbol.NONE, "hbmfluid.diesel");
|
||||
DIESEL_CRACK = new FluidType("DIESEL_CRACK",0xf2eed5, 11, 1, 1, 1, 2, 0, EnumSymbol.NONE, "hbmfluid.diesel_crack");
|
||||
LIGHTOIL = new FluidType("LIGHTOIL",0x8c7451, 6, 2, 1, 1, 2, 0, EnumSymbol.NONE, "hbmfluid.lightoil");
|
||||
KEROSENE = new FluidType("KEROSENE",0xffa5d2, 12, 1, 1, 1, 2, 0, EnumSymbol.NONE, "hbmfluid.kerosene");
|
||||
GAS = new FluidType("GAS",0xfffeed, 13, 1, 1, 1, 4, 1, EnumSymbol.NONE, "hbmfluid.gas");
|
||||
@ -136,6 +146,7 @@ public class Fluids {
|
||||
WASTEFLUID = new FluidType("WASTEFLUID",0x544400, 0, 2, 2, 2, 0, 1, EnumSymbol.RADIATION, "hbmfluid.wastefluid", FluidTrait.NO_CONTAINER);
|
||||
WASTEGAS = new FluidType("WASTEGAS",0xB8B8B8, 1, 2, 2, 2, 0, 1, EnumSymbol.RADIATION, "hbmfluid.wastegas", FluidTrait.NO_CONTAINER);
|
||||
GASOLINE = new FluidType("GASOLINE",0x445772, 2, 2, 2, 1, 2, 0, EnumSymbol.NONE, "hbmfluid.gasoline");
|
||||
COALGAS = new FluidType("COALGAS",0x445772, 2, 2, 2, 1, 2, 0, EnumSymbol.NONE, "hbmfluid.coalgas");
|
||||
SPENTSTEAM = new FluidType("SPENTSTEAM",0x445772, 3, 2, 2, 2, 0, 0, EnumSymbol.NONE, "hbmfluid.spentsteam", FluidTrait.NO_CONTAINER);
|
||||
FRACKSOL = new FluidType("FRACKSOL",0x798A6B, 4, 2, 2, 1, 3, 3, EnumSymbol.ACID, "hbmfluid.fracksol", FluidTrait.CORROSIVE);
|
||||
PLASMA_DT = new FluidType("PLASMA_DT",0xF7AFDE, 8, 1, 2, 0, 4, 0, EnumSymbol.RADIATION, "hbmfluid.plasma_dt", 3250, FluidTrait.NO_CONTAINER, FluidTrait.NO_ID);
|
||||
@ -150,6 +161,13 @@ public class Fluids {
|
||||
DEATH = new FluidType("DEATH",0x717A88, 8, 2, 2, 2, 0, 1, EnumSymbol.ACID, "hbmfluid.death", 300, FluidTrait.CORROSIVE_2, FluidTrait.LEAD_CONTAINER);
|
||||
ETHANOL = new FluidType("ETHANOL",0xe0ffff, 9, 2, 2, 2, 3, 0, EnumSymbol.NONE, "hbmfluid.ethanol");
|
||||
HEAVYWATER = new FluidType("HEAVYWATER",0x00a0b0, 10, 2, 2, 1, 0, 0, EnumSymbol.NONE, "hbmfluid.heavywater");
|
||||
CRACKOIL = new FluidType("CRACKOIL",0x020202, 6, 1, 1, 2, 1, 0, EnumSymbol.NONE, "hbmfluid.crackoil");
|
||||
COALOIL = new FluidType("COALOIL",0x020202, 6, 1, 1, 2, 1, 0, EnumSymbol.NONE, "hbmfluid.coaloil");
|
||||
HOTCRACKOIL = new FluidType("HOTCRACKOIL",0x300900, 8, 2, 1, 2, 3, 0, EnumSymbol.NONE, "hbmfluid.hotcrackoil", 350);
|
||||
NAPHTHA_CRACK = new FluidType("NAPHTHA_CRACK",0x595744, 5, 2, 1, 2, 1, 0, EnumSymbol.NONE, "hbmfluid.naphtha_crack");
|
||||
LIGHTOIL_CRACK = new FluidType("LIGHTOIL_CRACK",0x8c7451, 6, 2, 1, 1, 2, 0, EnumSymbol.NONE, "hbmfluid.lightoil_crack");
|
||||
AROMATICS = new FluidType("AROMATICS",0xfffeed, 13, 1, 1, 1, 4, 1, EnumSymbol.NONE, "hbmfluid.aromatics");
|
||||
UNSATURATEDS = new FluidType("UNSATURATEDS",0xfffeed, 13, 1, 1, 1, 4, 1, EnumSymbol.NONE, "hbmfluid.unsaturateds");
|
||||
// ^ ^ ^ ^ ^ ^ ^ ^
|
||||
//ADD NEW FLUIDS HERE
|
||||
//AND DON'T FORGET THE META DOWN HERE
|
||||
@ -181,25 +199,35 @@ public class Fluids {
|
||||
metaOrder.add(MERCURY);
|
||||
//oils, fuels
|
||||
metaOrder.add(OIL);
|
||||
metaOrder.add(CRACKOIL);
|
||||
metaOrder.add(COALOIL);
|
||||
metaOrder.add(HOTOIL);
|
||||
metaOrder.add(HOTCRACKOIL);
|
||||
//metaOrder.add(HOTCOALOIL);
|
||||
metaOrder.add(HEAVYOIL);
|
||||
metaOrder.add(NAPHTHA);
|
||||
metaOrder.add(NAPHTHA_CRACK);
|
||||
metaOrder.add(LIGHTOIL);
|
||||
metaOrder.add(LIGHTOIL_CRACK);
|
||||
metaOrder.add(BITUMEN);
|
||||
metaOrder.add(SMEAR);
|
||||
metaOrder.add(HEATINGOIL);
|
||||
metaOrder.add(RECLAIMED);
|
||||
metaOrder.add(PETROIL);
|
||||
metaOrder.add(LUBRICANT);
|
||||
metaOrder.add(DIESEL);
|
||||
metaOrder.add(KEROSENE);
|
||||
metaOrder.add(GAS);
|
||||
metaOrder.add(PETROLEUM);
|
||||
metaOrder.add(LPG);
|
||||
metaOrder.add(ETHANOL);
|
||||
metaOrder.add(AROMATICS);
|
||||
metaOrder.add(UNSATURATEDS);
|
||||
metaOrder.add(DIESEL);
|
||||
metaOrder.add(DIESEL_CRACK);
|
||||
metaOrder.add(KEROSENE);
|
||||
metaOrder.add(GASOLINE);
|
||||
metaOrder.add(COALGAS);
|
||||
metaOrder.add(BIOGAS);
|
||||
metaOrder.add(BIOFUEL);
|
||||
metaOrder.add(GASOLINE);
|
||||
metaOrder.add(ETHANOL);
|
||||
metaOrder.add(NITAN);
|
||||
metaOrder.add(BALEFIRE);
|
||||
//processing fluids
|
||||
|
||||
63
src/main/java/com/hbm/inventory/gui/GUISolidifier.java
Normal file
63
src/main/java/com/hbm/inventory/gui/GUISolidifier.java
Normal file
@ -0,0 +1,63 @@
|
||||
package com.hbm.inventory.gui;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import com.hbm.inventory.FluidTank;
|
||||
import com.hbm.inventory.container.ContainerSolidifier;
|
||||
import com.hbm.lib.RefStrings;
|
||||
import com.hbm.tileentity.machine.TileEntityMachineSolidifier;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.resources.I18n;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
public class GUISolidifier extends GuiInfoContainer {
|
||||
|
||||
private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/processing/gui_solidifier.png");
|
||||
private TileEntityMachineSolidifier solidifier;
|
||||
|
||||
public GUISolidifier(InventoryPlayer invPlayer, TileEntityMachineSolidifier tedf) {
|
||||
super(new ContainerSolidifier(invPlayer, tedf));
|
||||
solidifier = tedf;
|
||||
|
||||
this.xSize = 176;
|
||||
this.ySize = 204;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float f) {
|
||||
super.drawScreen(mouseX, mouseY, f);
|
||||
|
||||
solidifier.tank.renderTankInfo(this, mouseX, mouseY, guiLeft + 35, guiTop + 36, 16, 52);
|
||||
this.drawElectricityInfo(this, mouseX, mouseY, guiLeft + 134, guiTop + 18, 16, 52, solidifier.power, solidifier.maxPower);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void drawGuiContainerForegroundLayer(int i, int j) {
|
||||
|
||||
String name = this.solidifier.hasCustomInventoryName() ? this.solidifier.getInventoryName() : I18n.format(this.solidifier.getInventoryName());
|
||||
|
||||
this.fontRendererObj.drawString(name, 70 - this.fontRendererObj.getStringWidth(name) / 2, 6, 0xC7C1A3);
|
||||
this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture(texture);
|
||||
drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);
|
||||
|
||||
int i = (int)(solidifier.getPower() * 52 / solidifier.getMaxPower());
|
||||
drawTexturedModalRect(guiLeft + 134, guiTop + 70 - i, 176, 52 - i, 16, i);
|
||||
|
||||
int j = solidifier.progress * 42 / solidifier.processTime;
|
||||
drawTexturedModalRect(guiLeft + 42, guiTop + 17, 192, 0, j, 35);
|
||||
|
||||
if(i > 0)
|
||||
drawTexturedModalRect(guiLeft + 138, guiTop + 4, 176, 52, 9, 12);
|
||||
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture(solidifier.tank.getSheet());
|
||||
solidifier.tank.renderTank(this, guiLeft + 35, guiTop + 88, solidifier.tank.getTankType().textureX() * FluidTank.x, solidifier.tank.getTankType().textureY() * FluidTank.y, 16, 52);
|
||||
}
|
||||
}
|
||||
@ -381,10 +381,10 @@ public abstract class GuiInfoContainer extends GuiContainer {
|
||||
GL11.glDisable(GL11.GL_TEXTURE_2D);
|
||||
tess.startDrawingQuads();
|
||||
tess.setColorOpaque_I(color);
|
||||
tess.addVertex(renX, renY + height, z);
|
||||
tess.addVertex(renX + width, renY + height, z);
|
||||
tess.addVertex(renX + width, renY + 0, z);
|
||||
tess.addVertex(renX, renY, z);
|
||||
tess.addVertex(renX, renY + height, z);
|
||||
tess.addVertex(renX + width, renY + height, z);
|
||||
tess.addVertex(renX + width, renY + 0, z);
|
||||
tess.addVertex(renX, renY, z);
|
||||
tess.draw();
|
||||
GL11.glEnable(GL11.GL_TEXTURE_2D);
|
||||
}
|
||||
|
||||
@ -21,15 +21,12 @@ public class LiquefactionRecipes {
|
||||
|
||||
public static void register() {
|
||||
|
||||
//TODO: make sure to either remove chemplant liquefication recipes or to adjust the values to match these
|
||||
|
||||
//temporary, replace with liquefacted coal (or coal oil? parallel to crude and crack oils perhaps)
|
||||
//if coal oil isn't parallel, we could do coal -> coal oil -> coal tar -> crude oil (or crack oil)
|
||||
//if coal oil is parallel, we might fractionate it into crude or crack oil and coal gasoline
|
||||
recipes.put(COAL.gem(), new FluidStack(100, Fluids.OIL));
|
||||
recipes.put(COAL.dust(), new FluidStack(100, Fluids.OIL));
|
||||
//make sure to include bitumen to tar in the solidificator with matching values
|
||||
recipes.put(ANY_TAR.any(), new FluidStack(100, Fluids.BITUMEN));
|
||||
//oil processing
|
||||
recipes.put(COAL.gem(), new FluidStack(100, Fluids.COALOIL));
|
||||
recipes.put(COAL.dust(), new FluidStack(100, Fluids.COALOIL));
|
||||
recipes.put(KEY_OIL_TAR, new FluidStack(75, Fluids.BITUMEN));
|
||||
recipes.put(KEY_CRACK_TAR, new FluidStack(100, Fluids.BITUMEN));
|
||||
recipes.put(KEY_COAL_TAR, new FluidStack(50, Fluids.BITUMEN));
|
||||
//general utility recipes because why not
|
||||
recipes.put(new ComparableStack(Blocks.netherrack), new FluidStack(250, Fluids.LAVA));
|
||||
recipes.put(new ComparableStack(Blocks.cobblestone), new FluidStack(250, Fluids.LAVA));
|
||||
|
||||
@ -162,6 +162,7 @@ public class MachineRecipes {
|
||||
if(type == Fluids.STEAM) return new Object[] { Fluids.HOTSTEAM, 5, 50, 30000 };
|
||||
if(type == Fluids.HOTSTEAM) return new Object[] { Fluids.SUPERHOTSTEAM, 5, 50, 45000 };
|
||||
if(type == Fluids.OIL) return new Object[] { Fluids.HOTOIL, 5, 5, 35000 };
|
||||
if(type == Fluids.CRACKOIL) return new Object[] { Fluids.HOTCRACKOIL, 5, 5, 35000 };
|
||||
|
||||
return null;
|
||||
}
|
||||
@ -1469,51 +1470,51 @@ public class MachineRecipes {
|
||||
input[0] = new FluidStack(800, Fluids.ACID);
|
||||
input[1] = new FluidStack(200, Fluids.MERCURY);
|
||||
break;
|
||||
case SF_OIL:
|
||||
input[0] = new FluidStack(350, Fluids.OIL);
|
||||
break;
|
||||
case SF_HEAVYOIL:
|
||||
input[0] = new FluidStack(250, Fluids.HEAVYOIL);
|
||||
break;
|
||||
case SF_SMEAR:
|
||||
input[0] = new FluidStack(200, Fluids.SMEAR);
|
||||
break;
|
||||
case SF_HEATINGOIL:
|
||||
input[0] = new FluidStack(100, Fluids.HEATINGOIL);
|
||||
break;
|
||||
case SF_RECLAIMED:
|
||||
input[0] = new FluidStack(200, Fluids.RECLAIMED);
|
||||
break;
|
||||
case SF_PETROIL:
|
||||
input[0] = new FluidStack(250, Fluids.PETROIL);
|
||||
break;
|
||||
case SF_LUBRICANT:
|
||||
input[0] = new FluidStack(250, Fluids.LUBRICANT);
|
||||
break;
|
||||
case SF_NAPHTHA:
|
||||
input[0] = new FluidStack(300, Fluids.NAPHTHA);
|
||||
break;
|
||||
case SF_DIESEL:
|
||||
input[0] = new FluidStack(400, Fluids.DIESEL);
|
||||
break;
|
||||
case SF_LIGHTOIL:
|
||||
input[0] = new FluidStack(450, Fluids.LIGHTOIL);
|
||||
break;
|
||||
case SF_KEROSENE:
|
||||
input[0] = new FluidStack(550, Fluids.KEROSENE);
|
||||
break;
|
||||
case SF_GAS:
|
||||
input[0] = new FluidStack(750, Fluids.GAS);
|
||||
break;
|
||||
case SF_PETROLEUM:
|
||||
input[0] = new FluidStack(600, Fluids.PETROLEUM);
|
||||
break;
|
||||
case SF_BIOGAS:
|
||||
input[0] = new FluidStack(3500, Fluids.BIOGAS);
|
||||
break;
|
||||
case SF_BIOFUEL:
|
||||
input[0] = new FluidStack(1500, Fluids.BIOFUEL);
|
||||
break;
|
||||
case SF_OIL:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_OIL * 2, Fluids.OIL);
|
||||
break;
|
||||
case SF_HEAVYOIL:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_HEAVY * 2, Fluids.HEAVYOIL);
|
||||
break;
|
||||
case SF_SMEAR:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_SMEAR * 2, Fluids.SMEAR);
|
||||
break;
|
||||
case SF_HEATINGOIL:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_HEATING * 2, Fluids.HEATINGOIL);
|
||||
break;
|
||||
case SF_RECLAIMED:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_RECLAIMED * 2, Fluids.RECLAIMED);
|
||||
break;
|
||||
case SF_PETROIL:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_PETROIL * 2, Fluids.PETROIL);
|
||||
break;
|
||||
case SF_LUBRICANT:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_LUBE * 2, Fluids.LUBRICANT);
|
||||
break;
|
||||
case SF_NAPHTHA:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_NAPH * 2, Fluids.NAPHTHA);
|
||||
break;
|
||||
case SF_DIESEL:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_DIESEL * 2, Fluids.DIESEL);
|
||||
break;
|
||||
case SF_LIGHTOIL:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_LIGHT * 2, Fluids.LIGHTOIL);
|
||||
break;
|
||||
case SF_KEROSENE:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_KEROSENE * 2, Fluids.KEROSENE);
|
||||
break;
|
||||
case SF_GAS:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_GAS * 2, Fluids.GAS);
|
||||
break;
|
||||
case SF_PETROLEUM:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_PETROLEUM * 2, Fluids.PETROLEUM);
|
||||
break;
|
||||
case SF_BIOGAS:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_BIOGAS * 2, Fluids.BIOGAS);
|
||||
break;
|
||||
case SF_BIOFUEL:
|
||||
input[0] = new FluidStack(SolidificationRecipes.SF_BIOFUEL * 2, Fluids.BIOFUEL);
|
||||
break;
|
||||
case POLYMER:
|
||||
input[0] = new FluidStack(600, Fluids.PETROLEUM);
|
||||
break;
|
||||
|
||||
@ -3,8 +3,10 @@ package com.hbm.inventory.recipes;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import com.hbm.inventory.OreDictManager.DictFrame;
|
||||
import com.hbm.inventory.fluid.FluidType;
|
||||
import com.hbm.inventory.fluid.Fluids;
|
||||
import com.hbm.items.ItemEnums.EnumTarType;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.machine.ItemFluidIcon;
|
||||
import com.hbm.util.Tuple.Quartet;
|
||||
@ -18,6 +20,10 @@ public class RefineryRecipes {
|
||||
public static final int oil_frac_naph = 25;
|
||||
public static final int oil_frac_light = 15;
|
||||
public static final int oil_frac_petro = 10;
|
||||
public static final int crack_frac_naph = 40;
|
||||
public static final int crack_frac_light = 30;
|
||||
public static final int crack_frac_aroma = 15;
|
||||
public static final int crack_frac_unsat = 15;
|
||||
|
||||
public static final int heavy_frac_bitu = 30;
|
||||
public static final int heavy_frac_smear = 70;
|
||||
@ -27,13 +33,23 @@ public class RefineryRecipes {
|
||||
public static final int napht_frac_diesel = 60;
|
||||
public static final int light_frac_diesel = 40;
|
||||
public static final int light_frac_kero = 60;
|
||||
|
||||
public static final int ncrack_frac_heat = 30;
|
||||
public static final int ncrack_frac_diesel = 70;
|
||||
public static final int lcrack_frac_kero = 70;
|
||||
public static final int lcrack_frac_petro = 30;
|
||||
public static final int coal_frac_coalgas = 70;
|
||||
public static final int coal_frac_natgas = 30;
|
||||
|
||||
//cracking in percent
|
||||
public static final int oil_crack_oil = 80;
|
||||
public static final int oil_crack_petro = 20;
|
||||
public static final int bitumen_crack_oil = 80;
|
||||
public static final int bitumen_crack_petro = 20;
|
||||
public static final int bitumen_crack_aroma = 20;
|
||||
public static final int smear_crack_napht = 60;
|
||||
public static final int smear_crack_petro = 40;
|
||||
public static final int gas_crack_petro = 50;
|
||||
public static final int gas_crack_petro = 30;
|
||||
public static final int gas_crack_unsat = 20;
|
||||
public static final int diesel_crack_kero = 40;
|
||||
public static final int diesel_crack_petro = 30;
|
||||
public static final int kero_crack_petro = 60;
|
||||
@ -54,30 +70,42 @@ public class RefineryRecipes {
|
||||
ItemFluidIcon.make(Fluids.PETROLEUM, oil_frac_petro * 10),
|
||||
new ItemStack(ModItems.sulfur, 1) });
|
||||
|
||||
recipes.put(ItemFluidIcon.make(Fluids.HOTCRACKOIL, 1000),
|
||||
new ItemStack[] {
|
||||
ItemFluidIcon.make(Fluids.NAPHTHA_CRACK, crack_frac_naph * 10),
|
||||
ItemFluidIcon.make(Fluids.LIGHTOIL_CRACK, crack_frac_light * 10),
|
||||
ItemFluidIcon.make(Fluids.AROMATICS, crack_frac_aroma * 10),
|
||||
ItemFluidIcon.make(Fluids.UNSATURATEDS, crack_frac_unsat * 10),
|
||||
DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRACK) });
|
||||
|
||||
/*recipes.put(ItemFluidIcon.make(Fluids.HOTCRACKOIL, 1000),
|
||||
new ItemStack[] {
|
||||
ItemFluidIcon.make(Fluids.NAPHTHA_CRACK, oil_frac_heavy * 10), //fractionates into crack diesel and heating oil
|
||||
ItemFluidIcon.make(Fluids.LIGHTOIL_CRACK, oil_frac_naph * 10), //fractionates into kerosene and petroleum
|
||||
ItemFluidIcon.make(Fluids.AROMATICS, oil_frac_light * 10), //used for making bakelite and TNT
|
||||
ItemFluidIcon.make(Fluids.UNSATURATEDS, oil_frac_petro * 10), //used for all sorts of things, can be processed into petroleum
|
||||
ItemFluidIcon.make(Fluids.UNSATURATEDS, oil_frac_petro * 10), //for bakelite and perhaps acetylene torches
|
||||
DictFrame.fromOne(ModItems.coke, EnumCokeType.PETROLEUM) });*/
|
||||
|
||||
return recipes;
|
||||
}
|
||||
|
||||
public static void registerFractions() {
|
||||
fractions.put(Fluids.HEAVYOIL, new Quartet(Fluids.BITUMEN, Fluids.SMEAR, heavy_frac_bitu, heavy_frac_smear));
|
||||
fractions.put(Fluids.SMEAR, new Quartet(Fluids.HEATINGOIL, Fluids.LUBRICANT, smear_frac_heat, smear_frac_lube));
|
||||
fractions.put(Fluids.NAPHTHA, new Quartet(Fluids.HEATINGOIL, Fluids.DIESEL, napht_frac_heat, napht_frac_diesel));
|
||||
fractions.put(Fluids.LIGHTOIL, new Quartet(Fluids.DIESEL, Fluids.KEROSENE, light_frac_diesel, light_frac_kero));
|
||||
fractions.put(Fluids.HEAVYOIL, new Quartet(Fluids.BITUMEN, Fluids.SMEAR, heavy_frac_bitu, heavy_frac_smear));
|
||||
fractions.put(Fluids.SMEAR, new Quartet(Fluids.HEATINGOIL, Fluids.LUBRICANT, smear_frac_heat, smear_frac_lube));
|
||||
fractions.put(Fluids.NAPHTHA, new Quartet(Fluids.HEATINGOIL, Fluids.DIESEL, napht_frac_heat, napht_frac_diesel));
|
||||
fractions.put(Fluids.NAPHTHA_CRACK, new Quartet(Fluids.HEATINGOIL, Fluids.DIESEL_CRACK, ncrack_frac_heat, ncrack_frac_diesel));
|
||||
fractions.put(Fluids.LIGHTOIL, new Quartet(Fluids.DIESEL, Fluids.KEROSENE, light_frac_diesel, light_frac_kero));
|
||||
fractions.put(Fluids.LIGHTOIL_CRACK, new Quartet(Fluids.KEROSENE, Fluids.PETROLEUM, lcrack_frac_kero, lcrack_frac_petro));
|
||||
fractions.put(Fluids.COALOIL, new Quartet(Fluids.COALGAS, Fluids.GAS, coal_frac_coalgas, coal_frac_natgas));
|
||||
}
|
||||
|
||||
public static void registerCracking() {
|
||||
cracking.put(Fluids.BITUMEN, new Quartet(Fluids.OIL, Fluids.PETROLEUM, bitumen_crack_oil, bitumen_crack_petro));
|
||||
cracking.put(Fluids.SMEAR, new Quartet(Fluids.NAPHTHA, Fluids.PETROLEUM, smear_crack_napht, smear_crack_petro));
|
||||
cracking.put(Fluids.GAS, new Quartet(Fluids.PETROLEUM, Fluids.NONE, gas_crack_petro, 0));
|
||||
cracking.put(Fluids.DIESEL, new Quartet(Fluids.KEROSENE, Fluids.PETROLEUM, diesel_crack_kero, diesel_crack_petro));
|
||||
cracking.put(Fluids.KEROSENE, new Quartet(Fluids.PETROLEUM, Fluids.NONE, kero_crack_petro, 0));
|
||||
cracking.put(Fluids.OIL, new Quartet(Fluids.CRACKOIL, Fluids.PETROLEUM, oil_crack_oil, oil_crack_petro));
|
||||
cracking.put(Fluids.BITUMEN, new Quartet(Fluids.OIL, Fluids.AROMATICS, bitumen_crack_oil, bitumen_crack_aroma));
|
||||
cracking.put(Fluids.SMEAR, new Quartet(Fluids.NAPHTHA, Fluids.PETROLEUM, smear_crack_napht, smear_crack_petro));
|
||||
cracking.put(Fluids.GAS, new Quartet(Fluids.PETROLEUM, Fluids.UNSATURATEDS, gas_crack_petro, gas_crack_unsat));
|
||||
cracking.put(Fluids.DIESEL, new Quartet(Fluids.KEROSENE, Fluids.PETROLEUM, diesel_crack_kero, diesel_crack_petro));
|
||||
cracking.put(Fluids.KEROSENE, new Quartet(Fluids.PETROLEUM, Fluids.NONE, kero_crack_petro, 0));
|
||||
}
|
||||
|
||||
public static Quartet<FluidType, FluidType, Integer, Integer> getFractions(FluidType oil) {
|
||||
|
||||
@ -17,17 +17,66 @@ import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class SolidificationRecipes {
|
||||
|
||||
public static final int SF_OIL = 200;
|
||||
public static final int SF_CRACK = 200;
|
||||
public static final int SF_HEAVY = 150;
|
||||
public static final int SF_BITUMEN = 100;
|
||||
public static final int SF_SMEAR = 100;
|
||||
public static final int SF_HEATING = 50;
|
||||
public static final int SF_RECLAIMED = 100;
|
||||
public static final int SF_PETROIL = 125;
|
||||
public static final int SF_LUBE = 125;
|
||||
public static final int SF_NAPH = 150;
|
||||
public static final int SF_DIESEL = 200;
|
||||
public static final int SF_LIGHT = 225;
|
||||
public static final int SF_KEROSENE = 275;
|
||||
public static final int SF_GAS = 375;
|
||||
public static final int SF_PETROLEUM = 300;
|
||||
public static final int SF_LPG = 150;
|
||||
public static final int SF_BIOGAS = 1750;
|
||||
public static final int SF_BIOFUEL = 750;
|
||||
public static final int SF_COALOIL = 200;
|
||||
//mostly for alternate chemistry, dump into SF if not desired
|
||||
public static final int SF_AROMA = 1000;
|
||||
public static final int SF_UNSAT = 1000;
|
||||
//in the event that these compounds are STILL too useless, add unsat + gas -> kerosene recipe for all those missile junkies
|
||||
//aromatics can be idfk wax or soap or sth, perhaps artificial lubricant?
|
||||
//on that note, add more leaded variants
|
||||
|
||||
private static HashMap<FluidType, Pair<Integer, ItemStack>> recipes = new HashMap();
|
||||
|
||||
public static void register() {
|
||||
registerRecipe(WATER, 1000, Blocks.ice);
|
||||
registerRecipe(LAVA, 1000, Blocks.obsidian);
|
||||
|
||||
//temporary recipes with incorrect quantities
|
||||
registerRecipe(OIL, 1000, DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRUDE));
|
||||
registerRecipe(BITUMEN, 1000, DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRUDE));
|
||||
registerRecipe(HEATINGOIL, 1000, ModItems.solid_fuel);
|
||||
registerRecipe(WATER, 1000, Blocks.ice);
|
||||
registerRecipe(LAVA, 1000, Blocks.obsidian);
|
||||
|
||||
registerRecipe(OIL, SF_OIL, DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRUDE));
|
||||
registerRecipe(CRACKOIL, SF_OIL, DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRACK));
|
||||
registerRecipe(COALOIL, SF_OIL, DictFrame.fromOne(ModItems.oil_tar, EnumTarType.COAL));
|
||||
registerRecipe(HEAVYOIL, SF_HEAVY, DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRUDE));
|
||||
registerRecipe(BITUMEN, SF_BITUMEN, DictFrame.fromOne(ModItems.oil_tar, EnumTarType.CRUDE));
|
||||
|
||||
registerRecipe(SMEAR, SF_SMEAR, ModItems.solid_fuel);
|
||||
registerRecipe(HEATINGOIL, SF_HEATING, ModItems.solid_fuel);
|
||||
registerRecipe(RECLAIMED, SF_RECLAIMED, ModItems.solid_fuel);
|
||||
registerRecipe(PETROIL, SF_PETROIL, ModItems.solid_fuel);
|
||||
registerRecipe(LUBRICANT, SF_LUBE, ModItems.solid_fuel);
|
||||
registerRecipe(NAPHTHA, SF_NAPH, ModItems.solid_fuel);
|
||||
registerRecipe(NAPHTHA_CRACK, SF_NAPH, ModItems.solid_fuel);
|
||||
registerRecipe(DIESEL, SF_DIESEL, ModItems.solid_fuel);
|
||||
registerRecipe(DIESEL_CRACK, SF_DIESEL, ModItems.solid_fuel);
|
||||
registerRecipe(LIGHTOIL, SF_LIGHT, ModItems.solid_fuel);
|
||||
registerRecipe(LIGHTOIL_CRACK, SF_LIGHT, ModItems.solid_fuel);
|
||||
registerRecipe(KEROSENE, SF_KEROSENE, ModItems.solid_fuel);
|
||||
registerRecipe(GAS, SF_GAS, ModItems.solid_fuel);
|
||||
registerRecipe(PETROLEUM, SF_PETROLEUM, ModItems.solid_fuel);
|
||||
registerRecipe(LPG, SF_LPG, ModItems.solid_fuel);
|
||||
registerRecipe(BIOGAS, SF_BIOGAS, ModItems.solid_fuel);
|
||||
registerRecipe(BIOFUEL, SF_BIOFUEL, ModItems.solid_fuel);
|
||||
registerRecipe(COALOIL, SF_COALOIL, ModItems.solid_fuel);
|
||||
registerRecipe(AROMATICS, SF_AROMA, ModItems.solid_fuel);
|
||||
registerRecipe(UNSATURATEDS, SF_UNSAT, ModItems.solid_fuel);
|
||||
}
|
||||
|
||||
private static void registerRecipe(FluidType type, int quantity, Item output) { registerRecipe(type, quantity, new ItemStack(output)); }
|
||||
|
||||
@ -16,6 +16,7 @@ public class ItemEnums {
|
||||
|
||||
public static enum EnumTarType {
|
||||
CRUDE,
|
||||
CRACK
|
||||
CRACK,
|
||||
COAL
|
||||
}
|
||||
}
|
||||
|
||||
@ -443,6 +443,7 @@ public class ModItems {
|
||||
|
||||
public static Item powder_dura_steel;
|
||||
public static Item powder_polymer;
|
||||
public static Item powder_bakelite;
|
||||
public static Item powder_euphemium;
|
||||
public static Item powder_meteorite;
|
||||
|
||||
@ -2886,6 +2887,7 @@ public class ModItems {
|
||||
powder_cerium = new ItemCustomLore().setRarity(EnumRarity.epic).setUnlocalizedName("powder_cerium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":powder_cerium");
|
||||
powder_dura_steel = new ItemCustomLore().setUnlocalizedName("powder_dura_steel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":powder_dura_steel");
|
||||
powder_polymer = new ItemCustomLore().setUnlocalizedName("powder_polymer").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":powder_polymer");
|
||||
powder_bakelite = new ItemCustomLore().setUnlocalizedName("powder_bakelite").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":powder_bakelite");
|
||||
powder_euphemium = new ItemCustomLore().setRarity(EnumRarity.epic).setUnlocalizedName("powder_euphemium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":powder_euphemium");
|
||||
powder_meteorite = new Item().setUnlocalizedName("powder_meteorite").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":powder_meteorite");
|
||||
powder_lanthanium = new ItemCustomLore().setRarity(EnumRarity.epic).setUnlocalizedName("powder_lanthanium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":powder_lanthanium");
|
||||
@ -5746,6 +5748,7 @@ public class ModItems {
|
||||
GameRegistry.registerItem(powder_beryllium, powder_beryllium.getUnlocalizedName());
|
||||
GameRegistry.registerItem(powder_dura_steel, powder_dura_steel.getUnlocalizedName());
|
||||
GameRegistry.registerItem(powder_polymer, powder_polymer.getUnlocalizedName());
|
||||
GameRegistry.registerItem(powder_bakelite, powder_bakelite.getUnlocalizedName());
|
||||
GameRegistry.registerItem(powder_schrabidium, powder_schrabidium.getUnlocalizedName());
|
||||
GameRegistry.registerItem(powder_schrabidate, powder_schrabidate.getUnlocalizedName());
|
||||
GameRegistry.registerItem(powder_magnetized_tungsten, powder_magnetized_tungsten.getUnlocalizedName());
|
||||
|
||||
@ -204,6 +204,7 @@ public class ClientProxy extends ServerProxy {
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityDeuteriumTower.class, new RenderDeuteriumTower());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineCatalyticCracker.class, new RenderCatalyticCracker());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineLiquefactor.class, new RenderLiquefactor());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineSolidifier.class, new RenderSolidifier());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineRadiolysis.class, new RenderRadiolysis());
|
||||
//AMS
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityAMSBase.class, new RenderAMSBase());
|
||||
|
||||
@ -951,6 +951,7 @@ public class MainRegistry {
|
||||
RefineryRecipes.registerCracking();
|
||||
RadiolysisRecipes.registerRadiolysis();
|
||||
LiquefactionRecipes.register();
|
||||
SolidificationRecipes.register();
|
||||
FuelPoolRecipes.register();
|
||||
|
||||
TileEntityNukeCustom.registerBombItems();
|
||||
|
||||
@ -67,6 +67,7 @@ public class ResourceManager {
|
||||
public static final IModelCustom fraction_spacer = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/machines/fraction_spacer.obj"));
|
||||
public static final IModelCustom cracking_tower = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/machines/cracking_tower.obj"));
|
||||
public static final IModelCustom liquefactor = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/machines/liquefactor.obj"));
|
||||
public static final IModelCustom solidifier = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/machines/solidifier.obj"));
|
||||
|
||||
//Flare Stack
|
||||
public static final IModelCustom oilflare = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/oilFlare.obj"));
|
||||
@ -348,6 +349,7 @@ public class ResourceManager {
|
||||
public static final ResourceLocation fraction_spacer_tex = new ResourceLocation(RefStrings.MODID, "textures/models/machines/fraction_spacer.png");
|
||||
public static final ResourceLocation cracking_tower_tex = new ResourceLocation(RefStrings.MODID, "textures/models/machines/cracking_tower.png");
|
||||
public static final ResourceLocation liquefactor_tex = new ResourceLocation(RefStrings.MODID, "textures/models/machines/liquefactor.png");
|
||||
public static final ResourceLocation solidifier_tex = new ResourceLocation(RefStrings.MODID, "textures/models/machines/solidifier.png");
|
||||
|
||||
//Flare Stack
|
||||
public static final ResourceLocation oilflare_tex = new ResourceLocation(RefStrings.MODID, "textures/models/oilFlareTexture.png");
|
||||
|
||||
@ -1195,6 +1195,17 @@ public class ItemRenderLibrary {
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}});
|
||||
|
||||
renderers.put(Item.getItemFromBlock(ModBlocks.machine_solidifier), new ItemRenderBase( ) {
|
||||
public void renderInventory() {
|
||||
GL11.glTranslated(0, -2.5, 0);
|
||||
GL11.glScaled(3, 3, 3);
|
||||
}
|
||||
public void renderCommon() {
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
bindTexture(ResourceManager.solidifier_tex); ResourceManager.solidifier.renderPart("Main");
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}});
|
||||
|
||||
renderers.put(Item.getItemFromBlock(ModBlocks.machine_radiolysis), new ItemRenderBase( ) {
|
||||
public void renderInventory() {
|
||||
GL11.glTranslated(0, -2.5, 0);
|
||||
|
||||
@ -57,6 +57,7 @@ public class RenderLiquefactor extends TileEntitySpecialRenderer {
|
||||
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
GL11.glEnable(GL11.GL_CULL_FACE);
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
}
|
||||
|
||||
@ -0,0 +1,71 @@
|
||||
package com.hbm.render.tileentity;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import com.hbm.blocks.BlockDummyable;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.tileentity.machine.TileEntityMachineSolidifier;
|
||||
|
||||
import net.minecraft.client.renderer.OpenGlHelper;
|
||||
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
||||
public class RenderSolidifier extends TileEntitySpecialRenderer {
|
||||
|
||||
@Override
|
||||
public void renderTileEntityAt(TileEntity tileEntity, double x, double y, double z, float f) {
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(x + 0.5D, y, z + 0.5D);
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
GL11.glDisable(GL11.GL_CULL_FACE);
|
||||
|
||||
switch(tileEntity.getBlockMetadata() - BlockDummyable.offset) {
|
||||
case 2: GL11.glRotatef(90, 0F, 1F, 0F); break;
|
||||
case 4: GL11.glRotatef(180, 0F, 1F, 0F); break;
|
||||
case 3: GL11.glRotatef(270, 0F, 1F, 0F); break;
|
||||
case 5: GL11.glRotatef(0, 0F, 1F, 0F); break;
|
||||
}
|
||||
|
||||
TileEntityMachineSolidifier liq = (TileEntityMachineSolidifier) tileEntity;
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
bindTexture(ResourceManager.solidifier_tex);
|
||||
ResourceManager.solidifier.renderPart("Main");
|
||||
|
||||
GL11.glDisable(GL11.GL_LIGHTING);
|
||||
GL11.glDisable(GL11.GL_TEXTURE_2D);
|
||||
|
||||
if(liq.tank.getFill() > 0) {
|
||||
int color = liq.tank.getTankType().getColor();
|
||||
GL11.glColor3ub((byte) ((color & 0xFF0000) >> 16), (byte) ((color & 0x00FF00) >> 8), (byte) ((color & 0x0000FF) >> 0));
|
||||
|
||||
double height = (double)liq.tank.getFill() / (double)liq.tank.getMaxFill();
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, 1, 0);
|
||||
GL11.glScaled(1, height, 1);
|
||||
GL11.glTranslated(0, -1, 0);
|
||||
ResourceManager.solidifier.renderPart("Fluid");
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
GL11.glAlphaFunc(GL11.GL_GREATER, 0);
|
||||
OpenGlHelper.glBlendFunc(770, 771, 1, 0);
|
||||
GL11.glColor4f(0.75F, 1.0F, 1.0F, 0.15F);
|
||||
GL11.glDepthMask(false);
|
||||
|
||||
ResourceManager.solidifier.renderPart("Glass");
|
||||
|
||||
GL11.glDepthMask(true);
|
||||
GL11.glAlphaFunc(GL11.GL_GREATER, 0.1F);
|
||||
GL11.glDisable(GL11.GL_BLEND);
|
||||
GL11.glEnable(GL11.GL_TEXTURE_2D);
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
GL11.glEnable(GL11.GL_CULL_FACE);
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
}
|
||||
@ -1,21 +1,24 @@
|
||||
package com.hbm.tileentity.machine;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.interfaces.IFluidAcceptor;
|
||||
import com.hbm.inventory.FluidTank;
|
||||
import com.hbm.inventory.fluid.FluidType;
|
||||
import com.hbm.inventory.fluid.Fluids;
|
||||
import com.hbm.inventory.recipes.LiquefactionRecipes;
|
||||
import com.hbm.inventory.recipes.SolidificationRecipes;
|
||||
import com.hbm.lib.Library;
|
||||
import com.hbm.tileentity.TileEntityMachineBase;
|
||||
import com.hbm.util.Tuple.Pair;
|
||||
|
||||
import api.hbm.energy.IEnergyUser;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
|
||||
public class TileEntityMachineSolidifier extends TileEntityMachineBase implements IEnergyUser {
|
||||
public class TileEntityMachineSolidifier extends TileEntityMachineBase implements IEnergyUser, IFluidAcceptor {
|
||||
|
||||
public long power;
|
||||
public static final long maxPower = 100000;
|
||||
@ -40,6 +43,7 @@ public class TileEntityMachineSolidifier extends TileEntityMachineBase implement
|
||||
|
||||
if(!worldObj.isRemote) {
|
||||
this.power = Library.chargeTEFromItems(slots, 1, power, maxPower);
|
||||
tank.setType(4, slots);
|
||||
tank.updateTank(this);
|
||||
|
||||
this.trySubscribe(worldObj, xCoord + 2, yCoord + 1, zCoord, Library.POS_X);
|
||||
@ -47,6 +51,11 @@ public class TileEntityMachineSolidifier extends TileEntityMachineBase implement
|
||||
this.trySubscribe(worldObj, xCoord, yCoord + 1, zCoord + 2, Library.POS_Z);
|
||||
this.trySubscribe(worldObj, xCoord, yCoord + 1, zCoord - 2, Library.NEG_Z);
|
||||
|
||||
if(this.canProcess())
|
||||
this.process();
|
||||
else
|
||||
this.progress = 0;
|
||||
|
||||
NBTTagCompound data = new NBTTagCompound();
|
||||
data.setLong("power", this.power);
|
||||
data.setInteger("progress", this.progress);
|
||||
@ -54,6 +63,72 @@ public class TileEntityMachineSolidifier extends TileEntityMachineBase implement
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canExtractItem(int slot, ItemStack stack, int side) {
|
||||
return slot == 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int[] getAccessibleSlotsFromSide(int side) {
|
||||
return new int[] { 0 };
|
||||
}
|
||||
|
||||
public boolean canProcess() {
|
||||
|
||||
if(this.power < usage)
|
||||
return false;
|
||||
|
||||
Pair<Integer, ItemStack> out = SolidificationRecipes.getOutput(tank.getTankType());
|
||||
|
||||
if(out == null)
|
||||
return false;
|
||||
|
||||
int req = out.getKey();
|
||||
ItemStack stack = out.getValue();
|
||||
|
||||
if(req > tank.getFill())
|
||||
return false;
|
||||
|
||||
if(slots[0] != null) {
|
||||
|
||||
if(slots[0].getItem() != stack.getItem())
|
||||
return false;
|
||||
|
||||
if(slots[0].getItemDamage() != stack.getItemDamage())
|
||||
return false;
|
||||
|
||||
if(slots[0].stackSize + stack.stackSize > slots[0].getMaxStackSize())
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public void process() {
|
||||
|
||||
this.power -= usage;
|
||||
|
||||
progress++;
|
||||
|
||||
if(progress >= processTime) {
|
||||
|
||||
Pair<Integer, ItemStack> out = SolidificationRecipes.getOutput(tank.getTankType());
|
||||
int req = out.getKey();
|
||||
ItemStack stack = out.getValue();
|
||||
tank.setFill(tank.getFill() - req);
|
||||
|
||||
if(slots[0] == null) {
|
||||
slots[0] = stack.copy();
|
||||
} else {
|
||||
slots[0].stackSize += stack.stackSize;
|
||||
}
|
||||
|
||||
progress = 0;
|
||||
|
||||
this.markDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void networkUnpack(NBTTagCompound nbt) {
|
||||
this.power = nbt.getLong("power");
|
||||
@ -86,6 +161,42 @@ public class TileEntityMachineSolidifier extends TileEntityMachineBase implement
|
||||
public long getMaxPower() {
|
||||
return maxPower;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setFillstate(int fill, int index) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setFluidFill(int fill, FluidType type) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setType(FluidType type, int index) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<FluidTank> getTanks() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getFluidFill(FluidType type) {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaxFluidFill(FluidType type) {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
AxisAlignedBB bb = null;
|
||||
|
||||
|
||||
@ -18,7 +18,7 @@ achievement.bossMeltdown.desc=More terrible than great, but I take what I can ge
|
||||
achievement.bossMeltdown=3.6 Roentgen
|
||||
achievement.bossWorm.desc=The Fabstaff. My ass. You do the math.
|
||||
achievement.bossWorm=Disassembling Balls-O-Tron
|
||||
achievement.bossUFO.desc=Yo, what do we have here? A huge spacecraft pulling up to the bloockship?
|
||||
achievement.bossUFO.desc=Yo, what do we have here? A huge spacecraft pulling up to the blockship?
|
||||
achievement.bossUFO=Ayy Lmao
|
||||
achievement.burnerPress.desc=Pressure pushing down on me, on you
|
||||
achievement.burnerPress=Under Pressure
|
||||
|
||||
1850
src/main/resources/assets/hbm/models/machines/solidifier.obj
Normal file
1850
src/main/resources/assets/hbm/models/machines/solidifier.obj
Normal file
File diff suppressed because it is too large
Load Diff
BIN
src/main/resources/assets/hbm/textures/items/oil_tar.coal.png
Normal file
BIN
src/main/resources/assets/hbm/textures/items/oil_tar.coal.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 411 B |
BIN
src/main/resources/assets/hbm/textures/items/powder_bakelite.png
Normal file
BIN
src/main/resources/assets/hbm/textures/items/powder_bakelite.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 337 B |
Binary file not shown.
|
After Width: | Height: | Size: 3.1 KiB |
Loading…
x
Reference in New Issue
Block a user