Updated initial content registration

This commit is contained in:
Calclavia 2014-07-14 16:20:02 -04:00
parent 020e13c7f8
commit 15ac700074
55 changed files with 392 additions and 692 deletions

View file

@ -13,7 +13,7 @@ public class BlockColorGlass extends BlockColored
public BlockColorGlass(String name)
{
super(name, Settings.CONFIGURATION.getBlock(name, Settings.getNextBlockID()).getInt(), Material.glass);
super(name, Settings.config.getBlock(name, Settings.getNextBlockID()).getInt(), Material.glass);
this.setCreativeTab(CreativeTabs.tabDecorations);
this.setHardness(.5f);
this.setResistance(.5f);

View file

@ -13,7 +13,7 @@ public class BlockColorSand extends BlockColored
{
public BlockColorSand()
{
super("colorSand", Settings.CONFIGURATION.getBlock("colorSand", Settings.getNextBlockID()).getInt(), Material.sand);
super("colorSand", Settings.config.getBlock("colorSand", Settings.getNextBlockID()).getInt(), Material.sand);
this.setCreativeTab(CreativeTabs.tabDecorations);
this.setHardness(1f);
this.setResistance(.5f);

View file

@ -87,7 +87,7 @@ public class ResonantInduction
MinecraftForge.EVENT_BUS.register(new LinkEventHandler());
MinecraftForge.EVENT_BUS.register(new FluidEventHandler());
Settings.CONFIGURATION.load();
Settings.config.load();
blockMulti = new BlockMulti(Settings.getNextBlockID()).setPacketType(PACKET_TILE);
@ -105,7 +105,7 @@ public class ResonantInduction
GameRegistry.registerBlock(blockFluidMixture, blockFluidMixture.getUnlocalizedName());
GameRegistry.registerTileEntity(TileFluidMixture.class, blockFluidMixture.getUnlocalizedName());
Settings.CONFIGURATION.save();
Settings.config.save();
}
@EventHandler

View file

@ -17,7 +17,7 @@ public class ItemInstaHole extends Item
public ItemInstaHole()
{
super(Settings.CONFIGURATION.getItem("InstaHole", Settings.getNextItemID()).getInt());
super(Settings.config.getItem("InstaHole", Settings.getNextItemID()).getInt());
this.setUnlocalizedName("InstaHole");
this.setCreativeTab(CreativeTabs.tabTools);
}

View file

@ -26,7 +26,7 @@ public class BlockBase extends BlockAdvanced
public BlockBase(int id, String name, Material material)
{
super(Settings.CONFIGURATION.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), material);
super(Settings.config.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), material);
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setUnlocalizedName(Reference.PREFIX + name);
this.setTextureName(Reference.PREFIX + name);

View file

@ -20,7 +20,7 @@ public class BlockIOBase extends BlockSidedIO
{
public BlockIOBase(String name, int id)
{
super(Settings.CONFIGURATION.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), Material.piston);
super(Settings.config.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), Material.piston);
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setUnlocalizedName(Reference.PREFIX + name);
this.setTextureName(Reference.PREFIX + name);

View file

@ -27,7 +27,7 @@ public class BlockMachine extends BlockTile
public BlockMachine(int id, String name, Material material)
{
super(Settings.CONFIGURATION.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), material);
super(Settings.config.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), material);
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setUnlocalizedName(Reference.PREFIX + name);
this.setTextureName(Reference.PREFIX + name);

View file

@ -18,7 +18,7 @@ public class BlockRotatableBase extends BlockRotatable
{
public BlockRotatableBase(String name, int id)
{
super(Settings.CONFIGURATION.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), UniversalElectricity.machine);
super(Settings.config.get(Configuration.CATEGORY_BLOCK, name, id).getInt(id), UniversalElectricity.machine);
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setUnlocalizedName(Reference.PREFIX + name);
this.setTextureName(Reference.PREFIX + name);

View file

@ -15,7 +15,7 @@ public class ItemBase extends Item
{
public ItemBase(String name, int id)
{
super(Settings.CONFIGURATION.get(Configuration.CATEGORY_ITEM, name, id).getInt(id));
super(Settings.config.get(Configuration.CATEGORY_ITEM, name, id).getInt(id));
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setUnlocalizedName(Reference.PREFIX + name);
this.setTextureName(Reference.PREFIX + name);

View file

@ -14,7 +14,7 @@ public abstract class ItemMultipartBase extends JItemMultiPart
{
public ItemMultipartBase(String name, int id)
{
super(Settings.CONFIGURATION.get(Configuration.CATEGORY_ITEM, name, id).getInt(id));
super(Settings.config.get(Configuration.CATEGORY_ITEM, name, id).getInt(id));
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setUnlocalizedName(Reference.PREFIX + name);
this.setTextureName(Reference.PREFIX + name);

View file

@ -41,7 +41,7 @@ public class BlockGasOre extends Block implements IFluidBlock
public BlockGasOre()
{
super(Settings.CONFIGURATION.getBlock("GasBlock", Settings.getNextBlockID()).getInt(), gas);
super(Settings.config.getBlock("GasBlock", Settings.getNextBlockID()).getInt(), gas);
this.setUnlocalizedName("BlockGas");
this.setTickRandomly(true);
}

View file

@ -32,7 +32,7 @@ public class BlockOre extends Block implements IExtraBlockInfo
public BlockOre()
{
super(Settings.CONFIGURATION.getBlock("Ore", Settings.getNextBlockID()).getInt(), Material.rock);
super(Settings.config.getBlock("Ore", Settings.getNextBlockID()).getInt(), Material.rock);
this.setCreativeTab(CreativeTabs.tabBlock);
this.setUnlocalizedName(Reference.PREFIX + "Ore");
this.setHardness(2.5f);
@ -124,7 +124,7 @@ public class BlockOre extends Block implements IExtraBlockInfo
if (this.doWorldGen)
{
ItemStack stack = new ItemStack(RecipeLoader.blockOre, 1, this.ordinal());
return (OreGenReplaceStone) new OreGenReplaceStone(this.name, this.name + "Ore", stack, this.maxY, this.ammount, this.branch).enable(Settings.CONFIGURATION);
return (OreGenReplaceStone) new OreGenReplaceStone(this.name, this.name + "Ore", stack, this.maxY, this.ammount, this.branch).enable(Settings.config);
}
return null;
}

View file

@ -96,7 +96,7 @@ public class Electrical
{
NetworkRegistry.instance().registerGuiHandler(this, proxy);
Settings.CONFIGURATION.load();
Settings.config.load();
// Energy
itemPartWire = new ItemWire(Settings.getNextItemID());
@ -123,7 +123,7 @@ public class Electrical
GameRegistry.registerTileEntity(TileAdvancedFurnace.class, "ri_" + blockAdvancedFurnace.getUnlocalizedName());
}
Settings.CONFIGURATION.save();
Settings.config.save();
GameRegistry.registerItem(itemMultimeter, itemMultimeter.getUnlocalizedName());
GameRegistry.registerItem(itemTransformer, itemTransformer.getUnlocalizedName());
@ -155,7 +155,7 @@ public class Electrical
}
proxy.preInit();
Settings.CONFIGURATION.save();
Settings.config.save();
}
@EventHandler

View file

@ -40,7 +40,7 @@ public class ItemReadoutTools extends ItemBase
public ItemReadoutTools()
{
super(Settings.getNextItemID(), "DMTools", Settings.CONFIGURATION,Reference.PREFIX, CreativeTabs.tabTools);
super(Settings.getNextItemID(), "DMTools", Settings.config,Reference.PREFIX, CreativeTabs.tabTools);
this.setHasSubtypes(true);
this.setMaxStackSize(1);

View file

@ -40,7 +40,7 @@ public class ItemWire extends JItemMultiPart
public ItemWire(int id)
{
super(Settings.CONFIGURATION.get(Configuration.CATEGORY_ITEM, "wire", id).getInt(id));
super(Settings.config.get(Configuration.CATEGORY_ITEM, "wire", id).getInt(id));
this.setUnlocalizedName(Reference.PREFIX + "wire");
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setHasSubtypes(true);

View file

@ -24,7 +24,7 @@ public class BlockKitchenSink extends BlockMachine
{
public BlockKitchenSink()
{
super(Settings.CONFIGURATION, "FluidSink", Material.iron);
super(Settings.config, "FluidSink", Material.iron);
this.setResistance(4f);
this.setHardness(4f);
}

View file

@ -22,7 +22,7 @@ public class BlockReleaseValve extends BlockMachine
{
public BlockReleaseValve()
{
super(Settings.CONFIGURATION, "ReleaseValve", Material.iron);
super(Settings.config, "ReleaseValve", Material.iron);
this.setHardness(1f);
this.setResistance(5f);
}

View file

@ -21,7 +21,7 @@ public class BlockSteamPiston extends BlockMachine
public BlockSteamPiston()
{
super(Settings.CONFIGURATION, "SteamEngine", Material.iron);
super(Settings.config, "SteamEngine", Material.iron);
}

View file

@ -33,7 +33,7 @@ public class BlockTank extends BlockMachine
public BlockTank()
{
super(Settings.CONFIGURATION, "FluidTank", Material.rock);
super(Settings.config, "FluidTank", Material.rock);
this.setHardness(1f);
this.setResistance(5f);
}

View file

@ -35,7 +35,7 @@ public class BlockPipe extends BlockMachine
public BlockPipe()
{
super(Settings.CONFIGURATION, "FluidPipe", Material.iron);
super(Settings.config, "FluidPipe", Material.iron);
this.setBlockBounds(0.30F, 0.30F, 0.30F, 0.70F, 0.70F, 0.70F);
this.setHardness(1f);
this.setResistance(3f);

View file

@ -30,7 +30,7 @@ public class BlockConstructionPump extends BlockMachine
public BlockConstructionPump()
{
super(Settings.CONFIGURATION, "ConstructionPump", Material.iron);
super(Settings.config, "ConstructionPump", Material.iron);
this.setHardness(1f);
this.setResistance(5f);

View file

@ -28,7 +28,7 @@ public class BlockDrain extends BlockMachine
public BlockDrain()
{
super(Settings.CONFIGURATION, "FluidDrain", Material.iron);
super(Settings.config, "FluidDrain", Material.iron);
}
@Override

View file

@ -25,7 +25,7 @@ public class BlockPumpMachine extends BlockMachine
public BlockPumpMachine()
{
super(Settings.CONFIGURATION, "StarterPump", Material.iron);
super(Settings.config, "StarterPump", Material.iron);
this.setHardness(1f);
this.setResistance(5f);
}

View file

@ -20,7 +20,7 @@ public class ItemColoredDust extends Item
public ItemColoredDust()
{
super(Settings.CONFIGURATION.getItem("GlowingRefinedSand", Settings.getNextItemID()).getInt());
super(Settings.config.getItem("GlowingRefinedSand", Settings.getNextItemID()).getInt());
this.setMaxDamage(0);
this.setHasSubtypes(true);
this.setCreativeTab(CreativeTabs.tabMaterials);

View file

@ -57,7 +57,7 @@ public class ItemCommonTool extends Item implements IExtraItemInfo
public ItemCommonTool()
{
super(Settings.CONFIGURATION.getItem("Items", "CommonTools", Settings.getNextItemID()).getInt());
super(Settings.config.getItem("Items", "CommonTools", Settings.getNextItemID()).getInt());
this.maxStackSize = 1;
this.setCreativeTab(CreativeTabs.tabTools);
}

View file

@ -36,7 +36,7 @@ public class BlockCrate extends BlockMachine
public BlockCrate()
{
super(Settings.CONFIGURATION, "crate", UniversalElectricity.machine);
super(Settings.config, "crate", UniversalElectricity.machine);
}
@SideOnly(Side.CLIENT)

View file

@ -28,7 +28,7 @@ public class BlockEncoder extends BlockMachine
public BlockEncoder()
{
super(Settings.CONFIGURATION, "encoder", Material.wood);
super(Settings.config, "encoder", Material.wood);
}
@SideOnly(Side.CLIENT)

View file

@ -39,7 +39,7 @@ public class BlockAdvancedHopper extends BlockMachine
public BlockAdvancedHopper()
{
super(Settings.CONFIGURATION, "DMHopper", Material.iron);
super(Settings.config, "DMHopper", Material.iron);
this.setCreativeTab(CreativeTabs.tabRedstone);
this.setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
}

View file

@ -23,7 +23,7 @@ public class ItemImprinter extends Item
{
public ItemImprinter(int id)
{
super(Settings.CONFIGURATION.getItem("imprint", id).getInt());
super(Settings.config.getItem("imprint", id).getInt());
this.setUnlocalizedName("imprint");
this.setCreativeTab(ResonantInductionTabs.CORE);
this.setHasSubtypes(true);

View file

@ -24,29 +24,20 @@ import resonantinduction.archaic.engineering.TileEngineeringTable;
import archaic.filter.BlockImprinter;
import resonantinduction.archaic.filter.TileFilter;
import archaic.filter.TileImprinter;
import resonantinduction.archaic.firebox.BlockFirebox;
import archaic.firebox.BlockHotPlate;
import archaic.firebox.TileFirebox;
import resonantinduction.archaic.firebox.TileHotPlate;
import resonantinduction.archaic.fluid.grate.TileGrate;
import resonantinduction.archaic.fluid.gutter.TileGutter;
import resonantinduction.archaic.fluid.tank.TileTank;
import archaic.process.BlockCastingMold;
import archaic.process.BlockMillstone;
import archaic.process.TileCastingMold;
import archaic.process.TileMillstone;
import resonantinduction.archaic.engineering.TileEngineeringTable;
import resonantinduction.archaic.filter.TileFilter;
import resonantinduction.archaic.firebox.BlockFirebox;
import resonantinduction.archaic.firebox.TileHotPlate;
import resonantinduction.archaic.fluid.grate.TileGrate;
import resonantinduction.archaic.fluid.gutter.TileGutter;
import resonantinduction.archaic.fluid.tank.TileTank;
import resonantinduction.archaic.waila.Waila;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.ResonantTab;
import resonantinduction.core.Settings;
import resonantinduction.core.TabRI;
import resonantinduction.core.prefab.imprint.ItemImprint;
import resonantinduction.core.resource.ItemHandCrank;
import cpw.mods.fml.common.Mod;
@ -71,7 +62,7 @@ public class Archaic
/** Mod Information */
public static final String ID = "ResonantInduction|Archaic";
public static final String NAME = Reference.NAME + " Archaic";
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.CONFIGURATION, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(TabRI.DEFAULT);
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.config, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(ResonantTab.DEFAULT);
@Instance(ID)
public static Archaic INSTANCE;
@SidedProxy(clientSide = "resonantinduction.archaic.ClientProxy", serverSide = "resonantinduction.archaic.CommonProxy")
@ -105,7 +96,7 @@ public class Archaic
{
modproxies = new ProxyHandler();
NetworkRegistry.instance().registerGuiHandler(this, proxy);
Settings.CONFIGURATION.load();
Settings.config.load();
blockEngineeringTable = contentRegistry.newBlock(TileEngineeringTable.class);
blockCrate = contentRegistry.createBlock(BlockCrate.class, ItemBlockCrate.class, TileCrate.class);
blockImprinter = contentRegistry.createTile(BlockImprinter.class, TileImprinter.class);
@ -124,7 +115,7 @@ public class Archaic
itemHammer = contentRegistry.createItem(ItemHammer.class);
modproxies.applyModule(Waila.class, true);
Settings.CONFIGURATION.save();
Settings.config.save();
PacketAnnotation.register(TileFirebox.class);
PacketAnnotation.register(TileFilter.class);
@ -143,7 +134,7 @@ public class Archaic
@EventHandler
public void postInit(FMLPostInitializationEvent evt)
{
TabRI.ITEMSTACK = new ItemStack(blockEngineeringTable);
ResonantTab.ITEMSTACK = new ItemStack(blockEngineeringTable);
if (OreDictionary.getOres("cobblestone") == null)
{
OreDictionary.registerOre("cobblestone", Block.cobblestone);

View file

@ -64,14 +64,14 @@ public class ItemBlockTank extends ItemBlock implements IFluidContainerItem
@Override
public String getUnlocalizedName(ItemStack itemStack)
{
String translation = LanguageUtility.getLocal(Block.blocksList[this.getBlockID()].getUnlocalizedName() + "." + itemStack.getItemDamage());
String translation = LanguageUtility.getLocal(Block.blocksList[this.getBlock()].getUnlocalizedName() + "." + itemStack.getItemDamage());
if (translation == null || translation.isEmpty())
{
return Block.blocksList[this.getBlockID()].getUnlocalizedName();
return Block.blocksList[this.getBlock()].getUnlocalizedName();
}
return Block.blocksList[this.getBlockID()].getUnlocalizedName() + "." + itemStack.getItemDamage();
return Block.blocksList[this.getBlock()].getUnlocalizedName() + "." + itemStack.getItemDamage();
}
@Override

View file

@ -88,34 +88,10 @@ import resonantinduction.atomic.machine.thermometer.TileThermometer;
import resonantinduction.atomic.schematic.SchematicAccelerator;
import resonantinduction.atomic.schematic.SchematicFissionReactor;
import resonantinduction.atomic.schematic.SchematicFusionReactor;
import resonantinduction.atomic.blocks.TileElectromagnet;
import resonantinduction.atomic.blocks.TileSiren;
import resonantinduction.atomic.items.ItemBreederFuel;
import resonantinduction.atomic.items.ItemDarkMatter;
import resonantinduction.atomic.items.ItemHazmat;
import resonantinduction.atomic.items.ItemRadioactive;
import resonantinduction.atomic.machine.accelerator.EntityParticle;
import resonantinduction.atomic.machine.accelerator.TileAccelerator;
import resonantinduction.atomic.machine.boiler.BlockNuclearBoiler;
import resonantinduction.atomic.machine.centrifuge.BlockCentrifuge;
import resonantinduction.atomic.machine.centrifuge.TileCentrifuge;
import resonantinduction.atomic.machine.extractor.BlockChemicalExtractor;
import resonantinduction.atomic.machine.extractor.turbine.TileElectricTurbine;
import resonantinduction.atomic.machine.extractor.turbine.TileFunnel;
import resonantinduction.atomic.machine.plasma.BlockPlasmaHeater;
import resonantinduction.atomic.machine.plasma.TilePlasma;
import resonantinduction.atomic.machine.plasma.TilePlasmaHeater;
import resonantinduction.atomic.machine.quantum.TileQuantumAssembler;
import resonantinduction.atomic.machine.reactor.TileControlRod;
import resonantinduction.atomic.machine.thermometer.TileThermometer;
import resonantinduction.atomic.schematic.SchematicAccelerator;
import resonantinduction.atomic.schematic.SchematicBreedingReactor;
import resonantinduction.atomic.schematic.SchematicFissionReactor;
import resonantinduction.atomic.schematic.SchematicFusionReactor;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.ResonantTab;
import resonantinduction.core.Settings;
import resonantinduction.core.TabRI;
import universalelectricity.core.transform.vector.Vector3;
import universalelectricity.api.vector.VectorWorld;
import cpw.mods.fml.common.Loader;
@ -148,7 +124,7 @@ public class Atomic
{ 0, 0, 0, 0 }, 0);
public static final String BAN_ANTIMATTER_POWER = FlagRegistry.registerFlag("ban_antimatter_power");
public static final String NAME = Reference.NAME + " Atomic";
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.CONFIGURATION, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(TabRI.DEFAULT);
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.config, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(ResonantTab.DEFAULT);
private static final String[] SUPPORTED_LANGUAGES = new String[]
{ "en_US", "pl_PL", "de_DE", "ru_RU" };
@ -279,7 +255,7 @@ public class Atomic
BlockCreativeBuilder.register(new SchematicFissionReactor());
BlockCreativeBuilder.register(new SchematicFusionReactor());
Settings.CONFIGURATION.load();
Settings.config.load();
/** Register Packets */
PacketAnnotation.register(TileAccelerator.class);
@ -311,7 +287,7 @@ public class Atomic
FLUIDSTACK_TOXIC_WASTE = new FluidStack(FluidRegistry.getFluidID("toxicwaste"), 0);
/** Block Initiation */
blockRadioactive = contentRegistry.createBlock(BlockRadioactive.class).setUnlocalizedName(Reference.PREFIX + "radioactive").setTextureName(Reference.PREFIX + "radioactive").setCreativeTab(TabRI.DEFAULT);
blockRadioactive = contentRegistry.createBlock(BlockRadioactive.class).setUnlocalizedName(Reference.PREFIX + "radioactive").setTextureName(Reference.PREFIX + "radioactive").setCreativeTab(ResonantTab.DEFAULT);
blockUraniumOre = contentRegistry.createBlock(BlockUraniumOre.class);
blockElectricTurbine = contentRegistry.createTile(BlockElectricTurbine.class, TileElectricTurbine.class);
@ -332,10 +308,10 @@ public class Atomic
blockToxicWaste = contentRegistry.createBlock(BlockToxicWaste.class).setCreativeTab(null);
/** Items */
itemHazmatTop = new ItemHazmat(Settings.CONFIGURATION.getItem("HazmatTop", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 0).setUnlocalizedName(Reference.PREFIX + "hazmatMask");
itemHazmatBody = new ItemHazmat(Settings.CONFIGURATION.getItem("HazmatBody", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 1).setUnlocalizedName(Reference.PREFIX + "hazmatBody");
itemHazmatLeggings = new ItemHazmat(Settings.CONFIGURATION.getItem("HazmatBottom", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 2).setUnlocalizedName(Reference.PREFIX + "hazmatLeggings");
itemHazmatBoots = new ItemHazmat(Settings.CONFIGURATION.getItem("HazmatBoots", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 3).setUnlocalizedName(Reference.PREFIX + "hazmatBoots");
itemHazmatTop = new ItemHazmat(Settings.config.getItem("HazmatTop", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 0).setUnlocalizedName(Reference.PREFIX + "hazmatMask");
itemHazmatBody = new ItemHazmat(Settings.config.getItem("HazmatBody", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 1).setUnlocalizedName(Reference.PREFIX + "hazmatBody");
itemHazmatLeggings = new ItemHazmat(Settings.config.getItem("HazmatBottom", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 2).setUnlocalizedName(Reference.PREFIX + "hazmatLeggings");
itemHazmatBoots = new ItemHazmat(Settings.config.getItem("HazmatBoots", Settings.getNextItemID()).getInt(), hazmatArmorMaterial, proxy.getArmorIndex("hazmat"), 3).setUnlocalizedName(Reference.PREFIX + "hazmatBoots");
itemCell = contentRegistry.createItem("cellEmpty", Item.class);
itemFissileFuel = contentRegistry.createItem("rodFissileFuel", ItemFissileFuel.class);
@ -353,7 +329,7 @@ public class Atomic
FLUID_PLASMA.setBlockID(blockPlasma);
int bucketID = Settings.getNextItemID();
itemBucketToxic = (new ItemBucket(Settings.CONFIGURATION.getItem("Toxic Waste Bucket", bucketID).getInt(bucketID), blockToxicWaste.blockID)).setCreativeTab(TabRI.DEFAULT).setUnlocalizedName(Reference.PREFIX + "bucketToxicWaste")
itemBucketToxic = (new ItemBucket(Settings.config.getItem("Toxic Waste Bucket", bucketID).getInt(bucketID), blockToxicWaste.blockID)).setCreativeTab(ResonantTab.DEFAULT).setUnlocalizedName(Reference.PREFIX + "bucketToxicWaste")
.setContainerItem(Item.bucketEmpty).setTextureName(Reference.PREFIX + "bucketToxicWaste");
FluidContainerRegistry.registerFluidContainer(FluidRegistry.getFluid("toxicwaste"), new ItemStack(itemBucketToxic), new ItemStack(Item.bucketEmpty));
@ -361,19 +337,19 @@ public class Atomic
FluidContainerRegistry.registerFluidContainer(new FluidStack(FluidRegistry.getFluid("deuterium"), 200), new ItemStack(itemDeuteriumCell), new ItemStack(itemCell));
FluidContainerRegistry.registerFluidContainer(new FluidStack(FluidRegistry.getFluid("tritium"), 200), new ItemStack(itemTritiumCell), new ItemStack(itemCell));
if (OreDictionary.getOres("oreUranium").size() > 1 && Settings.CONFIGURATION.get(Configuration.CATEGORY_GENERAL, "Auto Disable Uranium If Exist", false).getBoolean(false))
if (OreDictionary.getOres("oreUranium").size() > 1 && Settings.config.get(Configuration.CATEGORY_GENERAL, "Auto Disable Uranium If Exist", false).getBoolean(false))
{
ResonantInduction.LOGGER.fine("Disabled Uranium Generation. Detected another uranium being generated: " + OreDictionary.getOres("oreUranium").size());
}
else
{
uraniumOreGeneration = new OreGenReplaceStone("Uranium Ore", "oreUranium", new ItemStack(blockUraniumOre), 0, 25, 9, 3, "pickaxe", 2);
uraniumOreGeneration.enable(Settings.CONFIGURATION);
uraniumOreGeneration.enable(Settings.config);
OreGenerator.addOre(uraniumOreGeneration);
ResonantInduction.LOGGER.fine("Added Atomic Science uranium to ore generator.");
}
Settings.CONFIGURATION.save();
Settings.config.save();
MinecraftForge.EVENT_BUS.register(itemAntimatter);
MinecraftForge.EVENT_BUS.register(FulminationHandler.INSTANCE);
@ -419,8 +395,8 @@ public class Atomic
});
proxy.preInit();
Settings.CONFIGURATION.save();
TabRI.ITEMSTACK = new ItemStack(blockReactorCell);
Settings.config.save();
ResonantTab.ITEMSTACK = new ItemStack(blockReactorCell);
}
@EventHandler
@ -556,7 +532,7 @@ public class Atomic
Atomic.proxy.init();
Settings.CONFIGURATION.load();
Settings.config.load();
if (Loader.isModLoaded("IC2") && Settings.allowAlternateRecipes)
{
@ -644,7 +620,7 @@ public class Atomic
}
}
Settings.CONFIGURATION.save();
Settings.config.save();
}
@ForgeSubscribe

View file

@ -7,8 +7,8 @@ import net.minecraft.util.IIcon;
import net.minecraft.world.World;
import resonant.lib.prefab.block.BlockRadioactive;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantTab;
import resonantinduction.core.Settings;
import resonantinduction.core.TabRI;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -20,7 +20,7 @@ public class BlockUraniumOre extends BlockRadioactive
super(id, Material.rock);
this.setUnlocalizedName(Reference.PREFIX + "oreUranium");
this.setStepSound(soundStoneFootstep);
this.setCreativeTab(TabRI.DEFAULT);
this.setCreativeTab(ResonantTab.DEFAULT);
this.setHardness(2f);
this.setTextureName(Reference.PREFIX + "oreUranium");

View file

@ -9,7 +9,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.DamageSource;
import resonant.api.armor.IAntiPoisonArmor;
import resonantinduction.core.Reference;
import resonantinduction.core.TabRI;
import resonantinduction.core.ResonantTab;
/** Hazmat */
public class ItemHazmat extends ItemArmor implements IAntiPoisonArmor
@ -17,7 +17,7 @@ public class ItemHazmat extends ItemArmor implements IAntiPoisonArmor
public ItemHazmat(int id, EnumArmorMaterial material, int index, int slot)
{
super(id, material, index, slot);
this.setCreativeTab(TabRI.DEFAULT);
this.setCreativeTab(ResonantTab.DEFAULT);
this.setMaxDamage(200000);
}

View file

@ -1,223 +0,0 @@
package resonantinduction.core;
import java.util.HashMap;
import net.minecraft.command.CommandBase;
import net.minecraft.command.ICommand;
import net.minecraft.command.ICommandSender;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ChatMessageComponent;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.event.ForgeSubscribe;
import net.minecraftforge.event.entity.player.PlayerInteractEvent;
import net.minecraftforge.event.entity.player.PlayerInteractEvent.Action;
import resonantinduction.core.interfaces.ICmdMachine;
import universalelectricity.api.CompatibilityModule;
import universalelectricity.api.vector.VectorWorld;
/** Command that allows interaction with machines using chat commands
*
* @author Darkguardsman */
public class CommandMachine extends CommandBase
{
public static HashMap<String, VectorWorld> selection = new HashMap<String, VectorWorld>();
@Override
public String getCommandName()
{
return "machine";
}
@Override
public String getCommandUsage(ICommandSender user)
{
return "/machine ?";
}
@Override
public void processCommand(ICommandSender sender, String[] args)
{
if (args != null && args.length > 0 && args[0] != null)
{
final String command = args[0];
if (command.equalsIgnoreCase("?"))
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("/machine <arguments....>"));
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Each machine has unique commands"));
}//Commands are only support by players at the moment
else if (sender instanceof EntityPlayer)
{
final boolean hasSubCommand = args.length > 1 && args[1] != null;
final boolean hasSecondSub = args.length > 2 && args[2] != null;
final boolean hasThirdSub = args.length > 3 && args[3] != null;
final String subCommand = hasSubCommand ? args[1] : null;
final String subCommand2 = hasSecondSub ? args[2] : null;
final String subCommand3 = hasThirdSub ? args[3] : null;
if (selection.containsKey(((EntityPlayer) sender).username) && selection.get(((EntityPlayer) sender).username) != null)
{
VectorWorld pos = selection.get(((EntityPlayer) sender).username);
TileEntity tile = pos.getTileEntity();
if (tile instanceof ICmdMachine && ((ICmdMachine) tile).canTakeCommand(sender, args))
{
((ICmdMachine) tile).processCommand(sender, args);
}
else if (command.equalsIgnoreCase("energy"))
{
if (CompatibilityModule.isHandler(tile))
{
if (!hasSubCommand)
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("/Machine energy set <side> <amount>"));
sender.sendChatToPlayer(ChatMessageComponent.createFromText("/Machine energy get <side>"));
}
else if (subCommand.equalsIgnoreCase("get") || subCommand.equalsIgnoreCase("set"))
{
if (hasSecondSub)
{
ForgeDirection direction = getDirection(subCommand2);
if (direction != null)
{
if (subCommand.equalsIgnoreCase("get"))
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Energy: " + CompatibilityModule.getEnergy(tile, direction) + "/" + CompatibilityModule.getMaxEnergy(tile, direction)));
}
else if (subCommand.equalsIgnoreCase("set"))
{
if (hasThirdSub)
{
long joules = Long.parseLong(subCommand3, -33);
if (joules >= 0)
{
long ex = CompatibilityModule.extractEnergy(tile, direction, Long.MAX_VALUE, false);
if (ex == CompatibilityModule.extractEnergy(tile, direction, Long.MAX_VALUE, true))
{
CompatibilityModule.receiveEnergy(tile, direction, joules, true);
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Energy set"));
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Failed to set energy! Maybe try a different side?"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Invalid input value"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Supply an energy value"));
}
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Couldn't read input for side argument"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Need to supply a side"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Unknown energy command"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Machine is not an energy handler"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Unknown command, or unsupport for this machine!"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Please select the machine first"));
}
}
else
{
sender.sendChatToPlayer(ChatMessageComponent.createFromText("Console access not supported"));
}
}
}
public ForgeDirection getDirection(String str)
{
if (str != null && !str.isEmpty())
{
//Get side from work input
if (str.equalsIgnoreCase("north") || str.equalsIgnoreCase("n"))
{
return ForgeDirection.NORTH;
}
else if (str.equalsIgnoreCase("south") || str.equalsIgnoreCase("s"))
{
return ForgeDirection.SOUTH;
}
else if (str.equalsIgnoreCase("east") || str.equalsIgnoreCase("e"))
{
return ForgeDirection.EAST;
}
else if (str.equalsIgnoreCase("west") || str.equalsIgnoreCase("w"))
{
return ForgeDirection.WEST;
}
else if (str.equalsIgnoreCase("up") || str.equalsIgnoreCase("u"))
{
return ForgeDirection.UP;
}
else if (str.equalsIgnoreCase("down") || str.equalsIgnoreCase("d"))
{
return ForgeDirection.DOWN;
}
//Get side from number input
int side = Integer.getInteger(str, -3);
if (side >= 0 && side < 6)
{
return ForgeDirection.getOrientation(side);
}
}
return null;
}
@ForgeSubscribe
public void onPlayInteract(PlayerInteractEvent event)
{
if (event.action == Action.RIGHT_CLICK_BLOCK)
{
if (event.entityPlayer.getHeldItem() != null && ResonantInduction.itemDevStaff != null && event.entityPlayer.getHeldItem().itemID == ResonantInduction.itemDevStaff.itemID)
{
if (event.entityPlayer.isSneaking())
{
VectorWorld hit = new VectorWorld(event.entity.worldObj, event.x, event.y, event.z);
TileEntity tile = hit.getTileEntity();
if (tile != null)
{
event.entityPlayer.sendChatToPlayer(ChatMessageComponent.createFromText("Tile selected at " + hit.x + "x " + hit.y + "y " + hit.z + "z]"));
selection.put(event.entityPlayer.username, hit);
if (event.isCancelable())
event.setCanceled(true);
}
}
}
}
}
@Override
public int compareTo(Object par1Obj)
{
return this.compareTo((ICommand) par1Obj);
}
}

View file

@ -0,0 +1,74 @@
package resonantinduction.core
import java.util.HashMap
import net.minecraft.block.Block
import net.minecraft.item.{Item, ItemStack}
import net.minecraftforge.fluids.BlockFluidFinite
import resonant.content.loader.{ContentHolder, ExplicitContentName}
import resonantinduction.core.content.BlockIndustrialStone
import resonantinduction.core.resource.fluid.ItemOreResourceBucket
import resonantinduction.core.resource.{ItemOreResource, TileDust}
/**
* The core contents of Resonant Induction
* @author Calclavia
*/
object CoreContent extends ContentHolder
{
final val blockMixtureFluids: HashMap[Integer, BlockFluidFinite] = new HashMap[Integer, BlockFluidFinite]
final val blockMoltenFluid: HashMap[Integer, BlockFluidFinite] = new HashMap[Integer, BlockFluidFinite]
/**
* Blocks
*/
val decoration: Block = new BlockIndustrialStone()
@ExplicitContentName("dust")
val blockDust: Block = new TileDust().setCreativeTab(null)
@ExplicitContentName("refinedDust")
val blockRefinedDust: Block = new TileDust().setCreativeTab(null)
/**
* Items
*/
@ExplicitContentName
val rubble = new ItemOreResource
@ExplicitContentName
val dust = new ItemOreResource
@ExplicitContentName
val refinedDust = new ItemOreResource
@ExplicitContentName
val bucketMixture = new ItemOreResourceBucket(false)
@ExplicitContentName
val bucketMolten = new ItemOreResourceBucket(true)
/*
val itemBiomass = contentRegistry.createItem(classOf[ItemBiomass])
val itemDevStaff = contentRegistry.createItem(classOf[ItemDevStaff])
val itemFlour = contentRegistry.createItem(classOf[ItemFlour])
*/
manager.setTab(ResonantTab).setPrefix(Reference.PREFIX)
/**
* Recipe registration
*/
override def postInit()
{
/**
* Resources
*/
/**
* Decoration
*/
recipes += shaped(new ItemStack(decoration, 8, 3), Array[AnyRef]("XXX", "XCX", "XXX", 'X', Block.cobblestone, 'C', new ItemStack(Item.coal, 1, 1)))
recipes +=(decoration, 3, new ItemStack(decoration, 1, 5), 5)
recipes +=(decoration, new ItemStack(decoration, 1, 4), 5)
recipes += shaped(new ItemStack(decoration, 8, 7), Array[AnyRef]("XXX", "XVX", "XXX", 'X', new ItemStack(decoration), 'V', Block.vine))
recipes += shaped(new ItemStack(decoration, 4), Array[AnyRef]("XX ", "XX ", " ", 'X', new ItemStack(decoration, 1, 5)))
recipes += shaped(new ItemStack(decoration, 4, 1), Array[AnyRef]("XXX", "XXX", "XX ", 'X', Block.stoneSingleSlab))
recipes += shaped(new ItemStack(decoration, 8, 2), Array[AnyRef]("XXX", "X X", "XXX", 'X', new ItemStack(decoration, 1, 5)))
recipes += shaped(new ItemStack(decoration, 5, 10), Array[AnyRef]("IXI", "XXX", "IXI", 'X', new ItemStack(decoration, 1, 5), 'I', Item.ingotIron))
}
}

View file

@ -1,33 +0,0 @@
package resonantinduction.core;
/**
* A class for static references.
*
* @author Calclavia
*/
public class Reference
{
/** The official name of the mod */
public static final String NAME = "Resonant Induction";
public static final String MAJOR_VERSION = "@MAJOR@";
public static final String MINOR_VERSION = "@MINOR@";
public static final String REVISION_VERSION = "@REVIS@";
public static final String BUILD_VERSION = "@BUILD@";
public static final String VERSION = MAJOR_VERSION + "." + MINOR_VERSION + "." + REVISION_VERSION;
public static final String CHANNEL = "resonindc";
/**
* Directory Information
*/
public static final String DOMAIN = "resonantinduction";
public static final String PREFIX = DOMAIN + ":";
public static final String DIRECTORY = "/assets/" + DOMAIN + "/";
public static final String TEXTURE_DIRECTORY = "textures/";
public static final String GUI_DIRECTORY = TEXTURE_DIRECTORY + "gui/";
public static final String BLOCK_TEXTURE_DIRECTORY = TEXTURE_DIRECTORY + "blocks/";
public static final String ITEM_TEXTURE_DIRECTORY = TEXTURE_DIRECTORY + "items/";
public static final String MODEL_PATH = "models/";
public static final String MODEL_DIRECTORY = DIRECTORY + MODEL_PATH;
public static final String LANGUAGE_DIRECTORY = DIRECTORY + "languages/";
public static final String[] LANGUAGES = new String[] { "en_US", "de_DE", "ru_RU" };
}

View file

@ -0,0 +1,36 @@
package resonantinduction.core
import java.util.logging.Logger
/**
* A class for global references.
*
* @author Calclavia
*/
object Reference
{
final val idPrefix = "ResonantInduction"
/** The official name of the mod */
final val NAME: String = "Resonant Induction"
final val LOGGER = Logger.getLogger(Reference.NAME)
final val MAJOR_VERSION: String = "@MAJOR@"
final val MINOR_VERSION: String = "@MINOR@"
final val REVISION_VERSION: String = "@REVIS@"
final val BUILD_VERSION: String = "@BUILD@"
final val VERSION: String = MAJOR_VERSION + "." + MINOR_VERSION + "." + REVISION_VERSION
final val CHANNEL: String = "resonindc"
/**
* Directory Information
*/
final val DOMAIN: String = "resonantinduction"
final val PREFIX: String = DOMAIN + ":"
final val DIRECTORY: String = "/assets/" + DOMAIN + "/"
final val TEXTURE_DIRECTORY: String = "textures/"
final val GUI_DIRECTORY: String = TEXTURE_DIRECTORY + "gui/"
final val BLOCK_TEXTURE_DIRECTORY: String = TEXTURE_DIRECTORY + "blocks/"
final val ITEM_TEXTURE_DIRECTORY: String = TEXTURE_DIRECTORY + "items/"
final val MODEL_PATH: String = "models/"
final val MODEL_DIRECTORY: String = DIRECTORY + MODEL_PATH
}

View file

@ -11,7 +11,6 @@ import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.FurnaceRecipes;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.fluids.BlockFluidFinite;
import net.minecraftforge.oredict.OreDictionary;
import net.minecraftforge.oredict.ShapelessOreRecipe;
import org.modstats.ModstatInfo;
@ -25,7 +24,7 @@ import resonant.lib.network.PacketHandler;
import resonant.lib.network.PacketTile;
import resonant.lib.prefab.item.ItemBlockMetadata;
import resonant.lib.utility.LanguageUtility;
import resonantinduction.core.blocks.BlockIndustrialStone;
import resonantinduction.core.content.BlockIndustrialStone;
import resonantinduction.core.blocks.IndustrialStoneBlocksRecipes;
import resonantinduction.core.handler.TextureHookHandler;
import resonantinduction.core.items.ItemDevStaff;
@ -71,7 +70,7 @@ public class ResonantInduction
public static final PacketAnnotation PACKET_ANNOTATION = new PacketAnnotation(Reference.CHANNEL);
public static final HashMap<Integer, BlockFluidFinite> blockMixtureFluids = new HashMap<Integer, BlockFluidFinite>();
public static final HashMap<Integer, BlockFluidFinite> blockMoltenFluid = new HashMap<Integer, BlockFluidFinite>();
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.CONFIGURATION, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(TabRI.CORE);
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.config, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(ResonantTab.CORE);
@Instance(ID)
public static ResonantInduction INSTANCE;
@SidedProxy(clientSide = "resonantinduction.core.ClientProxy", serverSide = "resonantinduction.core.CommonProxy")
@ -87,7 +86,7 @@ public class ResonantInduction
public static Block blockDust, blockRefinedDust;
public static Block blockIndustrialStone;
@EventHandler
public void preInit(FMLPreInitializationEvent evt)
@ -95,7 +94,7 @@ public class ResonantInduction
ResonantInduction.LOGGER.setParent(FMLLog.getLogger());
NetworkRegistry.instance().registerGuiHandler(this, proxy);
Modstats.instance().getReporter().registerMod(this);
Settings.CONFIGURATION.load();
Settings.config.load();
// Register Forge Events
MinecraftForge.EVENT_BUS.register(ResourceGenerator.INSTANCE);
MinecraftForge.EVENT_BUS.register(new TextureHookHandler());
@ -128,7 +127,7 @@ public class ResonantInduction
GameRegistry.registerTileEntity(TileFluidMixture.class, "ri_fluid_mixture");
proxy.preInit();
TabRI.ITEMSTACK = new ItemStack(blockIndustrialStone);
ResonantTab.ITEMSTACK = new ItemStack(blockIndustrialStone);
}
@EventHandler
@ -145,7 +144,7 @@ public class ResonantInduction
@EventHandler
public void postInit(FMLPostInitializationEvent evt)
{
ConfigHandler.configure(Settings.CONFIGURATION, "resonantinduction");
ConfigHandler.configure(Settings.config, "resonantinduction");
// Generate Resources
ResourceGenerator.generateOreResources();
@ -155,7 +154,7 @@ public class ResonantInduction
GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack (itemFlour ,1,1),new Object []{itemFlour, Item.bucketWater}));
MachineRecipes.INSTANCE.addRecipe(RecipeType.GRINDER.name(), Item.wheat, itemFlour);
proxy.postInit();
Settings.CONFIGURATION.save();
Settings.config.save();
IndustrialStoneBlocksRecipes.init();
}

View file

@ -0,0 +1,94 @@
package resonantinduction.core
import cpw.mods.fml.common.Mod.EventHandler
import cpw.mods.fml.common.event.{FMLInitializationEvent, FMLPostInitializationEvent, FMLPreInitializationEvent, FMLServerStartingEvent}
import cpw.mods.fml.common.network.NetworkRegistry
import cpw.mods.fml.common.registry.GameRegistry
import cpw.mods.fml.common.{FMLCommonHandler, FMLLog, Mod, SidedProxy}
import mffs.{Settings, Content}
import net.minecraft.block.Block
import net.minecraft.command.{ICommandManager, ServerCommandManager}
import net.minecraft.item.crafting.FurnaceRecipes
import net.minecraft.item.{Item, ItemStack}
import net.minecraftforge.common.MinecraftForge
import net.minecraftforge.common.config.Configuration
import net.minecraftforge.oredict.ShapelessOreRecipe
import org.modstats.{ModstatInfo, Modstats}
import resonant.api.recipe.MachineRecipes
import resonant.lib.config.ConfigHandler
import resonant.lib.loadable.LoadableHandler
import resonant.lib.network.netty.PacketManager
import resonant.lib.utility.LanguageUtility
import resonantinduction.core.blocks.IndustrialStoneBlocksRecipes
import resonantinduction.core.handler.TextureHookHandler
import resonantinduction.core.items.{ItemDevStaff, ItemFlour}
import resonantinduction.core.prefab.part.PacketMultiPart
import resonantinduction.core.resource.fluid.{ItemOreResourceBucket, TileFluidMixture}
import resonantinduction.core.resource.{BlockDust, ItemBiomass, ItemOreResource, ResourceGenerator, TileDust}
/** The core module of Resonant Induction
*
* @author Calclavia */
@Mod(modid = ResonantInduction.ID, name = ResonantInduction.NAME, version = Reference.VERSION, modLanguage = "scala", dependencies = "required-after:ForgeMultipart@[1.0.0.244,);required-after:ResonantEngine;before:ThermalExpansion;before:Mekanism")
@ModstatInfo(prefix = "resonantin")
object ResonantInduction
{
/** Mod Information */
final val ID: String = Reference.idPrefix + ":Core"
/** Packets */
val packetHandler = new PacketManager(Reference.channel)
val loadables = new LoadableHandler
@SidedProxy(clientSide = "resonantinduction.core.ClientProxy", serverSide = "resonantinduction.core.CommonProxy")
var proxy: CommonProxy = _
/** Recipe Types */
object RecipeType extends Enumeration
{
final val CRUSHER, GRINDER, MIXER, SMELTER, SAWMILL = Value
}
@EventHandler
def preInit(evt: FMLPreInitializationEvent)
{
/**
* Registrations
*/
NetworkRegistry.instance.registerGuiHandler(this, proxy)
Modstats.instance.getReporter.registerMod(this)
Settings.config = new Configuration(event.getSuggestedConfigurationFile)
ConfigHandler.sync(Settings, Settings.config)
MinecraftForge.EVENT_BUS.register(ResourceGenerator.INSTANCE)
MinecraftForge.EVENT_BUS.register(new TextureHookHandler)
loadables.applyModule(proxy)
loadables.applyModule(packetHandler)
loadables.applyModule(CoreContent)
proxy.preInit()
ResonantTab.itemStack = new ItemStack(blockIndustrialStone)
}
@EventHandler
def init(evt: FMLInitializationEvent)
{
ResourceGenerator.generateOreResources()
proxy.init()
}
@EventHandler
def postInit(evt: FMLPostInitializationEvent)
{
/*
GameRegistry.addRecipe(new ShapelessOreRecipe(itemFlour, Array[AnyRef](Item.wheat, Item.wheat)))
FurnaceRecipes.smelting.addSmelting(itemFlour.itemID, 1, new ItemStack(Item.bread), 50f)
GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(itemFlour, 1, 1), Array[AnyRef](itemFlour, Item.bucketWater)))
MachineRecipes.INSTANCE.addRecipe(RecipeType.GRINDER.name, Item.wheat, itemFlour)
*/
proxy.postInit()
}
}

View file

@ -0,0 +1,18 @@
/**
*
*/
package resonantinduction.core
import net.minecraft.creativetab.CreativeTabs
import net.minecraft.item.{ItemStack, Item}
/**
* @author Calclavia
*
*/
object ResonantTab extends CreativeTabs(CreativeTabs.getNextID, "ResonantInduction")
{
var itemStack: ItemStack = null
override def getTabIconItem: Item = itemStack.getItem
}

View file

@ -1,185 +0,0 @@
package resonantinduction.core;
import java.io.File;
import java.util.Arrays;
import net.minecraft.item.ItemStack;
import net.minecraft.server.MinecraftServer;
import net.minecraftforge.common.Configuration;
import resonant.api.recipe.QuantumAssemblerRecipes;
import resonant.lib.config.Config;
import resonant.lib.content.IDManager;
import resonant.lib.prefab.poison.PotionRadiation;
import resonant.lib.utility.LanguageUtility;
import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.ModMetadata;
/** @author Calclavia */
public class Settings
{
public static final Configuration CONFIGURATION = new Configuration(new File(Loader.instance().getConfigDir(), Reference.NAME + ".cfg"));
public static final String DOMAIN = "resonantinduction";
/** IDs suggested by Jyzarc and Horfius */
public static final IDManager idManager;
static
{
CONFIGURATION.load();
idManager = new IDManager(CONFIGURATION.get(Configuration.CATEGORY_GENERAL, "BlockIDPrefix", 1200).getInt(1200), CONFIGURATION.get(Configuration.CATEGORY_GENERAL, "ItemIDPrefix", 20150).getInt(20150));
CONFIGURATION.save();
}
/** Config Options */
public static void load()
{
for (int recipeID : quantumAssemblerRecipes)
{
try
{
QuantumAssemblerRecipes.addRecipe(new ItemStack(recipeID, 1, 0));
}
catch (Exception e)
{
e.printStackTrace();
}
}
// Calling this once to prevent the static class from not initiating.
PotionRadiation.INSTANCE.getId();
}
public static int getNextBlockID()
{
return idManager.getNextBlockID();
}
public static int getNextBlockID(String key)
{
int id = idManager.getNextBlockID();
return Settings.CONFIGURATION.get(Configuration.CATEGORY_BLOCK, key, id).getInt(id);
}
public static int getNextItemID()
{
return idManager.getNextItemID();
}
public static int getNextItemID(String key)
{
int id = idManager.getNextItemID();
return Settings.CONFIGURATION.get(Configuration.CATEGORY_ITEM, key, id).getInt(id);
}
@Config(key = "Engineering Table Autocraft")
public static boolean ALLOW_ENGINEERING_AUTOCRAFT = true;
@Config(key = "Tesla Sound FXs")
public static boolean SOUND_FXS = true;
@Config(key = "Shiny silver Wires")
public static boolean SHINY_SILVER = true;
@Config(key = "Max EM Contractor Path")
public static int MAX_LEVITATOR_DISTANCE = 200;
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Max Reach")
public static int LEVITATOR_MAX_REACH = 40;
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Push Delay")
public static int LEVITATOR_PUSH_DELAY = 5;
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Max Speed")
public static double LEVITATOR_MAX_SPEED = .2;
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Acceleration")
public static double LEVITATOR_ACCELERATION = .02;
@Config(category = "Power", key = "Wind_tubine_Ratio")
public static int WIND_POWER_RATIO = 1;
@Config(category = "Power", key = "Water_tubine_Ratio")
public static int WATER_POWER_RATIO = 1;
@Config(category = "Power", key = "Solor_Panel")
public static int SOLAR_ENERGY = 50;
@Config
public static double fulminationOutputMultiplier = 1;
@Config
public static double turbineOutputMultiplier = 1;
@Config
public static double fissionBoilVolumeMultiplier = 1;
@Config
public static boolean allowTurbineStacking = true;
@Config
public static boolean allowToxicWaste = true;
@Config
public static boolean allowRadioactiveOres = true;
@Config
public static boolean allowOreDictionaryCompatibility = true;
@Config
public static boolean allowAlternateRecipes = true;
@Config
public static boolean allowIC2UraniumCompression = true;
@Config(comment = "0 = Do not generate, 1 = Generate items only, 2 = Generate all")
public static int quantumAssemblerGenerateMode = 1;
@Config
public static int uraniumHexaflourideRatio = 200;
@Config
public static int waterPerDeutermium = 4;
@Config
public static int deutermiumPerTritium = 4;
@Config(comment = "Put a list of block/item IDs to be used by the Quantum Assembler. Separate by commas, no space.")
public static int[] quantumAssemblerRecipes = new int[0];
@Config
public static double darkMatterSpawnChance = 0.2;
public static void setModMetadata(ModMetadata metadata, String id, String name)
{
setModMetadata(metadata, id, name, "");
}
public static void setModMetadata(ModMetadata metadata, String id, String name, String parent)
{
metadata.modId = id;
metadata.name = name;
metadata.description = LanguageUtility.getLocal("meta.resonantinduction.description");
metadata.url = "http://calclavia.com/resonant-induction";
metadata.logoFile = "ri_logo.png";
metadata.version = Reference.VERSION + "." + Reference.BUILD_VERSION;
metadata.authorList = Arrays.asList(new String[] { "Calclavia", "DarkCow", "Maxwolf Goodliffe" });
metadata.credits = LanguageUtility.getLocal("meta.resonantinduction.credits");
metadata.parent = parent;
metadata.autogenerated = false;
}
public static boolean isOp(String username)
{
MinecraftServer theServer = FMLCommonHandler.instance().getMinecraftServerInstance();
if (theServer != null)
{
return theServer.getConfigurationManager().getOps().contains(username.trim().toLowerCase());
}
return false;
}
}

View file

@ -0,0 +1,75 @@
package resonantinduction.core
import cpw.mods.fml.common.eventhandler.SubscribeEvent
import net.minecraft.item.ItemStack
import net.minecraftforge.common.config.Configuration
import resonant.api.recipe.QuantumAssemblerRecipes
import resonant.lib.config.Config
import resonant.lib.config.ConfigEvent.PostConfigEvent
import resonant.lib.prefab.poison.PotionRadiation
/** @author Calclavia */
object Settings
{
var config: Configuration = _
@Config(key = "Engineering Table Autocraft")
var ALLOW_ENGINEERING_AUTOCRAFT = true
@Config(key = "Tesla Sound FXs")
var SOUND_FXS = true
@Config(key = "Shiny silver Wires")
var SHINY_SILVER = true
@Config(key = "Max EM Contractor Path")
var MAX_LEVITATOR_DISTANCE: Int = 200
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Max Reach")
var LEVITATOR_MAX_REACH: Int = 40
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Push Delay")
var LEVITATOR_PUSH_DELAY: Int = 5
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Max Speed")
var LEVITATOR_MAX_SPEED: Double = .2
@Config(category = Configuration.CATEGORY_GENERAL, key = "Levitator Acceleration")
var LEVITATOR_ACCELERATION: Double = .02
@Config(category = "Power", key = "Wind_tubine_Ratio")
var WIND_POWER_RATIO: Int = 1
@Config(category = "Power", key = "Water_tubine_Ratio")
var WATER_POWER_RATIO: Int = 1
@Config(category = "Power", key = "Solor_Panel")
var SOLAR_ENERGY: Int = 50
@Config var fulminationOutputMultiplier: Double = 1
@Config var turbineOutputMultiplier: Double = 1
@Config var fissionBoilVolumeMultiplier: Double = 1
@Config var allowTurbineStacking: Boolean = true
@Config var allowToxicWaste: Boolean = true
@Config var allowRadioactiveOres: Boolean = true
@Config var allowOreDictionaryCompatibility: Boolean = true
@Config var allowAlternateRecipes: Boolean = true
@Config var allowIC2UraniumCompression: Boolean = true
@Config(comment = "0 = Do not generate, 1 = Generate items only, 2 = Generate all")
var quantumAssemblerGenerateMode: Int = 1
@Config var uraniumHexaflourideRatio: Int = 200
@Config var waterPerDeutermium: Int = 4
@Config var deutermiumPerTritium: Int = 4
@Config(comment = "Put a list of block/item IDs to be used by the Quantum Assembler. Separate by commas, no space.")
var quantumAssemblerRecipes: Array[Int] = new Array[Int](0)
@Config var darkMatterSpawnChance: Double = 0.2
@SubscribeEvent
def configEvent(evt: PostConfigEvent)
{
for (recipeID <- quantumAssemblerRecipes)
{
try
{
QuantumAssemblerRecipes.addRecipe(new ItemStack(recipeID, 1, 0))
}
catch
{
case e: Exception =>
{
e.printStackTrace
}
}
}
PotionRadiation.INSTANCE.getId
}
}

View file

@ -1,32 +0,0 @@
/**
*
*/
package resonantinduction.core;
import net.minecraftforge.client.event.sound.SoundLoadEvent;
import net.minecraftforge.event.ForgeSubscribe;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
/**
* @author Calclavia
*
*/
@SideOnly(Side.CLIENT)
public class SoundHandler
{
public static final SoundHandler INSTANCE = new SoundHandler();
public static final String[] SOUND_FILES = { "gearCrank.ogg", "hammer.ogg", "grinder1.ogg", "grinder2.ogg", "grinder3.ogg", "grinder4.ogg", "electricshock1.ogg", "electricshock2.ogg", "electricshock3.ogg", "electricshock4.ogg", "electricshock5.ogg", "electricshock6.ogg", "electricshock7.ogg", "conveyor.ogg" };
@ForgeSubscribe
public void loadSoundEvents(SoundLoadEvent event)
{
for (int i = 0; i < SOUND_FILES.length; i++)
{
event.manager.addSound(Reference.PREFIX + SOUND_FILES[i]);
}
ResonantInduction.LOGGER.fine("Loaded sound fxs");
}
}

View file

@ -1,31 +0,0 @@
/**
*
*/
package resonantinduction.core;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.ItemStack;
/**
* @author Calclavia
*
*/
public class TabRI extends CreativeTabs
{
public static final TabRI DEFAULT = new TabRI(CreativeTabs.getNextID(), Reference.DOMAIN);
public static final TabRI CORE = new TabRI(CreativeTabs.getNextID(), Reference.DOMAIN + ".core");
public static ItemStack ITEMSTACK;
public TabRI(int par1, String par2Str)
{
super(par1, par2Str);
}
@Override
public ItemStack getIconItemStack()
{
return ITEMSTACK;
}
}

View file

@ -1,56 +0,0 @@
package resonantinduction.core.blocks;
import net.minecraft.block.Block;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.FurnaceRecipes;
import resonantinduction.core.ResonantInduction;
import cpw.mods.fml.common.registry.GameRegistry;
public class IndustrialStoneBlocksRecipes {
public static void init () {
registerRecipes();
}
public static void registerRecipes() {
// Industrial Cobblestone
GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockIndustrialStone, 8, 3),
new Object[] { "XXX", "XCX", "XXX", 'X', Block.cobblestone, 'C', new ItemStack (Item.coal, 1, 1)});
// Industrial Stone
FurnaceRecipes.smelting().addSmelting(ResonantInduction.blockIndustrialStone.blockID,3, new ItemStack(ResonantInduction.blockIndustrialStone, 1, 5), 5);
// Industrial Cracked Stone
FurnaceRecipes.smelting().addSmelting(ResonantInduction.blockIndustrialStone.blockID, new ItemStack(ResonantInduction.blockIndustrialStone, 1, 4), 5);
// Industrial Mossy Stone
GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockIndustrialStone, 8, 7),
new Object[] { "XXX", "XVX", "XXX", 'X', new ItemStack(ResonantInduction.blockIndustrialStone), 'V', Block.vine});
// Industrial Brick
GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockIndustrialStone, 4),
new Object[] { "XX ", "XX ", " ", 'X', new ItemStack(ResonantInduction.blockIndustrialStone, 1, 5)});
// Industrial Double Slab Brick
GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockIndustrialStone, 4, 1),
new Object[] { "XXX", "XXX", "XX ", 'X', Block.stoneSingleSlab});
// Industrial Chiseled Brick
GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockIndustrialStone,8, 2),
new Object[] { "XXX", "X X", "XXX", 'X', new ItemStack(ResonantInduction.blockIndustrialStone, 1, 5)});
// Dark Iron Block Recipe
GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockIndustrialStone, 5, 10),
new Object[] { "IXI", "XXX", "IXI", 'X', new ItemStack(ResonantInduction.blockIndustrialStone, 1, 5), 'I', Item.ingotIron});
// Tinted Steel Block Recipe
/*GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockDarkStone, 4, 9),
new Object[] { "XSX", "SSS", "XSX", 'X', new ItemStack(ResonantInduction.blockDarkStone, 1, 5), 'S', new ItemStack(, ResonantEngine.idItemIngotSteel)});*/
// Steel Block Recipe
/*GameRegistry.addRecipe(new ItemStack(ResonantInduction.blockDarkStone,5, 8),
new Object[] { "SXS", "XXX", "SXS", 'X', new ItemStack(ResonantInduction.blockDarkStone, 1, 5), 'S', new ItemStack(, ResonantEngine.idItemIngotSteel)});*/
}
}

View file

@ -1,4 +1,4 @@
package resonantinduction.core.blocks;
package resonantinduction.core.content;
import java.util.List;

View file

@ -17,17 +17,17 @@ import net.minecraft.nbt.NBTTagList;
import resonant.lib.utility.LanguageUtility;
import resonant.lib.utility.nbt.NBTUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantTab;
import resonantinduction.core.Settings;
import resonantinduction.core.TabRI;
public class ItemImprint extends Item
{
public ItemImprint(int id)
{
super(Settings.CONFIGURATION.getItem("imprint", id).getInt());
super(Settings.config.getItem("imprint", id).getInt());
this.setUnlocalizedName(Reference.PREFIX + "imprint");
this.setTextureName(Reference.PREFIX + "imprint");
this.setCreativeTab(TabRI.DEFAULT);
this.setCreativeTab(ResonantTab.DEFAULT);
this.setHasSubtypes(true);
this.setMaxStackSize(1);
}

View file

@ -13,7 +13,7 @@ import net.minecraftforge.oredict.OreDictionary;
import resonant.lib.utility.LanguageUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.TabRI;
import resonantinduction.core.ResonantTab;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@ -24,15 +24,11 @@ import cpw.mods.fml.relauncher.SideOnly;
*/
public class ItemOreResource extends Item
{
private int blockID = ResonantInduction.blockRefinedDust.blockID;
;
public ItemOreResource(int id, String name)
private Block block = ResonantInduction.blockRefinedDust;
public ItemOreResource()
{
super(id);
setUnlocalizedName(Reference.PREFIX + name);
setTextureName(Reference.PREFIX + name);
setCreativeTab(TabRI.CORE);
setHasSubtypes(true);
setMaxDamage(0);
}

View file

@ -51,6 +51,7 @@ import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
/**
* Generates the resources based on available ores in Resonant Induction
* @author Calclavia
*/
public class ResourceGenerator implements IVirtualObject
@ -402,9 +403,9 @@ public class ResourceGenerator implements IVirtualObject
if (!materials.containsKey(materialName))
{
Settings.CONFIGURATION.load();
boolean allowMaterial = Settings.CONFIGURATION.get("Resource_Generator", "Enable " + oreDictName, true).getBoolean(true);
Settings.CONFIGURATION.save();
Settings.config.load();
boolean allowMaterial = Settings.config.get("Resource_Generator", "Enable " + oreDictName, true).getBoolean(true);
Settings.config.save();
if (!allowMaterial || OreDetectionBlackList.isIngotBlackListed("ingot" + oreDictName) || OreDetectionBlackList.isOreBlackListed("ore" + oreDictName))
{

View file

@ -17,7 +17,7 @@ import net.minecraftforge.fluids.BlockFluidFinite;
import net.minecraftforge.fluids.FluidRegistry;
import resonant.lib.utility.LanguageUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.TabRI;
import resonantinduction.core.ResonantTab;
import resonantinduction.core.resource.ItemOreResource;
import resonantinduction.core.resource.ResourceGenerator;
import cpw.mods.fml.relauncher.Side;
@ -37,7 +37,7 @@ public class ItemOreResourceBucket extends Item
setMaxStackSize(1);
setUnlocalizedName(Reference.PREFIX + name);
setTextureName(Reference.PREFIX + name);
setCreativeTab(TabRI.CORE);
setCreativeTab(ResonantTab.CORE);
setHasSubtypes(true);
setMaxDamage(0);
}

View file

@ -13,8 +13,8 @@ import resonant.lib.network.PacketHandler;
import resonant.lib.recipe.UniversalRecipe;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.ResonantTab;
import resonantinduction.core.Settings;
import resonantinduction.core.TabRI;
import resonantinduction.core.resource.ItemResourcePart;
import resonantinduction.electrical.armbot.BlockArmbot;
import resonantinduction.electrical.armbot.TileArmbot;
@ -69,7 +69,7 @@ public class Electrical
@Mod.Metadata(ID)
public static ModMetadata metadata;
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.CONFIGURATION, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(TabRI.DEFAULT);
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.config, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(ResonantTab.DEFAULT);
// Energy
public static Item itemWire;
@ -109,7 +109,7 @@ public class Electrical
modproxies = new ProxyHandler();
NetworkRegistry.instance().registerGuiHandler(this, proxy);
Settings.CONFIGURATION.load();
Settings.config.load();
// Energy
itemWire = contentRegistry.createItem(ItemWire.class);
itemMultimeter = contentRegistry.createItem(ItemMultimeter.class);
@ -135,7 +135,7 @@ public class Electrical
//Railings
//itemRailing = contentRegistry.createItem(ItemItemRailing.class);
Settings.CONFIGURATION.save();
Settings.config.save();
OreDictionary.registerOre("wire", itemWire);
OreDictionary.registerOre("motor", blockMotor);
@ -143,7 +143,7 @@ public class Electrical
OreDictionary.registerOre("batteryBox", ItemBlockBattery.setTier(new ItemStack(blockBattery, 1, 0), (byte) 0));
/** Set reference itemstacks */
TabRI.ITEMSTACK = new ItemStack(itemTransformer);
ResonantTab.ITEMSTACK = new ItemStack(itemTransformer);
for (EnumWireMaterial material : EnumWireMaterial.values())
{

View file

@ -41,7 +41,7 @@ public class TaskUse extends TaskBaseArmbot
{
if (super.onUpdate() == ProcessReturn.CONTINUE)
{
Block block = Block.blocksList[((IArmbot) this.program.getMachine()).getHandPos().getBlockID(this.program.getMachine().getLocation().left())];
Block block = Block.blocksList[((IArmbot) this.program.getMachine()).getHandPos().getBlock(this.program.getMachine().getLocation().left())];
TileEntity targetTile = ((IArmbot) this.program.getMachine()).getHandPos().getTileEntity(this.program.getMachine().getLocation().left());
if (targetTile != null)

View file

@ -16,7 +16,7 @@ import resonant.lib.render.EnumColor;
import resonant.lib.utility.LanguageUtility;
import resonantinduction.core.MultipartUtility;
import resonantinduction.core.Reference;
import resonantinduction.core.TabRI;
import resonantinduction.core.ResonantTab;
import resonantinduction.electrical.wire.flat.PartFlatWire;
import resonantinduction.electrical.wire.flat.RenderFlatWire;
import resonantinduction.electrical.wire.framed.PartFramedWire;
@ -39,7 +39,7 @@ public class ItemWire extends JItemMultiPart
super(id);
this.setUnlocalizedName(Reference.PREFIX + "wire");
this.setTextureName(Reference.PREFIX + "wire");
this.setCreativeTab(TabRI.DEFAULT);
this.setCreativeTab(ResonantTab.DEFAULT);
this.setHasSubtypes(true);
this.setMaxDamage(0);
}

View file

@ -1,5 +1,6 @@
package resonantinduction.mechanical;
import resonantinduction.core.ResonantTab;
import resonantinduction.mechanical.belt.BlockConveyorBelt;
import resonantinduction.mechanical.belt.TileConveyorBelt;
import resonantinduction.mechanical.energy.grid.MechanicalNode;
@ -32,7 +33,6 @@ import resonant.lib.recipe.UniversalRecipe;
import resonantinduction.core.Reference;
import resonantinduction.core.ResonantInduction;
import resonantinduction.core.Settings;
import resonantinduction.core.TabRI;
import resonantinduction.core.interfaces.IMechanicalNode;
import resonantinduction.mechanical.energy.turbine.BlockWaterTurbine;
import resonantinduction.mechanical.energy.turbine.BlockWindTurbine;
@ -76,7 +76,7 @@ public class Mechanical
@Mod.Metadata(ID)
public static ModMetadata metadata;
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.CONFIGURATION, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(TabRI.DEFAULT);
public static final ContentRegistry contentRegistry = new ContentRegistry(Settings.config, Settings.idManager, ID).setPrefix(Reference.PREFIX).setTab(ResonantTab.DEFAULT);
// Energy
public static Item itemGear;
@ -114,7 +114,7 @@ public class Mechanical
BlockCreativeBuilder.register(new SchematicWaterTurbine());
NodeRegistry.register(IMechanicalNode.class, MechanicalNode.class);
Settings.CONFIGURATION.load();
Settings.config.load();
itemGear = contentRegistry.createItem(ItemGear.class);
itemGearShaft = contentRegistry.createItem(ItemGearShaft.class);
@ -141,9 +141,9 @@ public class Mechanical
blockTilePlacer = contentRegistry.newBlock(TilePlacer.class);
proxy.preInit();
Settings.CONFIGURATION.save();
Settings.config.save();
TabRI.ITEMSTACK = new ItemStack(blockGrinderWheel);
ResonantTab.ITEMSTACK = new ItemStack(blockGrinderWheel);
PacketAnnotation.register(TileWindTurbine.class);
PacketAnnotation.register(TileWaterTurbine.class);