diff --git a/assets/hbm/lang/de_DE.lang b/assets/hbm/lang/de_DE.lang index eecea0cf7..522cb9907 100644 --- a/assets/hbm/lang/de_DE.lang +++ b/assets/hbm/lang/de_DE.lang @@ -509,7 +509,9 @@ item.fuse.name=Sicherung tile.test_nuke.name=Test Atombombe +item.ingot_th232.name=Th232-Barren item.ingot_uranium.name=Uranbarren +item.ingot_u233.name=U233-Barren item.ingot_u235.name=U235-Barren item.ingot_u238.name=U238-Barren item.ingot_u238m2.name=Metastabiler U238/2-Barren @@ -1093,6 +1095,8 @@ item.t45_kit.name=T45-Powerrüstungskit item.euphemium_kit.name=Euphemium Kit item.solinium_kit.name=Solinium Kit item.hazmat_kit.name=Strahlenschutz-Kit +item.hazmat_red_kit.name=Lvl 2 Strahlenschutz-Kit +item.hazmat_grey_kit.name=Lvl 3 Strahlenschutz-Kit tile.waste_earth.name=Totes Gras tile.waste_trinitite.name=Trinititerz @@ -1103,12 +1107,14 @@ tile.waste_planks.name=Verkohlte Holzbretter item.trinitite.name=Trinitit item.nuclear_waste.name=Atommüll item.waste_uranium.name=Erschöpfter Urankernbrennstoff +item.waste_thorium.name=Erschöpfter Thoriumkernbrennstoff item.waste_plutonium.name=Erschöpfter Plutoniumkernbrennstoff item.waste_mox.name=Erschöpfter MOX-Kernbrennstoff item.waste_schrabidium.name=Erschöpfter Schrabidiumkernbrennstoff item.scrap.name=Schrott item.ingot_uranium_fuel.name=Urankernbrennstoffbarren +item.ingot_thorium_fuel.name=Thoriumkernbrennstoffbarren item.ingot_plutonium_fuel.name=Plutoniumkernbrennstoffbarren item.ingot_mox_fuel.name=MOX-Kernbrennstoffbarren item.ingot_schrabidium_fuel.name=Schrabidiumkernbrennstoffbarren @@ -1678,6 +1684,8 @@ item.redcoil_capacitor.name=Rotspulenkondensator item.detonator.name=Fernzünder item.detonator_multi.name=Mehrfach-Fernzünder item.detonator_laser.name=Laserzünder +item.detonator_deadman.name=Totmannzünder +item.detonator_de.name=Totmannladung item.crate_caller.name=Nachschub-Requester item.bomb_caller.name=Luftschlag Zielmarker item.meteor_remote.name=Meteoritenkontroller diff --git a/assets/hbm/lang/en_US.lang b/assets/hbm/lang/en_US.lang index 3d91f1198..75500d239 100644 --- a/assets/hbm/lang/en_US.lang +++ b/assets/hbm/lang/en_US.lang @@ -509,7 +509,9 @@ item.fuse.name=Fuse tile.test_nuke.name=Test Nuke +item.ingot_th232.name=Th232 Ingot item.ingot_uranium.name=Uranium Ingot +item.ingot_u233.name=U233 Ingot item.ingot_u235.name=U235 Ingot item.ingot_u238.name=U238 Ingot item.ingot_u238m2.name=Metastable U238-2 Ingot @@ -1093,6 +1095,8 @@ item.t45_kit.name=T45 Power Armor Kit item.euphemium_kit.name=Euphemium Kit item.solinium_kit.name=Solinium Kit item.hazmat_kit.name=Hazmat Kit +item.hazmat_red_kit.name=Advanced Hazmat Kit +item.hazmat_grey_kit.name=High-Performance Hazmat Kit tile.waste_earth.name=Dead Grass tile.waste_trinitite.name=Trinitite Ore @@ -1103,12 +1107,14 @@ tile.waste_planks.name=Charred Wooden Planks item.trinitite.name=Trinitite item.nuclear_waste.name=Nuclear Waste item.waste_uranium.name=Depleted Uranium Fuel +item.waste_thorium.name=Depleted Thorium Fuel item.waste_plutonium.name=Depleted Plutonium Fuel item.waste_mox.name=Depleted MOX Fuel item.waste_schrabidium.name=Depleted Schrabidium Fuel item.scrap.name=Scrap item.ingot_uranium_fuel.name=Ingot of Uranium Fuel +item.ingot_thorium_fuel.name=Ingot of Thorium Fuel item.ingot_plutonium_fuel.name=Ingot of Plutonium Fuel item.ingot_mox_fuel.name=Ingot of MOX Fuel item.ingot_schrabidium_fuel.name=Ingot of Schrabidium Fuel @@ -1678,6 +1684,8 @@ item.redcoil_capacitor.name=Redcoil Capacitor item.detonator.name=Detonator item.detonator_multi.name=Multi Detonator item.detonator_laser.name=Laser Detonator +item.detonator_deadman.name=Dead Man's Detonator +item.detonator_de.name=Dead Man's Explosive item.crate_caller.name=Supply Drop Requester item.bomb_caller.name=Airstrike Designator item.meteor_remote.name=Meteorite Remote diff --git a/assets/hbm/textures/items/detonator_de.png b/assets/hbm/textures/items/detonator_de.png new file mode 100644 index 000000000..00429eff3 Binary files /dev/null and b/assets/hbm/textures/items/detonator_de.png differ diff --git a/assets/hbm/textures/items/detonator_deadman.png b/assets/hbm/textures/items/detonator_deadman.png new file mode 100644 index 000000000..cd7e81f6d Binary files /dev/null and b/assets/hbm/textures/items/detonator_deadman.png differ diff --git a/assets/hbm/textures/items/hazmat_grey_kit.png b/assets/hbm/textures/items/hazmat_grey_kit.png new file mode 100644 index 000000000..0a8cffdff Binary files /dev/null and b/assets/hbm/textures/items/hazmat_grey_kit.png differ diff --git a/assets/hbm/textures/items/hazmat_red_kit.png b/assets/hbm/textures/items/hazmat_red_kit.png new file mode 100644 index 000000000..8cca7bf3e Binary files /dev/null and b/assets/hbm/textures/items/hazmat_red_kit.png differ diff --git a/assets/hbm/textures/items/ingot_th232.png b/assets/hbm/textures/items/ingot_th232.png new file mode 100644 index 000000000..9ef1ba0a6 Binary files /dev/null and b/assets/hbm/textures/items/ingot_th232.png differ diff --git a/assets/hbm/textures/items/ingot_thorium_fuel.png b/assets/hbm/textures/items/ingot_thorium_fuel.png new file mode 100644 index 000000000..5c78f43f1 Binary files /dev/null and b/assets/hbm/textures/items/ingot_thorium_fuel.png differ diff --git a/assets/hbm/textures/items/ingot_u233.png b/assets/hbm/textures/items/ingot_u233.png new file mode 100644 index 000000000..dca9de1a6 Binary files /dev/null and b/assets/hbm/textures/items/ingot_u233.png differ diff --git a/assets/hbm/textures/items/syringe_ultra.png b/assets/hbm/textures/items/syringe_ultra.png new file mode 100644 index 000000000..27bdbd6ae Binary files /dev/null and b/assets/hbm/textures/items/syringe_ultra.png differ diff --git a/assets/hbm/textures/items/waste_thorium.png b/assets/hbm/textures/items/waste_thorium.png new file mode 100644 index 000000000..c05c098d0 Binary files /dev/null and b/assets/hbm/textures/items/waste_thorium.png differ diff --git a/com/hbm/blocks/generic/BlockCrate.java b/com/hbm/blocks/generic/BlockCrate.java index 2c98a533d..a5580970f 100644 --- a/com/hbm/blocks/generic/BlockCrate.java +++ b/com/hbm/blocks/generic/BlockCrate.java @@ -216,12 +216,14 @@ public class BlockCrate extends BlockFalling { //Red Crate BlockCrate.addToListWithWeight(redList, ModItems.mysteryshovel, 1); BlockCrate.addToListWithWeight(redList, ModItems.gun_revolver_pip, 1); + BlockCrate.addToListWithWeight(redList, ModItems.gun_revolver_blackjack, 1); BlockCrate.addToListWithWeight(redList, ModItems.clip_revolver_pip, 1); BlockCrate.addToListWithWeight(redList, ModItems.gun_calamity_dual, 1); BlockCrate.addToListWithWeight(redList, ModItems.gun_b92, 1); BlockCrate.addToListWithWeight(redList, ModItems.weaponized_starblaster_cell, 1); BlockCrate.addToListWithWeight(redList, ModItems.battery_spark, 1); BlockCrate.addToListWithWeight(redList, ModItems.bottle_sparkle, 1); + BlockCrate.addToListWithWeight(redList, ModItems.bottle_rad, 1); BlockCrate.addToListWithWeight(redList, ModItems.missile_taint, 1); BlockCrate.addToListWithWeight(redList, ModItems.flame_pony, 1); BlockCrate.addToListWithWeight(redList, ModItems.burnt_bark, 1); diff --git a/com/hbm/inventory/gui/GUIReactorControl.java b/com/hbm/inventory/gui/GUIReactorControl.java index 306e15539..2980e448d 100644 --- a/com/hbm/inventory/gui/GUIReactorControl.java +++ b/com/hbm/inventory/gui/GUIReactorControl.java @@ -1,5 +1,6 @@ package com.hbm.inventory.gui; +import org.lwjgl.input.Mouse; import org.lwjgl.opengl.GL11; import com.hbm.inventory.container.ContainerReactorControl; @@ -100,6 +101,8 @@ public class GUIReactorControl extends GuiInfoContainer { this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 4210752); this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752); + + this.fontRendererObj.drawString("Rods: " + control.rods + "%", 8, 40, 4210752); } @Override @@ -192,4 +195,69 @@ public class GUIReactorControl extends GuiInfoContainer { drawTexturedModalRect(guiLeft + 25, guiTop + 16, 194, 18, 18, 18); } } + + protected void keyTyped(char ch, int i) + { + super.keyTyped(ch, i); + + switch(ch) { + case '0': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 0, 0)); break; + case '1': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 10, 0)); break; + case '2': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 20, 0)); break; + case '3': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 30, 0)); break; + case '4': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 40, 0)); break; + case '5': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 50, 0)); break; + case '6': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 60, 0)); break; + case '7': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 70, 0)); break; + case '8': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 80, 0)); break; + case '9': + mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, 90, 0)); break; + } + + } + + public void handleMouseInput() + { + super.handleMouseInput(); + int i = Mouse.getEventDWheel(); + + if (i > 0) + { + i = 1; + } + + if (i < 0) + { + i = -1; + } + + int rods = control.rods + i; + + if(rods < 0) + rods = 0; + + if(rods > 100) + rods = 100; + + PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(control.xCoord, control.yCoord, control.zCoord, rods, 0)); + } } diff --git a/com/hbm/inventory/gui/GUIReactorMultiblock.java b/com/hbm/inventory/gui/GUIReactorMultiblock.java index 5a997d9b8..4380c5209 100644 --- a/com/hbm/inventory/gui/GUIReactorMultiblock.java +++ b/com/hbm/inventory/gui/GUIReactorMultiblock.java @@ -58,7 +58,10 @@ public class GUIReactorMultiblock extends GuiInfoContainer { case SCHRABIDIUM: fuel = "Schrabidium"; break; - case UNKNOWN: + case THORIUM: + fuel = "Thorium"; + break; + default: fuel = "ERROR"; break; } diff --git a/com/hbm/items/ModItems.java b/com/hbm/items/ModItems.java index 9497c4c9c..d70e548b9 100644 --- a/com/hbm/items/ModItems.java +++ b/com/hbm/items/ModItems.java @@ -38,8 +38,10 @@ public class ModItems { public static Item test_chestplate; public static Item test_leggings; public static Item test_boots; - + + public static Item ingot_th232; public static Item ingot_uranium; + public static Item ingot_u233; public static Item ingot_u235; public static Item ingot_u238; public static Item ingot_u238m2; @@ -63,6 +65,7 @@ public class ModItems { public static Item ingot_uranium_fuel; public static Item ingot_mox_fuel; public static Item ingot_schrabidium_fuel; + public static Item ingot_thorium_fuel; public static Item nugget_uranium_fuel; public static Item nugget_plutonium_fuel; public static Item nugget_mox_fuel; @@ -677,6 +680,7 @@ public class ModItems { public static Item rod_dual_waste; public static Item rod_quad_waste; public static Item waste_uranium; + public static Item waste_thorium; public static Item waste_plutonium; public static Item waste_mox; public static Item waste_schrabidium; @@ -1268,6 +1272,8 @@ public class ModItems { public static Item detonator; public static Item detonator_multi; public static Item detonator_laser; + public static Item detonator_deadman; + public static Item detonator_de; public static Item crate_caller; public static Item bomb_caller; public static Item meteor_remote; @@ -1442,7 +1448,9 @@ public class ModItems { test_nuke_tier1_target = new Item().setUnlocalizedName("test_nuke_tier1_target").setMaxStackSize(1).setCreativeTab(null).setTextureName(RefStrings.MODID + ":test_nuke_tier1_target"); test_nuke_tier2_target = new Item().setUnlocalizedName("test_nuke_tier2_target").setMaxStackSize(1).setCreativeTab(null).setTextureName(RefStrings.MODID + ":test_nuke_tier2_target"); + ingot_th232 = new Item().setUnlocalizedName("ingot_th232").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_th232"); ingot_uranium = new ItemRadioactive().setUnlocalizedName("ingot_uranium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_uranium"); + ingot_u233 = new ItemRadioactive().setUnlocalizedName("ingot_u233").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_u233"); ingot_u235 = new ItemRadioactive().setUnlocalizedName("ingot_u235").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_u235"); ingot_u238 = new ItemRadioactive().setUnlocalizedName("ingot_u238").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_u238"); ingot_u238m2 = new ItemUnstable(350, 200).setUnlocalizedName("ingot_u238m2").setCreativeTab(null).setTextureName(RefStrings.MODID + ":ingot_u238m2"); @@ -1458,6 +1466,7 @@ public class ModItems { ingot_plutonium_fuel = new ItemRadioactive().setUnlocalizedName("ingot_plutonium_fuel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_plutonium_fuel"); ingot_mox_fuel = new ItemRadioactive().setUnlocalizedName("ingot_mox_fuel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_mox_fuel"); ingot_schrabidium_fuel = new ItemRadioactive().setUnlocalizedName("ingot_schrabidium_fuel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_schrabidium_fuel"); + ingot_thorium_fuel = new ItemRadioactive().setUnlocalizedName("ingot_thorium_fuel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":ingot_thorium_fuel"); nugget_uranium_fuel = new ItemRadioactive().setUnlocalizedName("nugget_uranium_fuel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":nugget_uranium_fuel"); nugget_plutonium_fuel = new ItemRadioactive().setUnlocalizedName("nugget_plutonium_fuel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":nugget_plutonium_fuel"); nugget_mox_fuel = new ItemRadioactive().setUnlocalizedName("nugget_mox_fuel").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":nugget_mox_fuel"); @@ -2031,6 +2040,7 @@ public class ModItems { trinitite = new ItemCustomLore().setUnlocalizedName("trinitite").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":trinitite_new"); nuclear_waste = new ItemCustomLore().setUnlocalizedName("nuclear_waste").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":nuclear_waste"); waste_uranium = new ItemCustomLore().setUnlocalizedName("waste_uranium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":waste_uranium"); + waste_thorium = new ItemCustomLore().setUnlocalizedName("waste_thorium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":waste_thorium"); waste_plutonium = new ItemCustomLore().setUnlocalizedName("waste_plutonium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":waste_plutonium"); waste_mox = new ItemCustomLore().setUnlocalizedName("waste_mox").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":waste_mox"); waste_schrabidium = new ItemCustomLore().setUnlocalizedName("waste_schrabidium").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":waste_schrabidium"); @@ -2462,6 +2472,8 @@ public class ModItems { detonator = new ItemDetonator().setUnlocalizedName("detonator").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator"); detonator_multi = new ItemMultiDetonator().setUnlocalizedName("detonator_multi").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator_multi"); detonator_laser = new ItemLaserDetonator().setUnlocalizedName("detonator_laser").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator_laser"); + detonator_deadman = new ItemDrop().setUnlocalizedName("detonator_deadman").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator_deadman"); + detonator_de = new ItemDrop().setUnlocalizedName("detonator_de").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator_de"); crate_caller = new ItemCrateCaller().setUnlocalizedName("crate_caller").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":crate_caller"); bomb_caller = new ItemBombCaller().setUnlocalizedName("bomb_caller").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":bomb_caller"); meteor_remote = new ItemMeteorRemote().setUnlocalizedName("meteor_remote").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":meteor_remote"); @@ -2819,7 +2831,9 @@ public class ModItems { GameRegistry.registerItem(test_nuke_tier2_target, test_nuke_tier2_target.getUnlocalizedName()); //Ingots + GameRegistry.registerItem(ingot_th232, ingot_th232.getUnlocalizedName()); GameRegistry.registerItem(ingot_uranium, ingot_uranium.getUnlocalizedName()); + GameRegistry.registerItem(ingot_u233, ingot_u233.getUnlocalizedName()); GameRegistry.registerItem(ingot_u235, ingot_u235.getUnlocalizedName()); GameRegistry.registerItem(ingot_u238, ingot_u238.getUnlocalizedName()); GameRegistry.registerItem(ingot_u238m2, ingot_u238m2.getUnlocalizedName()); @@ -2844,6 +2858,7 @@ public class ModItems { GameRegistry.registerItem(ingot_combine_steel, ingot_combine_steel.getUnlocalizedName()); GameRegistry.registerItem(ingot_solinium, ingot_solinium.getUnlocalizedName()); GameRegistry.registerItem(ingot_uranium_fuel, ingot_uranium_fuel.getUnlocalizedName()); + GameRegistry.registerItem(ingot_thorium_fuel, ingot_thorium_fuel.getUnlocalizedName()); GameRegistry.registerItem(ingot_plutonium_fuel, ingot_plutonium_fuel.getUnlocalizedName()); GameRegistry.registerItem(ingot_mox_fuel, ingot_mox_fuel.getUnlocalizedName()); GameRegistry.registerItem(ingot_schrabidium_fuel, ingot_schrabidium_fuel.getUnlocalizedName()); @@ -3569,6 +3584,7 @@ public class ModItems { GameRegistry.registerItem(scrap, scrap.getUnlocalizedName()); GameRegistry.registerItem(waste_uranium, waste_uranium.getUnlocalizedName()); + GameRegistry.registerItem(waste_thorium, waste_thorium.getUnlocalizedName()); GameRegistry.registerItem(waste_plutonium, waste_plutonium.getUnlocalizedName()); GameRegistry.registerItem(waste_mox, waste_mox.getUnlocalizedName()); GameRegistry.registerItem(waste_schrabidium, waste_schrabidium.getUnlocalizedName()); @@ -4054,6 +4070,8 @@ public class ModItems { GameRegistry.registerItem(detonator, detonator.getUnlocalizedName()); GameRegistry.registerItem(detonator_multi, detonator_multi.getUnlocalizedName()); GameRegistry.registerItem(detonator_laser, detonator_laser.getUnlocalizedName()); + GameRegistry.registerItem(detonator_deadman, detonator_deadman.getUnlocalizedName()); + GameRegistry.registerItem(detonator_de, detonator_de.getUnlocalizedName()); GameRegistry.registerItem(crate_caller, crate_caller.getUnlocalizedName()); GameRegistry.registerItem(bomb_caller, bomb_caller.getUnlocalizedName()); GameRegistry.registerItem(meteor_remote, meteor_remote.getUnlocalizedName()); diff --git a/com/hbm/items/special/ItemDrop.java b/com/hbm/items/special/ItemDrop.java index 0ef839b4e..04d9d4102 100644 --- a/com/hbm/items/special/ItemDrop.java +++ b/com/hbm/items/special/ItemDrop.java @@ -10,6 +10,7 @@ import com.hbm.entity.logic.EntityNukeExplosionAdvanced; import com.hbm.entity.logic.EntityNukeExplosionMK3; import com.hbm.explosion.ExplosionChaos; import com.hbm.explosion.ExplosionLarge; +import com.hbm.interfaces.IBomb; import com.hbm.items.ModItems; import com.hbm.main.MainRegistry; @@ -17,15 +18,51 @@ import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; +import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.util.ChatComponentText; +import net.minecraft.world.World; public class ItemDrop extends Item { @Override public boolean onEntityItemUpdate(EntityItem entityItem) { if (entityItem != null) { - if (entityItem.onGround) { + + ItemStack stack = entityItem.getEntityItem(); - ItemStack stack = entityItem.getEntityItem(); + if (stack.getItem() != null && stack.getItem() == ModItems.detonator_deadman) { + if (!entityItem.worldObj.isRemote) { + + if(stack.stackTagCompound != null) { + + int x = stack.stackTagCompound.getInteger("x"); + int y = stack.stackTagCompound.getInteger("y"); + int z = stack.stackTagCompound.getInteger("z"); + + if(entityItem.worldObj.getBlock(x, y, z) instanceof IBomb) + { + if(!entityItem.worldObj.isRemote) + { + ((IBomb)entityItem.worldObj.getBlock(x, y, z)).explode(entityItem.worldObj, x, y, z); + } + } + } + + entityItem.worldObj.createExplosion(entityItem, entityItem.posX, entityItem.posY, + entityItem.posZ, 0.0F, true); + entityItem.setDead(); + } + } + if (stack.getItem() != null && stack.getItem() == ModItems.detonator_de) { + if (!entityItem.worldObj.isRemote) { + entityItem.worldObj.createExplosion(entityItem, entityItem.posX, entityItem.posY, + entityItem.posZ, 15.0F, true); + } + + entityItem.setDead(); + } + + if (entityItem.onGround) { if (stack.getItem() != null && stack.getItem() == ModItems.cell_antimatter) { if (!entityItem.worldObj.isRemote) { @@ -142,26 +179,26 @@ public class ItemDrop extends Item { @Override public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) { - if (itemstack.getItem() != null && itemstack.getItem() == ModItems.cell_antimatter) { + if (this == ModItems.cell_antimatter) { list.add("Warning: Exposure to matter will"); list.add("lead to violent annihilation!"); } - if (itemstack.getItem() != null && itemstack.getItem() == ModItems.pellet_antimatter) { + if (this == ModItems.pellet_antimatter) { list.add("Very heavy antimatter cluster."); list.add("Gets rid of black holes."); } - if (itemstack.getItem() != null && itemstack.getItem() == ModItems.cell_anti_schrabidium) { + if (this == ModItems.cell_anti_schrabidium) { list.add("Warning: Exposure to matter will"); list.add("create a fólkvangr field!"); } - if (itemstack.getItem() != null && itemstack.getItem() == ModItems.singularity) { + if (this == ModItems.singularity) { list.add("You may be asking:"); list.add("\"But HBM, a manifold with an undefined"); list.add("state of spacetime? How is this possible?\""); list.add("Long answer short:"); list.add("\"I have no idea!\""); } - if (itemstack.getItem() != null && itemstack.getItem() == ModItems.singularity_counter_resonant) { + if (this == ModItems.singularity_counter_resonant) { list.add("Nullifies resonance of objects in"); list.add("non-euclidean space, creates variable"); list.add("gravity well. Spontaneously spawns"); @@ -169,19 +206,63 @@ public class ItemDrop extends Item { list.add("appear near you, do not look directly"); list.add("at it."); } - if (itemstack.getItem() != null && itemstack.getItem() == ModItems.singularity_super_heated) { + if (this == ModItems.singularity_super_heated) { list.add("Continuously heats up matter by"); list.add("resonating every planck second."); list.add("Tends to catch fire or to create"); list.add("small plamsa arcs. Not edible."); } - if (itemstack.getItem() != null && itemstack.getItem() == ModItems.black_hole) { + if (this == ModItems.black_hole) { list.add("Contains a regular singularity"); list.add("in the center. Large enough to"); list.add("stay stable. It's not the end"); list.add("of the world as we know it,"); list.add("and I don't feel fine."); } + if (this == ModItems.detonator_deadman) { + list.add("Shift right-click to set position,"); + list.add("drop to detonate!"); + if(itemstack.getTagCompound() == null) + { + list.add("No position set!"); + } else { + list.add("Set pos to " + itemstack.stackTagCompound.getInteger("x") + ", " + itemstack.stackTagCompound.getInteger("y") + ", " + itemstack.stackTagCompound.getInteger("z")); + } + } + if (this == ModItems.detonator_de) { + list.add("Explodes when dropped!"); + } } + + @Override + public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int p_77648_7_, float p_77648_8_, float p_77648_9_, float p_77648_10_) + { + if(this != ModItems.detonator_deadman) { + return super.onItemUse(stack, player, world, x, y, z, p_77648_7_, p_77648_8_, p_77648_9_, p_77648_10_); + } + + if(stack.stackTagCompound == null) + { + stack.stackTagCompound = new NBTTagCompound(); + } + + if(player.isSneaking()) + { + stack.stackTagCompound.setInteger("x", x); + stack.stackTagCompound.setInteger("y", y); + stack.stackTagCompound.setInteger("z", z); + + if(world.isRemote) + { + player.addChatMessage(new ChatComponentText("Position set!")); + } + + world.playSoundAtEntity(player, "hbm:item.techBoop", 2.0F, 1.0F); + + return true; + } + + return false; + } } diff --git a/com/hbm/items/special/ItemRadioactive.java b/com/hbm/items/special/ItemRadioactive.java index fb5a9c3e6..e7be5d63c 100644 --- a/com/hbm/items/special/ItemRadioactive.java +++ b/com/hbm/items/special/ItemRadioactive.java @@ -44,7 +44,7 @@ public class ItemRadioactive extends Item { this == ModItems.pellet_neptunium || this == ModItems.pellet_schrabidium) { //Library.applyRadiation(living, 80, 24, 60, 19); - Library.applyRadData(living, 100F/20F * mod); + Library.applyRadData(living, 50F/20F * mod); } //Strong @@ -83,7 +83,7 @@ public class ItemRadioactive extends Item { this == ModItems.waste_mox || this == ModItems.waste_schrabidium) { //Library.applyRadiation(living, 60, 19, 40, 14); - Library.applyRadData(living, 25F/20F * mod); + Library.applyRadData(living, 5F/20F * mod); } //Strong Nuggets @@ -102,9 +102,10 @@ public class ItemRadioactive extends Item { this == ModItems.rod_mox_fuel || this == ModItems.rod_uranium_fuel_depleted || this == ModItems.rod_plutonium_fuel_depleted || - this == ModItems.rod_mox_fuel_depleted) { + this == ModItems.rod_mox_fuel_depleted || + this == ModItems.ingot_thorium_fuel) { //Library.applyRadiation(living, 45, 19, 30, 14); - Library.applyRadData(living, 15F/20F * mod); + Library.applyRadData(living, 3.5F/20F * mod); } //Medium @@ -123,7 +124,7 @@ public class ItemRadioactive extends Item { this == ModItems.tsar_core || this == ModItems.trinitite) { //Library.applyRadiation(living, 30, 14, 15, 9); - Library.applyRadData(living, 10F/20F * mod); + Library.applyRadData(living, 2.5F/20F * mod); } //Medium Nuggets @@ -134,9 +135,10 @@ public class ItemRadioactive extends Item { this == ModItems.rod_neptunium || this == ModItems.rod_pu238 || this == ModItems.rod_plutonium || - this == ModItems.pellet_rtg_weak) { + this == ModItems.pellet_rtg_weak || + this == ModItems.waste_thorium) { //Library.applyRadiation(living, 20, 14, 5, 9); - Library.applyRadData(living, 5F/20F * mod); + Library.applyRadData(living, 1F/20F * mod); } //Weak @@ -150,7 +152,7 @@ public class ItemRadioactive extends Item { this == ModItems.rod_quad_pu238 || this == ModItems.rod_dual_pu238) { //Library.applyRadiation(living, 20, 4, 5, 0); - Library.applyRadData(living, 5F/20F * mod); + Library.applyRadData(living, 0.5F/20F * mod); } //Weak Nuggets @@ -161,7 +163,7 @@ public class ItemRadioactive extends Item { this == ModItems.rod_u238 || this == ModItems.powder_yellowcake) { //Library.applyRadiation(living, 10, 4, 0, 0); - Library.applyRadData(living, 1F/20F * mod); + Library.applyRadData(living, 0.25F/20F * mod); } //Tritium @@ -171,7 +173,7 @@ public class ItemRadioactive extends Item { this == ModItems.rod_dual_tritium || this == ModItems.rod_quad_tritium) { //Library.applyRadiation(living, 10, 4, 0, 0); - Library.applyRadData(living, 2.5F/20F * mod); + Library.applyRadData(living, 0.75F/20F * mod); } //Powder @@ -179,7 +181,7 @@ public class ItemRadioactive extends Item { if (this == ModItems.powder_neptunium || this == ModItems.powder_plutonium) { //Library.applyRadiation(living, 60, 19, 45, 14); - Library.applyRadData(living, 10F/20F * mod); + Library.applyRadData(living, 2F/20F * mod); if(living instanceof EntityPlayer && !Library.checkForHazmat((EntityPlayer)living)) living.setFire(5); @@ -187,7 +189,7 @@ public class ItemRadioactive extends Item { if (this == ModItems.powder_uranium) { //Library.applyRadiation(living, 20, 4, 0, 0); - Library.applyRadData(living, 5F/20F * mod); + Library.applyRadData(living, 1F/20F * mod); if(living instanceof EntityPlayer && !Library.checkForHazmat((EntityPlayer)living)) living.setFire(5); @@ -217,7 +219,7 @@ public class ItemRadioactive extends Item { living.addPotionEffect(new PotionEffect(Potion.blindness.id, 60 * 20, 0)); //Library.applyRadiation(living, 100, 29, 75, 24); - Library.applyRadData(living, 35F/20F * mod); + Library.applyRadData(living, 7.5F/20F * mod); } if (this == ModItems.nugget_schrabidium || @@ -226,20 +228,20 @@ public class ItemRadioactive extends Item { this == ModItems.nugget_hes || this == ModItems.nugget_les) { //living.addPotionEffect(new PotionEffect(Potion.blindness.id, 60 * 20, 0)); - Library.applyRadData(living, 20F/20F * mod); + Library.applyRadData(living, 5F/20F * mod); //Library.applyRadiation(living, 75, 29, 60, 24); } if (this == ModItems.plate_schrabidium || this == ModItems.wire_schrabidium) { //living.addPotionEffect(new PotionEffect(Potion.blindness.id, 60 * 20, 0)); - Library.applyRadData(living, 25F/20F * mod); + Library.applyRadData(living, 7.5F/20F * mod); //Library.applyRadiation(living, 80, 29, 60, 24); } if (this == ModItems.powder_schrabidium) { //Library.applyRadiation(living, 100, 29, 75, 24); - Library.applyRadData(living, 35F/20F * mod); + Library.applyRadData(living, 7.5F/20F * mod); if(living instanceof EntityPlayer && !Library.checkForHazmat((EntityPlayer)living)) { living.addPotionEffect(new PotionEffect(Potion.blindness.id, 60 * 20, 0)); diff --git a/com/hbm/items/tool/ItemReactorSensor.java b/com/hbm/items/tool/ItemReactorSensor.java index 5c619c14c..17a95c067 100644 --- a/com/hbm/items/tool/ItemReactorSensor.java +++ b/com/hbm/items/tool/ItemReactorSensor.java @@ -39,6 +39,36 @@ public class ItemReactorSensor extends Item { } + if (b == ModBlocks.reactor_hatch || b == ModBlocks.reactor_ejector + || b == ModBlocks.reactor_inserter) { + + int meta = world.getBlockMetadata(x, y, z); + + switch(meta) { + case 2: z += 2; break; + case 3: z -= 2; break; + case 4: x += 2; break; + case 5: x -= 2; break; + } + } + + b = world.getBlock(x, y, z); + + if (b == ModBlocks.reactor_computer) { + + if (stack.stackTagCompound == null) + stack.stackTagCompound = new NBTTagCompound(); + + stack.stackTagCompound.setInteger("x", x); + stack.stackTagCompound.setInteger("y", y); + stack.stackTagCompound.setInteger("z", z); + + world.playSoundAtEntity(player, "hbm:item.techBoop", 1.0F, 1.0F); + + player.swingItem(); + return true; + } + return false; } diff --git a/com/hbm/lib/RefStrings.java b/com/hbm/lib/RefStrings.java index 0845e7fad..3abd50da8 100644 --- a/com/hbm/lib/RefStrings.java +++ b/com/hbm/lib/RefStrings.java @@ -3,7 +3,7 @@ package com.hbm.lib; public class RefStrings { public static final String MODID = "hbm"; public static final String NAME = "Hbm's Nuclear Tech Mod"; - public static final String VERSION = "1.0.27 BETA (2981)"; + public static final String VERSION = "1.0.27 BETA (3000)"; //HBM's Beta Naming Convention: //V T (X-Y-Z) //V -> next release version diff --git a/com/hbm/main/CraftingManager.java b/com/hbm/main/CraftingManager.java index 27e3e3129..247f2de1c 100644 --- a/com/hbm/main/CraftingManager.java +++ b/com/hbm/main/CraftingManager.java @@ -600,6 +600,8 @@ public class CraftingManager { GameRegistry.addShapelessRecipe(new ItemStack(ModItems.detonator_multi, 1), new Object[] { ModItems.detonator, ModItems.circuit_targeting_tier3 }); GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.detonator_laser, 1), new Object[] { "RRD", "PIC", " P", 'P', "plateSteel", 'R', Items.redstone, 'C', ModItems.circuit_targeting_tier3, 'D', "gemDiamond", 'I', "ingotSteel" })); GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.detonator_laser, 1), new Object[] { "RRD", "PIC", " P", 'P', "plateSteel", 'R', Items.redstone, 'C', ModItems.circuit_targeting_tier3, 'D', "gemEmerald", 'I', "ingotSteel" })); + GameRegistry.addShapelessRecipe(new ItemStack(ModItems.detonator_deadman, 1), new Object[] { ModItems.detonator, ModItems.defuser, ModItems.ducttape }); + GameRegistry.addRecipe(new ItemStack(ModItems.detonator_de, 1), new Object[] { "T", "D", "T", 'T', Blocks.tnt, 'D', ModItems.detonator_deadman }); GameRegistry.addRecipe(new ItemStack(ModItems.bomb_caller, 1, 0), new Object[] { "TTT", "TRT", "TTT", 'T', Blocks.tnt, 'R', ModItems.detonator_laser }); GameRegistry.addRecipe(new ItemStack(ModItems.bomb_caller, 1, 1), new Object[] { "TTT", "TRT", "TTT", 'T', ModItems.grenade_gascan, 'R', ModItems.detonator_laser }); @@ -1320,6 +1322,9 @@ public class CraftingManager { //Temporary Crappy Recipes GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.gun_revolver_pip, 1), new Object[] { " G ", "SSP", " TI", 'G', "paneGlass", 'S', "plateSteel", 'P', ModItems.mechanism_revolver_2, 'T', ModItems.wire_tungsten, 'I', "ingotPolymer" })); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.gun_revolver_nopip, 1), new Object[] { "SSP", " TI", 'S', "plateSteel", 'P', ModItems.mechanism_revolver_2, 'T', ModItems.wire_tungsten, 'I', "ingotPolymer" })); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.gun_revolver_blackjack, 1), new Object[] { "SSP", " TI", 'S', "plateSteel", 'P', ModItems.mechanism_revolver_2, 'T', ModItems.wire_tungsten, 'I', "plankWood" })); + GameRegistry.addRecipe(new ItemStack(ModItems.gun_revolver_red, 1), new Object[] { "R ", " B", 'R', ModItems.key_red, 'B', ModItems.gun_revolver_blackjack }); //GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.gun_revolver_pip_ammo, 1), new Object[] { "S", "G", "C", 'S', "plateSteel", 'G', Items.gunpowder, 'C', "plateCopper" })); GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.plate_dineutronium, 4), new Object[] { "PIP", "IDI", "PIP", 'P', ModItems.powder_spark_mix, 'I', "ingotDineutronium", 'D', "ingotDesh" })); GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.plate_desh, 4), new Object[] { "PIP", "IDI", "PIP", 'P', ModItems.powder_polymer, 'I', "ingotDesh", 'D', "ingotDuraSteel" })); diff --git a/com/hbm/main/MainRegistry.java b/com/hbm/main/MainRegistry.java index fc1ba806d..51e420c85 100644 --- a/com/hbm/main/MainRegistry.java +++ b/com/hbm/main/MainRegistry.java @@ -1635,6 +1635,8 @@ public class MainRegistry TileEntityMachineReactorLarge.registerWasteEntry(60, ReactorFuelType.SCHRABIDIUM, ModItems.rod_empty, ModItems.rod_schrabidium_fuel_depleted); TileEntityMachineReactorLarge.registerWasteEntry(120, ReactorFuelType.SCHRABIDIUM, ModItems.rod_dual_empty, ModItems.rod_dual_schrabidium_fuel_depleted); TileEntityMachineReactorLarge.registerWasteEntry(240, ReactorFuelType.SCHRABIDIUM, ModItems.rod_quad_empty, ModItems.rod_quad_schrabidium_fuel_depleted); + + TileEntityMachineReactorLarge.registerFuelEntry(9, ReactorFuelType.THORIUM, ModItems.ingot_thorium_fuel); } @EventHandler diff --git a/com/hbm/packet/AuxButtonPacket.java b/com/hbm/packet/AuxButtonPacket.java index ff8efe723..04d6b14fb 100644 --- a/com/hbm/packet/AuxButtonPacket.java +++ b/com/hbm/packet/AuxButtonPacket.java @@ -153,6 +153,31 @@ public class AuxButtonPacket implements IMessage { reactor.tanks[2].setFill(fill); } } + + if (reac instanceof TileEntityMachineReactorLarge) { + TileEntityMachineReactorLarge reactor = (TileEntityMachineReactorLarge)reac; + + if(m.id == 0) { + reactor.rods = m.value; + } + + if(m.id == 2) { + FluidType type = FluidType.STEAM; + int fill = reactor.tanks[2].getFill(); + + switch(m.value) { + case 0: type = FluidType.STEAM; fill = (int)Math.floor(fill * 100); break; + case 1: type = FluidType.HOTSTEAM; fill = (int)Math.floor(fill / 10D); break; + case 2: type = FluidType.SUPERHOTSTEAM; fill = (int)Math.floor(fill / 10D); break; + } + + if(fill > reactor.tanks[2].getMaxFill()) + fill = reactor.tanks[2].getMaxFill(); + + reactor.tanks[2].setTankType(type); + reactor.tanks[2].setFill(fill); + } + } } if (te instanceof TileEntityMachineReactorLarge) { diff --git a/com/hbm/tileentity/machine/TileEntityMachineReactorLarge.java b/com/hbm/tileentity/machine/TileEntityMachineReactorLarge.java index f8fe17ac7..c6421a930 100644 --- a/com/hbm/tileentity/machine/TileEntityMachineReactorLarge.java +++ b/com/hbm/tileentity/machine/TileEntityMachineReactorLarge.java @@ -585,6 +585,9 @@ public class TileEntityMachineReactorLarge extends TileEntity case SCHRABIDIUM: waste = ModItems.waste_schrabidium; break; + case THORIUM: + waste = ModItems.waste_thorium; + break; default: waste = ModItems.waste_uranium; break; @@ -624,10 +627,15 @@ public class TileEntityMachineReactorLarge extends TileEntity if(chest.getStackInSlot(i) != null) { int cont = getFuelContent(chest.getStackInSlot(i).getItem(), type) * fuelMult; - if(cont > 0 && fuel + cont <= maxFuel && !chest.getStackInSlot(i).getItem().hasContainerItem()) { + if(cont > 0 && fuel + cont <= maxFuel) { + + Item container = chest.getStackInSlot(i).getItem().getContainerItem(); chest.decrStackSize(i, 1); fuel += cont; + + if(chest.getStackInSlot(i) == null && container != null) + chest.setInventorySlotContents(i, new ItemStack(container)); } } } @@ -637,11 +645,16 @@ public class TileEntityMachineReactorLarge extends TileEntity if(chest.getStackInSlot(i) != null) { int cont = getFuelContent(chest.getStackInSlot(i).getItem(), getFuelType(chest.getStackInSlot(i).getItem())) * fuelMult; - if(cont > 0 && fuel + cont <= maxFuel && !chest.getStackInSlot(i).getItem().hasContainerItem()) { + if(cont > 0 && fuel + cont <= maxFuel) { + + Item container = chest.getStackInSlot(i).getItem().getContainerItem(); type = getFuelType(chest.getStackInSlot(i).getItem()); chest.decrStackSize(i, 1); fuel += cont; + + if(chest.getStackInSlot(i) == null && container != null) + chest.setInventorySlotContents(i, new ItemStack(container)); } } } @@ -837,8 +850,9 @@ public class TileEntityMachineReactorLarge extends TileEntity } public enum ReactorFuelType { - + URANIUM(250000), + THORIUM(200000), PLUTONIUM(312500), MOX(250000), SCHRABIDIUM(2085000), diff --git a/com/hbm/tileentity/machine/TileEntityReactorControl.java b/com/hbm/tileentity/machine/TileEntityReactorControl.java index 23c5f77d4..69112b1e9 100644 --- a/com/hbm/tileentity/machine/TileEntityReactorControl.java +++ b/com/hbm/tileentity/machine/TileEntityReactorControl.java @@ -128,6 +128,7 @@ public class TileEntityReactorControl extends TileEntity implements ISidedInvent NBTTagList list = nbt.getTagList("items", 10); redstoned = nbt.getBoolean("red"); + lastRods = nbt.getInteger("lastRods"); slots = new ItemStack[getSizeInventory()]; @@ -148,6 +149,7 @@ public class TileEntityReactorControl extends TileEntity implements ISidedInvent NBTTagList list = new NBTTagList(); nbt.setBoolean("red", redstoned); + nbt.setInteger("lastRods", lastRods); for(int i = 0; i < slots.length; i++) { @@ -198,6 +200,7 @@ public class TileEntityReactorControl extends TileEntity implements ISidedInvent public boolean auto; public boolean isLinked; public boolean redstoned; + private int lastRods = 100; @Override public void updateEntity() { @@ -213,7 +216,7 @@ public class TileEntityReactorControl extends TileEntity implements ISidedInvent Block b = worldObj.getBlock(xCoord, yCoord, zCoord); - if(b == ModBlocks.machine_reactor_small) { + if(b == ModBlocks.machine_reactor_small || b == ModBlocks.reactor_computer) { linkX = xCoord; linkY = yCoord; linkZ = zCoord; @@ -269,6 +272,54 @@ public class TileEntityReactorControl extends TileEntity implements ISidedInvent reactor.retracting = true; } + } else if(linkY >= 0 && worldObj.getTileEntity(linkX, linkY, linkZ) instanceof TileEntityMachineReactorLarge) { + TileEntityMachineReactorLarge reactor = (TileEntityMachineReactorLarge)worldObj.getTileEntity(linkX, linkY, linkZ); + + hullHeat = reactor.hullHeat; + coreHeat = reactor.coreHeat; + fuel = reactor.fuel * 100 / reactor.maxFuel; + water = reactor.tanks[0].getFill(); + cool = reactor.tanks[1].getFill(); + steam = reactor.tanks[2].getFill(); + maxWater = reactor.tanks[0].getMaxFill(); + maxCool = reactor.tanks[1].getMaxFill(); + maxSteam = reactor.tanks[2].getMaxFill(); + rods = reactor.rods; + maxRods = reactor.rodsMax; + isOn = reactor.rods > 0; + isLinked = true; + + switch(reactor.tanks[2].getTankType()) { + case HOTSTEAM: + compression = 1; break; + case SUPERHOTSTEAM: + compression = 2; break; + default: + compression = 0; break; + } + + if(rods != 0) + lastRods = rods; + + if(!redstoned) { + if(worldObj.isBlockIndirectlyGettingPowered(xCoord, yCoord, zCoord)) { + redstoned = true; + + if(rods == 0) + rods = lastRods; + else + rods = 0; + } + } else { + if(!worldObj.isBlockIndirectlyGettingPowered(xCoord, yCoord, zCoord)) { + redstoned = false; + } + } + + if(auto && (water < 100 || cool < 100 || coreHeat > (50000 * 0.95)) && fuel > 0) { + reactor.rods = 0; + } + } else { hullHeat = 0; coreHeat = 0;