use of gregapi.network.NetworkHandler in project gregtech6 by GregTech6.
the class GT_API method onModPreInit2.
@Override
@SuppressWarnings({ "resource", "deprecation" })
public void onModPreInit2(FMLPreInitializationEvent aEvent) {
File tFile = new File(DirectoriesGT.CONFIG_GT, "IDs.cfg");
if (!tFile.exists())
tFile = new File(DirectoriesGT.CONFIG_GT, "ids.cfg");
Config.sConfigFileIDs = new Configuration(tFile);
Config.sConfigFileIDs.save();
ConfigsGT.GREGTECH = new Config("GregTech.cfg").setUseDefaultInNames(F);
ConfigsGT.RECIPES = new Config("Recipes.cfg");
ConfigsGT.WORLDGEN = new Config("WorldGenerationNew.cfg");
ConfigsGT.WORLDGEN_GT5 = new Config("old_barely_used_gt5_style_garbage_worldgen.cfg");
ConfigsGT.MATERIAL = new Config("Materials.cfg");
ConfigsGT.OREPROCESSING = new Config("OreProcessing.cfg");
// Deprecated Config Files.
ConfigsGT.OVERPOWERED = ConfigsGT.MACHINES = ConfigsGT.SPECIAL = ConfigsGT.GREGTECH;
tFile = new File(DirectoriesGT.CONFIG_GT, "Stacksizes.cfg");
if (!tFile.exists())
tFile = new File(DirectoriesGT.CONFIG_GT, "stacksizes.cfg");
Configuration tStackConfig = new Configuration(tFile);
tFile = new File(DirectoriesGT.LOGS, "gregtech.log");
if (!tFile.exists())
try {
tFile.createNewFile();
} catch (Throwable e) {
/**/
}
List<String> tList = ((LogBuffer) OUT).mBufferedLog;
try {
OUT = new PrintStream(tFile);
} catch (Throwable e) {
OUT = System.out;
}
for (String tString : tList) OUT.println(tString);
if (ConfigsGT.GREGTECH.get("general", "LoggingErrors", T)) {
tList = ((LogBuffer) ERR).mBufferedLog;
ERR = OUT;
for (String tString : tList) ERR.println(tString);
} else {
OUT.println("**********************************************************************");
OUT.println("* WARNING: ERROR LOGGING HAS BEEN DISABLED FOR THIS LOG FILE *");
OUT.println("**********************************************************************");
}
tFile = new File(DirectoriesGT.CONFIG_GT, "materiallist.log");
if (!tFile.exists()) {
try {
tFile.createNewFile();
} catch (Throwable e) {
/**/
}
}
try {
MAT_LOG = new PrintStream(tFile);
MAT_LOG.println("**********************************************************************");
MAT_LOG.println("* This is the complete List of usable GregTech Materials *");
MAT_LOG.println("**********************************************************************");
} catch (Throwable e) {
/**/
}
tFile = new File(DirectoriesGT.LOGS, "oredict.log");
if (!tFile.exists()) {
try {
tFile.createNewFile();
} catch (Throwable e) {
/**/
}
}
try {
tList = ((LogBuffer) ORD).mBufferedLog;
ORD = new PrintStream(tFile);
ORD.println("**********************************************************************");
ORD.println("* This is the complete Log of the GregTech OreDictionary Handler *");
ORD.println("**********************************************************************");
for (String tString : tList) ORD.println(tString);
} catch (Throwable e) {
/**/
}
if (ConfigsGT.GREGTECH.get("general", "LoggingPlayerActivity", !CODE_CLIENT)) {
tFile = new File(DirectoriesGT.LOGS, "playeractivity_" + (System.currentTimeMillis() / 60000) + ".log");
if (!tFile.exists()) {
try {
tFile.createNewFile();
} catch (Throwable e) {
/**/
}
}
try {
mPlayerLogger = new LoggerPlayerActivity(new PrintStream(tFile));
} catch (Throwable e) {
/**/
}
}
ConfigsGT.CLIENT = new Config(DirectoriesGT.MINECRAFT, "GregTech.cfg");
D1 = ConfigsGT.CLIENT.get("debug", "logs", F);
D2 = ConfigsGT.CLIENT.get("debug", "oredict", F);
D3 = ConfigsGT.CLIENT.get("debug", "misc", F);
CLIENT_BLOCKUPDATE_SOUNDS = ConfigsGT.CLIENT.get("debug", "block_update_sounds", F);
if (ConfigsGT.CLIENT.get("debug", "april_fools", F))
APRIL_FOOLS = T;
if (ConfigsGT.CLIENT.get("debug", "xmas_july", F))
XMAS_IN_JULY = T;
if (ConfigsGT.CLIENT.get("debug", "xmas_december", F))
XMAS_IN_DECEMBER = T;
if (APRIL_FOOLS) {
MT.W.setLocal("Wolframium");
MT.V.setLocal("Vandalium");
MT.B.setLocal("Boring");
MT.S.setLocal("Sulphur");
MT.K.setLocal("Kalium");
MT.Na.setLocal("Natrium");
MT.Ar.setLocal("Aragon");
MT.Al.setLocal("Aluminum");
MT.Ni.setLocal("Ferrous Metal");
MT.Pt.setLocal("Shiny Metal");
MT.Mithril.setLocal("Mana Infused Metal");
MT.Hg.setLocal("Quicksilver");
MT.Mo.setLocal("Molly-B");
MT.Sb.setLocal("Anti-Money");
MT.Tc.setLocal("Gregorium");
MT.Si.setLocal("Silicone");
MT.Cr.setLocal("Chrome");
MT.Cu.setLocal("Cooper");
MT.AnnealedCopper.setLocal("Anilled Cooper");
MT.Mg.setLocal("Manganesium");
MT.Mn.setLocal("Animenese");
MT.As.setLocal("Arse Nick");
MT.Br.setLocal("Bro, that's mine");
MT.Kr.setLocal("Kryptonite");
MT.Bi.setLocal("Biffmiff");
MT.Sg.setLocal("Resistance is Futile");
MT.Zr.setLocal("Diamond");
MT.Au.setLocal("Pyrite");
MT.Pyrite.setLocal("Gold");
MT.Fe.setLocal("Irun");
MT.IronWood.setLocal("Irunwood");
MT.ShadowIron.setLocal("Shade Irun");
MT.DarkIron.setLocal("Dank Irun");
MT.MeteoricIron.setLocal("Metaur Irun");
MT.GildedIron.setLocal("Guild Irun");
MT.WroughtIron.setLocal("Wrecked Irun");
MT.Steel.setLocal("Style");
MT.RedSteel.setLocal("Rad Style");
MT.BlueSteel.setLocal("Blu Style");
MT.BlackSteel.setLocal("Afroamerican Style");
MT.MeteoricSteel.setLocal("Metaur Style");
MT.MeteoricRedSteel.setLocal("Metaur Rad Style");
MT.MeteoricBlueSteel.setLocal("Metaur Blu Style");
MT.MeteoricBlackSteel.setLocal("Metaur Afroamerican Style");
MT.DamascusSteel.setLocal("Dank Style");
MT.VanadiumSteel.setLocal("Vandalium Style");
MT.TungstenSteel.setLocal("Wolf Style");
MT.ShadowSteel.setLocal("Shade Style");
MT.Steeleaf.setLocal("Style Leave");
MT.Knightmetal.setLocal("Night Metal");
MT.FierySteel.setLocal("Fury Style");
MT.Thaumium.setLocal("Thaumanominum");
MT.DarkThaumium.setLocal("Dank Thaumanominum");
MT.Coal.setLocal("Cool");
MT.Charcoal.setLocal("Charred Cole");
MT.Lapis.setLocal("Le Piss");
MT.Redstone.setLocal("Blingstone");
MT.Glowstone.setLocal("Klostein");
MT.Emerald.setLocal("Chaos Emerald");
MT.Craponite.setLocal("Pink Diamond");
MT.Diamond.setLocal("Sapphire");
MT.DiamondPink.setLocal("Craponite");
MT.Bedrock.setLocal("Sofarock");
MT.Plastic.setLocal("LEGO");
MT.Asbestos.setLocal("Bestos");
MT.AncientDebris.setLocal("Cinnabun");
MT.Cinnamon.setLocal("Ancient Debris");
MT.WOODS.Cinnamon.setLocal("Ancient Debris");
MT.Rb.setLocal("Ruby");
MT.Ruby.setLocal("Red Sapphire");
MT.KNO3.setLocal("Niter");
MT.NaNO3.setLocal("Nitre");
MT.Glyceryl.setLocal("Nitro");
MT.Gunpowder.setLocal("Boompowder");
MT.Lubricant.setLocal("Lube");
MT.H2SO4.setLocal("Sulphuric Acid");
MT.H2S2O7.setLocal("Disulphuric Acid");
MT.STONES.Greenschist.setLocal("Green Shit");
MT.STONES.Blueschist.setLocal("Blue Shit");
MT.Nikolite.setLocal("Bluestone");
MT.PigIron.setLocal("Ferrobacon");
MT.TinAlloy.setLocal("Tin*");
MT.Bronze.setLocal("Tinkerers Alloy");
MT.BlackBronze.setLocal("Afroamerican Tinkerers Alloy");
MT.Constantan.setLocal("Cupronickel");
MT.Ge.setLocal("Platosmium");
MT.Amazonite.setLocal("Bezosite");
MT.NetherQuartz.setLocal("Weather Quartz");
MT.MilkyQuartz.setLocal("Milk Quartz");
MT.CertusQuartz.setLocal("Citrus Quartz");
MT.ChargedCertusQuartz.setLocal("Charged Citrus Quartz");
MT.Firestone.setLocal("Hot Garbage");
MT.UUMatter.setLocal("UwU-Matter");
MT.UUAmplifier.setLocal("UwU-Amplifier");
MT.OREMATS.Galena.setLocal("Silverlead");
MT.OREMATS.Huebnerite.setLocal("Boobnerite");
MT.OREMATS.Bromargyrite.setLocal("Bromagnerite");
MT.OREMATS.Chalcopyrite.setLocal("Chackapackerite");
for (OreDictMaterial tMaterial : OreDictMaterial.MATERIAL_MAP.values()) if (tMaterial.mNameLocal.toLowerCase().contains("wood"))
tMaterial.setLocal(tMaterial.mNameLocal + " >:] nice");
}
if (D1) {
tList = ((LogBuffer) DEB).mBufferedLog;
DEB = OUT;
for (String tString : tList) DEB.println(tString);
}
for (OreDictPrefix tPrefix : OreDictPrefix.VALUES) if (!tPrefix.contains(TD.Prefix.PREFIX_UNUSED)) {
tPrefix.setConfigStacksize(tStackConfig.get("stacksizes", tPrefix.mNameInternal + "_" + tPrefix.mDefaultStackSize, tPrefix.mDefaultStackSize).getInt());
}
tStackConfig.save();
SURVIVAL_INTO_ADVENTURE_MODE = ConfigsGT.GREGTECH.get("general", "forceAdventureMode", F);
ADVENTURE_MODE_KIT = ConfigsGT.GREGTECH.get("general", "AdventureModeStartingKit", !MD.GT.mLoaded);
HUNGER_BY_INVENTORY_WEIGHT = ConfigsGT.GREGTECH.get("general", "AFK_Hunger", MD.GT.mLoaded);
TOOL_BREAK_FATIQUE = ConfigsGT.GREGTECH.get("general", "ToolBreakFatique", T);
INVENTORY_UNIFICATION = ConfigsGT.GREGTECH.get("general", "InventoryUnification", T);
XP_ORB_COMBINING = ConfigsGT.GREGTECH.get("general", "XP_Orb_Combining", T);
CONFIG_HARDNESS_MULTIPLIER_SAND = ConfigsGT.GREGTECH.get("general", "HardnessMultiplier_Sand", 1);
CONFIG_HARDNESS_MULTIPLIER_ROCK = ConfigsGT.GREGTECH.get("general", "HardnessMultiplier_Rock", 1);
CONFIG_HARDNESS_MULTIPLIER_ORES = ConfigsGT.GREGTECH.get("general", "HardnessMultiplier_Ores", 1);
ITEM_DESPAWN_TIME = ConfigsGT.GREGTECH.get("general", "ItemDespawnTime", 6000);
TREE_GROWTH_TIME = ConfigsGT.GREGTECH.get("general", "Tree_Growth_Time", 1);
ENTITY_CRAMMING = ConfigsGT.GREGTECH.get("general", "MaxEqualEntitiesAtOneSpot", 3);
DRINKS_ALWAYS_DRINKABLE = ConfigsGT.GREGTECH.get("general", "drinks_always_drinkable", F);
EMIT_EU_AS_RF = ConfigsGT.GREGTECH.get("general", "Emit_EU_as_RF_from_Blocks", F);
NERFED_WOOD = ConfigsGT.GREGTECH.get("general", "WoodNeedsSawForCrafting", T);
FORCE_GRAVEL_NO_FLINT = ConfigsGT.GREGTECH.get("general", "GravelWontDropFlint", F);
FAST_LEAF_DECAY = ConfigsGT.GREGTECH.get("general", "FastLeafDecay", T);
CONSTANT_ENERGY = ConfigsGT.GREGTECH.get("general", "UninterruptedEnergyRequirement", T);
FOOD_OVERDOSE_DEATH = ConfigsGT.GREGTECH.get("general", "DeathByOverdosingCertainFoods", T);
NUTRITION_SYSTEM = ConfigsGT.GREGTECH.get("general", "NutritionSystem", T);
OBSTRUCTION_CHECKS = ConfigsGT.GREGTECH.get("general", "ObstructionChecks", T);
OWNERSHIP_RESET = ConfigsGT.GREGTECH.get("general", "ResetPlayerOwnershipOfGT6Blocks", F);
SPAWN_ZONE_MOB_PROTECTION = ConfigsGT.GREGTECH.get("general", "PreventMobSpawnsCloseToSpawn", T);
SPAWN_NO_BATS = ConfigsGT.GREGTECH.get("general", "PreventBatSpawnsOnNonVanillaStone", T);
SPAWN_HOSTILES_ONLY_IN_DARKNESS = ConfigsGT.GREGTECH.get("general", "PreventMobSpawnsAboveLightLevel0", T);
DISABLE_GT6_CRAFTING_RECIPES = ConfigsGT.GREGTECH.get("general", "DisableGT6CraftingRecipesDEBUG", F);
TOOL_SOUNDS = ConfigsGT.GREGTECH.get("general", "sound_tools", T);
MOBS_DROP_LEAD = ConfigsGT.GREGTECH.get("general", "mobs_drop_lead_instead_of_iron", T);
MOBS_DROP_MEAT = ConfigsGT.GREGTECH.get("general", "mobs_drop_variety_meats", T);
MOBS_DROP_JUNK = ConfigsGT.GREGTECH.get("general", "mobs_drop_random_junk", T);
MOBS_DROP_BOOK = ConfigsGT.GREGTECH.get("general", "mobs_drop_books_and_manuals", T);
MOBS_DROP_NAME = ConfigsGT.GREGTECH.get("general", "mobs_drop_nametags_when_named", T);
ZOMBIES_DIG_WITH_TOOLS = ConfigsGT.GREGTECH.get("general", "Zombies_Dig_With_Tools", F);
ZOMBIES_DIG_TILEENTITIES = ConfigsGT.GREGTECH.get("general", "Zombies_Dig_TileEntities", F);
ZOMBIES_HOLD_PICKAXES = ConfigsGT.GREGTECH.get("general", "Zombies_Hold_Pickaxes", F);
ZOMBIES_HOLD_TNT = ConfigsGT.GREGTECH.get("general", "Zombies_Hold_TNT", F);
ZOMBIES_IGNITE_HELD_TNT = ConfigsGT.GREGTECH.get("general", "Zombies_Ignite_Held_TNT", F);
UT.Sounds.MULTITHREADED = ConfigsGT.GREGTECH.get("general", "sound_multi_threading", F);
ENABLE_ADDING_IC2_MACERATOR_RECIPES = ConfigsGT.GREGTECH.get("ic2", "EnableAddingMaceratorRecipes", T);
ENABLE_ADDING_IC2_EXTRACTOR_RECIPES = ConfigsGT.GREGTECH.get("ic2", "EnableAddingExtractorRecipes", T);
ENABLE_ADDING_IC2_COMPRESSOR_RECIPES = ConfigsGT.GREGTECH.get("ic2", "EnableAddingCompressorRecipes", T);
ENABLE_ADDING_IC2_OREWASHER_RECIPES = ConfigsGT.GREGTECH.get("ic2", "EnableAddingOreWasherRecipes", T);
ENABLE_ADDING_IC2_CENTRIFUGE_RECIPES = ConfigsGT.GREGTECH.get("ic2", "EnableAddingThermalCentrifugeRecipes", T);
if (!ConfigsGT.GREGTECH.get("general", "UseTFCAttackMultiplierWhenLoaded", T) || TFC_DAMAGE_MULTIPLIER < 1 || (!MD.TFC.mLoaded && !MD.TFCP.mLoaded))
TFC_DAMAGE_MULTIPLIER = 1;
if (MD.IC2C.mLoaded) {
DISABLE_ALL_IC2_MACERATOR_RECIPES = F;
ENABLE_ADDING_IC2_MACERATOR_RECIPES = T;
DISABLE_ALL_IC2_EXTRACTOR_RECIPES = F;
ENABLE_ADDING_IC2_EXTRACTOR_RECIPES = T;
DISABLE_ALL_IC2_COMPRESSOR_RECIPES = F;
ENABLE_ADDING_IC2_COMPRESSOR_RECIPES = T;
DISABLE_ALL_IC2_OREWASHER_RECIPES = F;
ENABLE_ADDING_IC2_OREWASHER_RECIPES = F;
DISABLE_ALL_IC2_CENTRIFUGE_RECIPES = F;
ENABLE_ADDING_IC2_CENTRIFUGE_RECIPES = F;
} else if (MD.IC2.mLoaded) {
DISABLE_ALL_IC2_MACERATOR_RECIPES = ConfigsGT.GREGTECH.get("ic2", "DisableAllMaceratorRecipes", F);
if (DISABLE_ALL_IC2_MACERATOR_RECIPES)
ENABLE_ADDING_IC2_MACERATOR_RECIPES = F;
DISABLE_ALL_IC2_EXTRACTOR_RECIPES = ConfigsGT.GREGTECH.get("ic2", "DisableAllExtractorRecipes", F);
if (DISABLE_ALL_IC2_EXTRACTOR_RECIPES)
ENABLE_ADDING_IC2_EXTRACTOR_RECIPES = F;
DISABLE_ALL_IC2_COMPRESSOR_RECIPES = ConfigsGT.GREGTECH.get("ic2", "DisableAllCompressorRecipes", F);
if (DISABLE_ALL_IC2_COMPRESSOR_RECIPES)
ENABLE_ADDING_IC2_COMPRESSOR_RECIPES = F;
DISABLE_ALL_IC2_OREWASHER_RECIPES = ConfigsGT.GREGTECH.get("ic2", "DisableAllOreWasherRecipes", F);
if (DISABLE_ALL_IC2_OREWASHER_RECIPES)
ENABLE_ADDING_IC2_OREWASHER_RECIPES = F;
DISABLE_ALL_IC2_CENTRIFUGE_RECIPES = ConfigsGT.GREGTECH.get("ic2", "DisableAllThermalCentrifugeRecipes", F);
if (DISABLE_ALL_IC2_CENTRIFUGE_RECIPES)
ENABLE_ADDING_IC2_CENTRIFUGE_RECIPES = F;
} else {
DISABLE_ALL_IC2_MACERATOR_RECIPES = F;
ENABLE_ADDING_IC2_MACERATOR_RECIPES = F;
DISABLE_ALL_IC2_EXTRACTOR_RECIPES = F;
ENABLE_ADDING_IC2_EXTRACTOR_RECIPES = F;
DISABLE_ALL_IC2_COMPRESSOR_RECIPES = F;
ENABLE_ADDING_IC2_COMPRESSOR_RECIPES = F;
DISABLE_ALL_IC2_OREWASHER_RECIPES = F;
ENABLE_ADDING_IC2_OREWASHER_RECIPES = F;
DISABLE_ALL_IC2_CENTRIFUGE_RECIPES = F;
ENABLE_ADDING_IC2_CENTRIFUGE_RECIPES = F;
}
if (ConfigsGT.GREGTECH.get("general", "disable_STDOUT", F))
System.out.close();
if (ConfigsGT.GREGTECH.get("general", "disable_STDERR", F))
System.err.close();
if (ConfigsGT.GREGTECH.get("general", "hardermobspawners", T))
Blocks.mob_spawner.setHardness(500.0F);
if (ConfigsGT.GREGTECH.get("general", "blastresistantmobspawners", T))
Blocks.mob_spawner.setResistance(6000000.0F);
else
Blocks.mob_spawner.setResistance(60);
FIRE_EXPLOSIONS = ConfigsGT.GREGTECH.get("machines", "explode_by_fire", T);
RAIN_EXPLOSIONS = ConfigsGT.GREGTECH.get("machines", "explode_by_rain", T);
WATER_EXPLOSIONS = ConfigsGT.GREGTECH.get("machines", "explode_by_water", T);
THUNDER_EXPLOSIONS = ConfigsGT.GREGTECH.get("machines", "explode_by_thunder", T);
OVERCHARGE_EXPLOSIONS = ConfigsGT.GREGTECH.get("machines", "explode_by_overload", F);
FIRE_BREAKING = ConfigsGT.GREGTECH.get("machines", "break_by_fire", T);
RAIN_BREAKING = ConfigsGT.GREGTECH.get("machines", "break_by_rain", T);
WATER_BREAKING = ConfigsGT.GREGTECH.get("machines", "break_by_water", T);
THUNDER_BREAKING = ConfigsGT.GREGTECH.get("machines", "break_by_thunder", T);
OVERCHARGE_BREAKING = ConfigsGT.GREGTECH.get("machines", "break_by_overload", F);
if (FIRE_EXPLOSIONS)
FIRE_BREAKING = T;
if (RAIN_EXPLOSIONS)
RAIN_BREAKING = T;
if (WATER_EXPLOSIONS)
WATER_BREAKING = T;
if (THUNDER_EXPLOSIONS)
THUNDER_BREAKING = T;
if (OVERCHARGE_EXPLOSIONS)
OVERCHARGE_BREAKING = T;
if (CONFIG_HARDNESS_MULTIPLIER_SAND <= 0.0)
CONFIG_HARDNESS_MULTIPLIER_SAND = 1.0;
if (CONFIG_HARDNESS_MULTIPLIER_ROCK <= 0.0)
CONFIG_HARDNESS_MULTIPLIER_ROCK = 1.0;
if (CONFIG_HARDNESS_MULTIPLIER_ORES <= 0.0)
CONFIG_HARDNESS_MULTIPLIER_ORES = 1.0;
HARDNESS_MULTIPLIER_SAND = CONFIG_HARDNESS_MULTIPLIER_SAND;
HARDNESS_MULTIPLIER_ROCK = CONFIG_HARDNESS_MULTIPLIER_ROCK;
HARDNESS_MULTIPLIER_ORES = CONFIG_HARDNESS_MULTIPLIER_ORES;
if (ConfigsGT.GREGTECH.get("compat", "IC2Classic", T))
ICompat.COMPAT_CLASSES.add((ICompat) UT.Reflection.callConstructor("gregapi.compat.industrialcraft.CompatIC2C", 0, null, D2));
if (ConfigsGT.GREGTECH.get("compat", "IC2EnergyItems", T))
ICompat.COMPAT_CLASSES.add(COMPAT_EU_ITEM = (ICompatIC2EUItem) UT.Reflection.callConstructor("gregapi.compat.industrialcraft.CompatIC2EUItem", 0, null, D2));
if (ConfigsGT.GREGTECH.get("compat", "IndustrialCraft2", T))
ICompat.COMPAT_CLASSES.add(COMPAT_IC2 = (ICompatIC2) UT.Reflection.callConstructor("gregapi.compat.industrialcraft.CompatIC2", 0, null, D2));
if (ConfigsGT.GREGTECH.get("compat", "ThaumCraft", T))
ICompat.COMPAT_CLASSES.add(COMPAT_TC = (ICompatTC) UT.Reflection.callConstructor("gregapi.compat.thaumcraft.CompatTC", 0, null, D2));
if (ConfigsGT.GREGTECH.get("compat", "BuildCraft", T))
ICompat.COMPAT_CLASSES.add(COMPAT_BC = (ICompatBC) UT.Reflection.callConstructor("gregapi.compat.buildcraft.CompatBC", 0, null, D2));
if (ConfigsGT.GREGTECH.get("compat", "ComputerCraft", T))
ICompat.COMPAT_CLASSES.add(COMPAT_CC = (ICompatCC) UT.Reflection.callConstructor("gregapi.compat.computercraft.CompatCC", 0, null, D2));
if (ConfigsGT.GREGTECH.get("compat", "Forestry", T))
ICompat.COMPAT_CLASSES.add(COMPAT_FR = (ICompatFR) UT.Reflection.callConstructor("gregapi.compat.forestry.CompatFR", 0, null, D2));
if (ConfigsGT.GREGTECH.get("compat", "GalactiCraft", T))
ICompat.COMPAT_CLASSES.add(COMPAT_GC = (ICompatGC) UT.Reflection.callConstructor("gregapi.compat.galacticraft.CompatGC", 0, null, D2));
if (MD.TC.mLoaded)
try {
ThaumcraftApi.objectTags.isEmpty();
} catch (NoSuchFieldError e) {
throw new RuntimeException("Please uninstall ThaumicFixer, GregTech-6 itself by now fixes the Thaumometer Lag Issue in a far better and less 'Thaumcraft-Addons breaking' way than Thaumic Fixer.");
}
SHOW_HIDDEN_ITEMS = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "HiddenGTItems", F);
SHOW_HIDDEN_MATERIALS = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "HiddenGTMaterials", F);
SHOW_HIDDEN_PREFIXES = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "HiddenGTPrefixes", F);
SHOW_MICROBLOCKS = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "MicroBlocks", F);
SHOW_BUMBLEBEES = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "Bumblebees", F);
SHOW_ORE_BLOCK_PREFIXES = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "OreBlocks", F);
SHOW_INTERNAL_NAMES = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "InternalNames", F);
SHOW_CHEM_FORMULAS = ConfigsGT.CLIENT.get(ConfigCategories.visibility, "ChemTooltips", T);
ITexture.Util.GT_ALPHA_BLENDING = ConfigsGT.CLIENT.get(ConfigCategories.general, "useGTAlphaBlending", ITexture.Util.GT_ALPHA_BLENDING);
ITexture.Util.MC_ALPHA_BLENDING = ConfigsGT.CLIENT.get(ConfigCategories.general, "useMCAlphaBlending", ITexture.Util.MC_ALPHA_BLENDING);
GT6WorldGenerator.PFAA = (ConfigsGT.WORLDGEN.get(ConfigCategories.general, "AutoDetectPFAA", T) && MD.PFAA.mLoaded && MD.COG.mLoaded);
GT6WorldGenerator.TFC = (ConfigsGT.WORLDGEN.get(ConfigCategories.general, "AutoDetectTFC", T) && (MD.TFC.mLoaded || MD.TFCP.mLoaded));
// Register Crafting Recipe Classes.
RecipeSorter.register("gregtech:shaped", AdvancedCraftingShaped.class, RecipeSorter.Category.SHAPED, "after:minecraft:shaped before:minecraft:shapeless");
RecipeSorter.register("gregtech:shapeless", AdvancedCraftingShapeless.class, RecipeSorter.Category.SHAPELESS, "after:gregtech:shaped after:minecraft:shapeless");
RecipeSorter.register("gregtech:1ToY", AdvancedCrafting1ToY.class, RecipeSorter.Category.SHAPELESS, "after:gregtech:shaped after:gregtech:shapeless");
RecipeSorter.register("gregtech:XToY", AdvancedCraftingXToY.class, RecipeSorter.Category.SHAPELESS, "after:gregtech:shaped after:gregtech:1ToY");
RecipeSorter.register("gregtech:tool", AdvancedCraftingTool.class, RecipeSorter.Category.SHAPELESS, "after:gregtech:shaped after:gregtech:XToY");
// A Default Packet Handler for some of the already existing Code. Yes, all those Packets are generalised special cases in order to save on Bandwidth.
// [ +127] = PacketConfig
// [ +126] = PacketPrefix
// [ +125] = PacketItemStackChat
// [+112 to +119] = PacketBlockEvent
// [+104 to +111] = PacketBlockError
// [+ 72 to + 79] = PacketDeathPoint
// [-120 to + 71] = PacketSyncData
// [-128 to -121] = PacketSound
NW_API = new NetworkHandler(MD.GAPI.mID, "GAPI", new PacketConfig(), new PacketPrefix(), new PacketItemStackChat(), new PacketBlockEvent(0), new PacketBlockEvent(1), new PacketBlockEvent(2), new PacketBlockEvent(3), new PacketBlockEvent(4), new PacketBlockEvent(5), new PacketBlockEvent(6), new PacketBlockEvent(7), new PacketBlockError(0), new PacketBlockError(1), new PacketBlockError(2), new PacketBlockError(3), new PacketBlockError(4), new PacketBlockError(5), new PacketBlockError(6), new PacketBlockError(7), new PacketDeathPoint(0), new PacketDeathPoint(1), new PacketDeathPoint(2), new PacketDeathPoint(3), new PacketDeathPoint(4), new PacketDeathPoint(5), new PacketDeathPoint(6), new PacketDeathPoint(7), new PacketSound(0), new PacketSound(1), new PacketSound(2), new PacketSound(3), new PacketSound(4), new PacketSound(5), new PacketSound(6), new PacketSound(7), new PacketSyncDataName(0), new PacketSyncDataName(1), new PacketSyncDataName(2), new PacketSyncDataName(3), new PacketSyncDataName(4), new PacketSyncDataName(5), new PacketSyncDataName(6), new PacketSyncDataName(7), new PacketSyncDataByte(0), new PacketSyncDataByte(1), new PacketSyncDataByte(2), new PacketSyncDataByte(3), new PacketSyncDataByte(4), new PacketSyncDataByte(5), new PacketSyncDataByte(6), new PacketSyncDataByte(7), new PacketSyncDataShort(0), new PacketSyncDataShort(1), new PacketSyncDataShort(2), new PacketSyncDataShort(3), new PacketSyncDataShort(4), new PacketSyncDataShort(5), new PacketSyncDataShort(6), new PacketSyncDataShort(7), new PacketSyncDataInteger(0), new PacketSyncDataInteger(1), new PacketSyncDataInteger(2), new PacketSyncDataInteger(3), new PacketSyncDataInteger(4), new PacketSyncDataInteger(5), new PacketSyncDataInteger(6), new PacketSyncDataInteger(7), new PacketSyncDataLong(0), new PacketSyncDataLong(1), new PacketSyncDataLong(2), new PacketSyncDataLong(3), new PacketSyncDataLong(4), new PacketSyncDataLong(5), new PacketSyncDataLong(6), new PacketSyncDataLong(7), new PacketSyncDataByteArray(0), new PacketSyncDataByteArray(1), new PacketSyncDataByteArray(2), new PacketSyncDataByteArray(3), new PacketSyncDataByteArray(4), new PacketSyncDataByteArray(5), new PacketSyncDataByteArray(6), new PacketSyncDataByteArray(7), new PacketSyncDataIDs(0), new PacketSyncDataIDs(1), new PacketSyncDataIDs(2), new PacketSyncDataIDs(3), new PacketSyncDataIDs(4), new PacketSyncDataIDs(5), new PacketSyncDataIDs(6), new PacketSyncDataIDs(7), new PacketSyncDataByteAndIDs(0), new PacketSyncDataByteAndIDs(1), new PacketSyncDataByteAndIDs(2), new PacketSyncDataByteAndIDs(3), new PacketSyncDataByteAndIDs(4), new PacketSyncDataByteAndIDs(5), new PacketSyncDataByteAndIDs(6), new PacketSyncDataByteAndIDs(7), new PacketSyncDataShortAndIDs(0), new PacketSyncDataShortAndIDs(1), new PacketSyncDataShortAndIDs(2), new PacketSyncDataShortAndIDs(3), new PacketSyncDataShortAndIDs(4), new PacketSyncDataShortAndIDs(5), new PacketSyncDataShortAndIDs(6), new PacketSyncDataShortAndIDs(7), new PacketSyncDataIntegerAndIDs(0), new PacketSyncDataIntegerAndIDs(1), new PacketSyncDataIntegerAndIDs(2), new PacketSyncDataIntegerAndIDs(3), new PacketSyncDataIntegerAndIDs(4), new PacketSyncDataIntegerAndIDs(5), new PacketSyncDataIntegerAndIDs(6), new PacketSyncDataIntegerAndIDs(7), new PacketSyncDataLongAndIDs(0), new PacketSyncDataLongAndIDs(1), new PacketSyncDataLongAndIDs(2), new PacketSyncDataLongAndIDs(3), new PacketSyncDataLongAndIDs(4), new PacketSyncDataLongAndIDs(5), new PacketSyncDataLongAndIDs(6), new PacketSyncDataLongAndIDs(7), new PacketSyncDataByteArrayAndIDs(0), new PacketSyncDataByteArrayAndIDs(1), new PacketSyncDataByteArrayAndIDs(2), new PacketSyncDataByteArrayAndIDs(3), new PacketSyncDataByteArrayAndIDs(4), new PacketSyncDataByteArrayAndIDs(5), new PacketSyncDataByteArrayAndIDs(6), new PacketSyncDataByteArrayAndIDs(7), new PacketSyncDataIDsAndCovers(0), new PacketSyncDataIDsAndCovers(1), new PacketSyncDataIDsAndCovers(2), new PacketSyncDataIDsAndCovers(3), new PacketSyncDataIDsAndCovers(4), new PacketSyncDataIDsAndCovers(5), new PacketSyncDataIDsAndCovers(6), new PacketSyncDataIDsAndCovers(7), new PacketSyncDataByteAndIDsAndCovers(0), new PacketSyncDataByteAndIDsAndCovers(1), new PacketSyncDataByteAndIDsAndCovers(2), new PacketSyncDataByteAndIDsAndCovers(3), new PacketSyncDataByteAndIDsAndCovers(4), new PacketSyncDataByteAndIDsAndCovers(5), new PacketSyncDataByteAndIDsAndCovers(6), new PacketSyncDataByteAndIDsAndCovers(7), new PacketSyncDataShortAndIDsAndCovers(0), new PacketSyncDataShortAndIDsAndCovers(1), new PacketSyncDataShortAndIDsAndCovers(2), new PacketSyncDataShortAndIDsAndCovers(3), new PacketSyncDataShortAndIDsAndCovers(4), new PacketSyncDataShortAndIDsAndCovers(5), new PacketSyncDataShortAndIDsAndCovers(6), new PacketSyncDataShortAndIDsAndCovers(7), new PacketSyncDataIntegerAndIDsAndCovers(0), new PacketSyncDataIntegerAndIDsAndCovers(1), new PacketSyncDataIntegerAndIDsAndCovers(2), new PacketSyncDataIntegerAndIDsAndCovers(3), new PacketSyncDataIntegerAndIDsAndCovers(4), new PacketSyncDataIntegerAndIDsAndCovers(5), new PacketSyncDataIntegerAndIDsAndCovers(6), new PacketSyncDataIntegerAndIDsAndCovers(7), new PacketSyncDataLongAndIDsAndCovers(0), new PacketSyncDataLongAndIDsAndCovers(1), new PacketSyncDataLongAndIDsAndCovers(2), new PacketSyncDataLongAndIDsAndCovers(3), new PacketSyncDataLongAndIDsAndCovers(4), new PacketSyncDataLongAndIDsAndCovers(5), new PacketSyncDataLongAndIDsAndCovers(6), new PacketSyncDataLongAndIDsAndCovers(7), new PacketSyncDataByteArrayAndIDsAndCovers(0), new PacketSyncDataByteArrayAndIDsAndCovers(1), new PacketSyncDataByteArrayAndIDsAndCovers(2), new PacketSyncDataByteArrayAndIDsAndCovers(3), new PacketSyncDataByteArrayAndIDsAndCovers(4), new PacketSyncDataByteArrayAndIDsAndCovers(5), new PacketSyncDataByteArrayAndIDsAndCovers(6), new PacketSyncDataByteArrayAndIDsAndCovers(7), new PacketSyncDataCoverVisuals(0), new PacketSyncDataCoverVisuals(1), new PacketSyncDataCoverVisuals(2), new PacketSyncDataCoverVisuals(3), new PacketSyncDataCoverVisuals(4), new PacketSyncDataCoverVisuals(5), new PacketSyncDataCoverVisuals(6), new PacketSyncDataCoverVisuals(7), new PacketSyncDataByteAndCoverVisuals(0), new PacketSyncDataByteAndCoverVisuals(1), new PacketSyncDataByteAndCoverVisuals(2), new PacketSyncDataByteAndCoverVisuals(3), new PacketSyncDataByteAndCoverVisuals(4), new PacketSyncDataByteAndCoverVisuals(5), new PacketSyncDataByteAndCoverVisuals(6), new PacketSyncDataByteAndCoverVisuals(7), new PacketSyncDataShortAndCoverVisuals(0), new PacketSyncDataShortAndCoverVisuals(1), new PacketSyncDataShortAndCoverVisuals(2), new PacketSyncDataShortAndCoverVisuals(3), new PacketSyncDataShortAndCoverVisuals(4), new PacketSyncDataShortAndCoverVisuals(5), new PacketSyncDataShortAndCoverVisuals(6), new PacketSyncDataShortAndCoverVisuals(7), new PacketSyncDataIntegerAndCoverVisuals(0), new PacketSyncDataIntegerAndCoverVisuals(1), new PacketSyncDataIntegerAndCoverVisuals(2), new PacketSyncDataIntegerAndCoverVisuals(3), new PacketSyncDataIntegerAndCoverVisuals(4), new PacketSyncDataIntegerAndCoverVisuals(5), new PacketSyncDataIntegerAndCoverVisuals(6), new PacketSyncDataIntegerAndCoverVisuals(7), new PacketSyncDataLongAndCoverVisuals(0), new PacketSyncDataLongAndCoverVisuals(1), new PacketSyncDataLongAndCoverVisuals(2), new PacketSyncDataLongAndCoverVisuals(3), new PacketSyncDataLongAndCoverVisuals(4), new PacketSyncDataLongAndCoverVisuals(5), new PacketSyncDataLongAndCoverVisuals(6), new PacketSyncDataLongAndCoverVisuals(7), new PacketSyncDataByteArrayAndCoverVisuals(0), new PacketSyncDataByteArrayAndCoverVisuals(1), new PacketSyncDataByteArrayAndCoverVisuals(2), new PacketSyncDataByteArrayAndCoverVisuals(3), new PacketSyncDataByteArrayAndCoverVisuals(4), new PacketSyncDataByteArrayAndCoverVisuals(5), new PacketSyncDataByteArrayAndCoverVisuals(6), new PacketSyncDataByteArrayAndCoverVisuals(7));
NW_AP2 = new NetworkHandler(MD.GAPI.mID, "GAP2", new PacketSyncDataByte(0), new PacketSyncDataByte(1), new PacketSyncDataByte(2), new PacketSyncDataByte(3), new PacketSyncDataByte(4), new PacketSyncDataByte(5), new PacketSyncDataByte(6), new PacketSyncDataByte(7), new PacketSyncDataShort(0), new PacketSyncDataShort(1), new PacketSyncDataShort(2), new PacketSyncDataShort(3), new PacketSyncDataShort(4), new PacketSyncDataShort(5), new PacketSyncDataShort(6), new PacketSyncDataShort(7), new PacketSyncDataInteger(0), new PacketSyncDataInteger(1), new PacketSyncDataInteger(2), new PacketSyncDataInteger(3), new PacketSyncDataInteger(4), new PacketSyncDataInteger(5), new PacketSyncDataInteger(6), new PacketSyncDataInteger(7), new PacketSyncDataLong(0), new PacketSyncDataLong(1), new PacketSyncDataLong(2), new PacketSyncDataLong(3), new PacketSyncDataLong(4), new PacketSyncDataLong(5), new PacketSyncDataLong(6), new PacketSyncDataLong(7), new PacketSyncDataByteArray(0), new PacketSyncDataByteArray(1), new PacketSyncDataByteArray(2), new PacketSyncDataByteArray(3), new PacketSyncDataByteArray(4), new PacketSyncDataByteArray(5), new PacketSyncDataByteArray(6), new PacketSyncDataByteArray(7), new PacketSyncDataIDs(0), new PacketSyncDataIDs(1), new PacketSyncDataIDs(2), new PacketSyncDataIDs(3), new PacketSyncDataIDs(4), new PacketSyncDataIDs(5), new PacketSyncDataIDs(6), new PacketSyncDataIDs(7), new PacketSyncDataByteAndIDs(0), new PacketSyncDataByteAndIDs(1), new PacketSyncDataByteAndIDs(2), new PacketSyncDataByteAndIDs(3), new PacketSyncDataByteAndIDs(4), new PacketSyncDataByteAndIDs(5), new PacketSyncDataByteAndIDs(6), new PacketSyncDataByteAndIDs(7), new PacketSyncDataShortAndIDs(0), new PacketSyncDataShortAndIDs(1), new PacketSyncDataShortAndIDs(2), new PacketSyncDataShortAndIDs(3), new PacketSyncDataShortAndIDs(4), new PacketSyncDataShortAndIDs(5), new PacketSyncDataShortAndIDs(6), new PacketSyncDataShortAndIDs(7), new PacketSyncDataIntegerAndIDs(0), new PacketSyncDataIntegerAndIDs(1), new PacketSyncDataIntegerAndIDs(2), new PacketSyncDataIntegerAndIDs(3), new PacketSyncDataIntegerAndIDs(4), new PacketSyncDataIntegerAndIDs(5), new PacketSyncDataIntegerAndIDs(6), new PacketSyncDataIntegerAndIDs(7), new PacketSyncDataLongAndIDs(0), new PacketSyncDataLongAndIDs(1), new PacketSyncDataLongAndIDs(2), new PacketSyncDataLongAndIDs(3), new PacketSyncDataLongAndIDs(4), new PacketSyncDataLongAndIDs(5), new PacketSyncDataLongAndIDs(6), new PacketSyncDataLongAndIDs(7), new PacketSyncDataByteArrayAndIDs(0), new PacketSyncDataByteArrayAndIDs(1), new PacketSyncDataByteArrayAndIDs(2), new PacketSyncDataByteArrayAndIDs(3), new PacketSyncDataByteArrayAndIDs(4), new PacketSyncDataByteArrayAndIDs(5), new PacketSyncDataByteArrayAndIDs(6), new PacketSyncDataByteArrayAndIDs(7), new PacketSyncDataIDsAndCovers(0), new PacketSyncDataIDsAndCovers(1), new PacketSyncDataIDsAndCovers(2), new PacketSyncDataIDsAndCovers(3), new PacketSyncDataIDsAndCovers(4), new PacketSyncDataIDsAndCovers(5), new PacketSyncDataIDsAndCovers(6), new PacketSyncDataIDsAndCovers(7), new PacketSyncDataByteAndIDsAndCovers(0), new PacketSyncDataByteAndIDsAndCovers(1), new PacketSyncDataByteAndIDsAndCovers(2), new PacketSyncDataByteAndIDsAndCovers(3), new PacketSyncDataByteAndIDsAndCovers(4), new PacketSyncDataByteAndIDsAndCovers(5), new PacketSyncDataByteAndIDsAndCovers(6), new PacketSyncDataByteAndIDsAndCovers(7), new PacketSyncDataShortAndIDsAndCovers(0), new PacketSyncDataShortAndIDsAndCovers(1), new PacketSyncDataShortAndIDsAndCovers(2), new PacketSyncDataShortAndIDsAndCovers(3), new PacketSyncDataShortAndIDsAndCovers(4), new PacketSyncDataShortAndIDsAndCovers(5), new PacketSyncDataShortAndIDsAndCovers(6), new PacketSyncDataShortAndIDsAndCovers(7), new PacketSyncDataIntegerAndIDsAndCovers(0), new PacketSyncDataIntegerAndIDsAndCovers(1), new PacketSyncDataIntegerAndIDsAndCovers(2), new PacketSyncDataIntegerAndIDsAndCovers(3), new PacketSyncDataIntegerAndIDsAndCovers(4), new PacketSyncDataIntegerAndIDsAndCovers(5), new PacketSyncDataIntegerAndIDsAndCovers(6), new PacketSyncDataIntegerAndIDsAndCovers(7), new PacketSyncDataLongAndIDsAndCovers(0), new PacketSyncDataLongAndIDsAndCovers(1), new PacketSyncDataLongAndIDsAndCovers(2), new PacketSyncDataLongAndIDsAndCovers(3), new PacketSyncDataLongAndIDsAndCovers(4), new PacketSyncDataLongAndIDsAndCovers(5), new PacketSyncDataLongAndIDsAndCovers(6), new PacketSyncDataLongAndIDsAndCovers(7), new PacketSyncDataByteArrayAndIDsAndCovers(0), new PacketSyncDataByteArrayAndIDsAndCovers(1), new PacketSyncDataByteArrayAndIDsAndCovers(2), new PacketSyncDataByteArrayAndIDsAndCovers(3), new PacketSyncDataByteArrayAndIDsAndCovers(4), new PacketSyncDataByteArrayAndIDsAndCovers(5), new PacketSyncDataByteArrayAndIDsAndCovers(6), new PacketSyncDataByteArrayAndIDsAndCovers(7), new PacketSyncDataCoverVisuals(0), new PacketSyncDataCoverVisuals(1), new PacketSyncDataCoverVisuals(2), new PacketSyncDataCoverVisuals(3), new PacketSyncDataCoverVisuals(4), new PacketSyncDataCoverVisuals(5), new PacketSyncDataCoverVisuals(6), new PacketSyncDataCoverVisuals(7), new PacketSyncDataByteAndCoverVisuals(0), new PacketSyncDataByteAndCoverVisuals(1), new PacketSyncDataByteAndCoverVisuals(2), new PacketSyncDataByteAndCoverVisuals(3), new PacketSyncDataByteAndCoverVisuals(4), new PacketSyncDataByteAndCoverVisuals(5), new PacketSyncDataByteAndCoverVisuals(6), new PacketSyncDataByteAndCoverVisuals(7), new PacketSyncDataShortAndCoverVisuals(0), new PacketSyncDataShortAndCoverVisuals(1), new PacketSyncDataShortAndCoverVisuals(2), new PacketSyncDataShortAndCoverVisuals(3), new PacketSyncDataShortAndCoverVisuals(4), new PacketSyncDataShortAndCoverVisuals(5), new PacketSyncDataShortAndCoverVisuals(6), new PacketSyncDataShortAndCoverVisuals(7), new PacketSyncDataIntegerAndCoverVisuals(0), new PacketSyncDataIntegerAndCoverVisuals(1), new PacketSyncDataIntegerAndCoverVisuals(2), new PacketSyncDataIntegerAndCoverVisuals(3), new PacketSyncDataIntegerAndCoverVisuals(4), new PacketSyncDataIntegerAndCoverVisuals(5), new PacketSyncDataIntegerAndCoverVisuals(6), new PacketSyncDataIntegerAndCoverVisuals(7), new PacketSyncDataLongAndCoverVisuals(0), new PacketSyncDataLongAndCoverVisuals(1), new PacketSyncDataLongAndCoverVisuals(2), new PacketSyncDataLongAndCoverVisuals(3), new PacketSyncDataLongAndCoverVisuals(4), new PacketSyncDataLongAndCoverVisuals(5), new PacketSyncDataLongAndCoverVisuals(6), new PacketSyncDataLongAndCoverVisuals(7), new PacketSyncDataByteArrayAndCoverVisuals(0), new PacketSyncDataByteArrayAndCoverVisuals(1), new PacketSyncDataByteArrayAndCoverVisuals(2), new PacketSyncDataByteArrayAndCoverVisuals(3), new PacketSyncDataByteArrayAndCoverVisuals(4), new PacketSyncDataByteArrayAndCoverVisuals(5), new PacketSyncDataByteArrayAndCoverVisuals(6), new PacketSyncDataByteArrayAndCoverVisuals(7));
// Registering the TileEntity used for Meta-Generated Blocks to store the 32000 variations.
GameRegistry.registerTileEntity(PrefixBlockTileEntity.class, "gt.MetaBlockTileEntity");
// Creating and loading the Lang File.
if (CODE_CLIENT) {
tFile = new File(DirectoriesGT.MINECRAFT, "GregTech.lang");
if (!tFile.exists())
tFile = new File(DirectoriesGT.MINECRAFT, "gregtech.lang");
LanguageHandler.sLangFile = new Configuration(tFile);
} else {
sBlockIconload.clear();
sBlockIconload = null;
sItemIconload.clear();
sItemIconload = null;
}
// Creating and loading the Unification Config.
OreDictManager.INSTANCE.mUnificationConfig = new Config("Unification.cfg");
// Initialising the Re-Registrations.
new LoaderOreDictReRegistrations().run();
// Register the Falling MetaBlock Entity.
EntityRegistry.registerModEntity(PrefixBlockFallingEntity.class, "gt.MetaBlockFallingEntity", 0, this, 160, 1, T);
// Initialise Enchantments.
new Enchantment_WerewolfDamage();
new Enchantment_EnderDamage();
new Enchantment_Radioactivity();
new Enchantment_SlimeDamage();
// Initialises the Fluid Display Item.
IL.Display_Fluid.set(new ItemFluidDisplay());
// Initialises the Integrated Circuit Item.
IL.Circuit_Selector.set(new ItemIntegratedCircuit());
// Initialises the Empty Slot Marker Item.
IL.Empty_Slot.set(new ItemEmptySlot());
// Register the GUI Handler.
NetworkRegistry.INSTANCE.registerGuiHandler(this, api_proxy);
// Fixing vanilla Oak Plank Slab Recipe.
CR.remove(ST.make(Blocks.planks, 1, 0), ST.make(Blocks.planks, 1, 1), ST.make(Blocks.planks, 1, 2));
CR.shaped(ST.make(Blocks.wooden_slab, 6, 0), CR.NONE, "WWW", 'W', ST.make(Blocks.planks, 1, 0));
// Preventing a Water Dupe by registering this Recipe early so it won't be overridden
RM.Canner.addRecipe1(T, 16, 16, ST.make(Items.glass_bottle, 1, 0), FL.Water.make(250), NF, ST.make(Items.potionitem, 1, 0));
RM.Canner.addRecipe1(T, 16, 16, ST.make(Items.potionitem, 1, 0), ST.make(Items.glass_bottle, 1, 0));
try {
LoadController tLoadController = ((LoadController) UT.Reflection.getFieldContent(Loader.instance(), "modController", T, T));
List<ModContainer> tModList = tLoadController.getActiveModList(), tNewModsList = new ArrayList<>(tModList.size());
ModContainer tGregTech = null;
for (short i = 0; i < tModList.size(); i++) {
ModContainer tMod = tModList.get(i);
if (tMod.getModId().equalsIgnoreCase(MD.GAPI.mID))
tGregTech = tMod;
else
tNewModsList.add(tMod);
}
if (tGregTech != null)
tNewModsList.add(0, tGregTech);
UT.Reflection.setFieldContent(tLoadController, "activeModList", tNewModsList);
} catch (Throwable e) {
e.printStackTrace(ERR);
}
for (ICompat tCompat : ICompat.COMPAT_CLASSES) try {
tCompat.onPreLoad(aEvent);
} catch (Throwable e) {
e.printStackTrace(ERR);
}
}
Aggregations