cpw.mods.fml.common.event.FMLPostInitializationEvent Java Examples

The following examples show how to use cpw.mods.fml.common.event.FMLPostInitializationEvent. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: EtFuturum.java    From Et-Futurum with The Unlicense 6 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event) {
	Items.blaze_rod.setFull3D();
	Blocks.trapped_chest.setCreativeTab(CreativeTabs.tabRedstone);

	if (enableUpdatedFoodValues) {
		setFinalField(ItemFood.class, Items.carrot, 3, "healAmount", "field_77853_b");
		setFinalField(ItemFood.class, Items.baked_potato, 5, "healAmount", "field_77853_b");
	}

	if (enableUpdatedHarvestLevels) {
		Blocks.packed_ice.setHarvestLevel("pickaxe", 0);
		Blocks.ladder.setHarvestLevel("axe", 0);
		Blocks.melon_block.setHarvestLevel("axe", 0);
	}
}
 
Example #2
Source File: Compatibility.java    From Chisel with GNU General Public License v2.0 6 votes vote down vote up
public static void init(FMLPostInitializationEvent event)
{
    new ChiselModCompatibility().postInit(event);

    addSupport("ProjRed|Exploration", "projectred.exploration.stone", "marble", 0, 99);
    addSupport("bluepower", "marble", "marble", 0, 99);
    
    addSupport("PFAAGeologica", "strongStone", "marble", 5, 99);
    addSupport("PFAAGeologica", "strongStoneSlab", "marbleSlab", 5, 99);
    addSupport("PFAAGeologica", "strongStoneBrickStairs.marble", "marbleStairs", 0, 99);
    addSupport("PFAAGeologica", "mediumStone", "limestone", 0, 99);
    addSupport("PFAAGeologica", "mediumStoneSlab", "limestoneSlab", 0, 99);
    addSupport("PFAAGeologica", "mediumStoneBrickStairs.limestone", "limestoneStairs", 0, 99);
    addSupport("PFAAGeologica", "strongStoneBrick", "stoneBrick", 3, 99);
    addSupport("PFAAGeologica", "strongCobble", "cobblestone", 3, 99);
}
 
Example #3
Source File: PneumaticCraft.java    From PneumaticCraft with GNU General Public License v3.0 6 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event){

    //Add these later so we include other mod's storage recipes.
    // CraftingRegistrator.addPressureChamberStorageBlockRecipes();
    CraftingRegistrator.addAssemblyCombinedRecipes();
    HeatExchangerManager.getInstance().init();
    FluidFuelManager.registerFuels();

    ThirdPartyManager.instance().postInit();
    proxy.postInit();
    Config.postInit();
    AmadronOfferManager.getInstance().shufflePeriodicOffers();
    AmadronOfferManager.getInstance().recompileOffers();
    CraftingRegistrator.addProgrammingPuzzleRecipes();
}
 
Example #4
Source File: NovaMinecraft.java    From NOVA-Core with GNU Lesser General Public License v3.0 5 votes vote down vote up
@Mod.EventHandler
@Override
@SuppressWarnings("deprecation")
public void postInit(FMLPostInitializationEvent evt) {
	try {
		proxy.postInit(evt);
		nativeConverters.stream().forEachOrdered(forgeLoadable -> forgeLoadable.postInit(evt));
		Game.recipes().init();
		cpw.mods.fml.common.ProgressManager.ProgressBar progressBar
			= cpw.mods.fml.common.ProgressManager.push("Post-initializing NOVA wrappers",
				(novaModWrappers.isEmpty() ? 1 : novaModWrappers.size()) + novaWrappers.size());
		FMLProgressBar fmlProgressBar = new FMLProgressBar(progressBar);
		novaModWrappers.stream().forEachOrdered(wrapper -> {
			fmlProgressBar.step(wrapper.getClass());
			wrapper.postInit(evt);
		});
		novaWrappers.stream().forEachOrdered(wrapper -> {
			fmlProgressBar.step(wrapper.getClass());
			wrapper.postInit(evt);
		});
		fmlProgressBar.finish();
		cpw.mods.fml.common.ProgressManager.pop(progressBar);
	} catch (Exception e) {
		Game.logger().error("Error during postInit", e);
		e.printStackTrace();
		throw new InitializationException(e);
	}
}
 
Example #5
Source File: Chisel.java    From Chisel-2 with GNU General Public License v2.0 5 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event) {
	ChiselTabs.postInit();
	Compatibility.init(event);
	FMLLog.severe("Unable to lookup chisel:... is not an error, please do not treat it as such");
	FMLLog.bigWarning("In case you didn't see the red above I suggest you read it - Cricket");
}
 
Example #6
Source File: GardenContainers.java    From GardenCollection with MIT License 5 votes vote down vote up
@Mod.EventHandler
public void postInit (FMLPostInitializationEvent event) {
    GardenCoreAPI.instance().registerSmallFlameHostBlock(ModBlocks.decorativePot, 0);
    GardenCoreAPI.instance().registerSmallFlameHostBlock(ModBlocks.decorativePot, 1);
    GardenCoreAPI.instance().registerSmallFlameHostBlock(ModBlocks.decorativePot, 2);
    recipes.init();
}
 
Example #7
Source File: Framez.java    From Framez with GNU General Public License v3.0 5 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event) {

    CompatibilityUtils.postInit(event);

    try {
        GuiHax.doGuiHax();
    } catch (Exception e) {
        e.printStackTrace();
        FMLCommonHandler.instance().exitJava(-1, true);
    }
}
 
Example #8
Source File: ElectroMagicTools.java    From Electro-Magic-Tools with GNU General Public License v3.0 5 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event) {
    ElectroMagicTools.logger.info(localize("console.EMT.postInit.begin"));

 ModuleRegistry.registerLateModules();
    RegistryHandler.registerIc2PostRegistrys();

    ElectroMagicTools.logger.info(localize("console.EMT.postInit.end"));
}
 
Example #9
Source File: Forbidden.java    From ForbiddenMagic with Do What The F*ck You Want To Public License 5 votes vote down vote up
@EventHandler
public void outro(FMLPostInitializationEvent event) {
    DarkAspects.addAspects();
    ForbiddenRecipes.addRecipes();
    ForbiddenResearch.addResearch();
    Compat.compatify();

    wandLord = new WandOverlord();
    WandTriggerRegistry.registerWandBlockTrigger(wandLord, 1, Blocks.obsidian, 0);
    WandTriggerRegistry.registerWandBlockTrigger(wandLord, 1, Blocks.netherrack, 0);
}
 
Example #10
Source File: WailaNBT.java    From wailanbt with MIT License 5 votes vote down vote up
@SuppressWarnings("UnusedDeclaration")
@SideOnly(Side.CLIENT)
@Mod.EventHandler
public void postInit(FMLPostInitializationEvent event){
    GuiContainerManager.addTooltipHandler(new TooltipHandler());

}
 
Example #11
Source File: DragonArtifacts.java    From Artifacts with MIT License 5 votes vote down vote up
@EventHandler
public void PostInit(FMLPostInitializationEvent event) 
{
	baublesLoaded = Loader.isModLoaded("Baubles");
	mystcraftLoaded = Loader.isModLoaded("Mystcraft");
	//System.out.println("[Artifacts] Is Baubles Loaded? " + baublesLoaded);
	//System.out.println("[Artifacts] Is Mystcraft Loaded? " + mystcraftLoaded);
}
 
Example #12
Source File: Extracells.java    From ExtraCells1 with MIT License 5 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event)
{
	proxy.checkForIDMismatches();
	//LP Support
	lpHelper = new LPHelper();
}
 
Example #13
Source File: GalacticraftProxy.java    From bartworks with MIT License 5 votes vote down vote up
public static void postInit(FMLPostInitializationEvent e){
    if (SideReference.Side.Server || SideReference.EffectiveSide.Server) {
        GalacticraftProxy.serverPostInit(e);
    } else {
        GalacticraftProxy.clientPostInit(e);
    }
    GalacticraftProxy.commonPostInit(e);
}
 
Example #14
Source File: BartWorksCrossmod.java    From bartworks with MIT License 5 votes vote down vote up
@Mod.EventHandler
public void postInit(FMLPostInitializationEvent init) {
    if (LoaderReference.GalacticraftCore)
        GalacticraftProxy.postInit(init);
    if (LoaderReference.miscutils)
        RadioHatchCompat.run();
    if (LoaderReference.tectech)
        TecTechResearchLoader.runResearches();
}
 
Example #15
Source File: ArchimedesShipMod.java    From archimedes-ships with MIT License 4 votes vote down vote up
@EventHandler
public void postInitMod(FMLPostInitializationEvent event)
{
	metaRotations.readMetaRotationFiles();
	pipeline.postInitialize();
}
 
Example #16
Source File: GardenTrees.java    From GardenCollection with MIT License 4 votes vote down vote up
@Mod.EventHandler
public void postInit (FMLPostInitializationEvent event) {
    config.postInit();
    integration.postInit();
    recipes.init();
}
 
Example #17
Source File: GardenCore.java    From GardenCollection with MIT License 4 votes vote down vote up
@Mod.EventHandler
public void postInit (FMLPostInitializationEvent event) {
    proxy.postInit();
    integration.postInit();
    recipes.init();

    /*try {
        List<ModContainer> loadedMods = Loader.instance().getActiveModList();
        for (ModContainer mod : loadedMods) {
            String baseAssetPath = "assets/" + mod.getModId() + "/textures/blocks/";
            Pattern assetPattern = Pattern.compile("assets/.+/textures/blocks/.+\\.png");
            JarFile modJar;

            try {
                modJar = new JarFile(mod.getSource());
            }
            catch (IOException e) {
                 continue;
            }

            Enumeration<JarEntry> modJarEntries = modJar.entries();
            while (modJarEntries.hasMoreElements()) {
                JarEntry element = modJarEntries.nextElement();
                if (element.isDirectory() || !assetPattern.matcher(element.getName()).matches())
                    continue;

                BufferedImage image = ImageIO.read(modJar.getInputStream(element));
                if (image.getWidth() != image.getHeight())
                    continue;

                int xStart = 0;
                int xStop = image.getWidth();
                int yStart = 0;
                int yStop = image.getHeight();

                SearchYStart:
                for (; yStart < yStop; yStart++, yStart++) {
                    for (int x = xStart; x < xStop; x++) {
                        if (((image.getRGB(x, yStart) >> 24) & 0xFF) != 0)
                            break SearchYStart;
                    }
                }

                SearchYStop:
                for (; yStop > yStart; yStop--) {
                    for (int x = xStart; x < xStop; x++) {
                        if (((image.getRGB(x, yStop - 1) >> 24) & 0xFF) != 0)
                            break SearchYStop;
                    }
                }

                SearchXStart:
                for (; xStart < xStop; xStart++) {
                    for (int y = yStart; y < yStop; y++) {
                        if (((image.getRGB(xStart, y) >> 24) & 0xFF) != 0)
                            break SearchXStart;
                    }
                }

                SearchXStop:
                for (; xStop > xStart; xStop--) {
                    for (int y = yStart; y < yStop; y++) {
                        if (((image.getRGB(xStop - 1, y) >> 24) & 0xFF) != 0)
                            break SearchXStop;
                    }
                }

                FMLLog.info("%s area: %d,%d; %dx%d", element.getName(), xStart, yStart, xStop - xStart, yStop - yStart);
            }

        }
    }
    catch (IOException e) {
        FMLLog.severe("Error processing jars: %s", e.getMessage());
    }*/
}
 
Example #18
Source File: MwForge.java    From mapwriter with MIT License 4 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event) {
	proxy.postInit();
}
 
Example #19
Source File: GardenStuff.java    From GardenCollection with MIT License 4 votes vote down vote up
@Mod.EventHandler
public void postInit (FMLPostInitializationEvent event) {
    proxy.postInit();
    recipes.init();
    integration.postInit();
}
 
Example #20
Source File: NBTEdit.java    From NBTEdit with GNU General Public License v3.0 4 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event){
	proxy.registerInformation();
}
 
Example #21
Source File: LetsModReboot.java    From LetsModReboot with GNU General Public License v3.0 4 votes vote down vote up
@Mod.EventHandler
public void postInit(FMLPostInitializationEvent event)
{
    LogHelper.info("Post Initialization Complete!");
}
 
Example #22
Source File: MoCProxy.java    From mocreaturesdev with GNU General Public License v3.0 4 votes vote down vote up
public void ConfigPostInit(FMLPostInitializationEvent event) {
    configPostEvent = event;
    initializeBiomes();
    initializeEntities();
}
 
Example #23
Source File: ChiselModCompatibility.java    From Chisel with GNU General Public License v2.0 4 votes vote down vote up
public void postInit(FMLPostInitializationEvent event)
{
    new ClassBlockCompat("shukaro.artifice.ArtificeBlocks", "blockMarble")
    {
        @Override
        void action()
        {
            Carving.chisel.addVariation("marble", block, 0, 99);
            block.setHarvestLevel("chisel", 0, 0);
        }
    };
    new ClassBlockCompat("num.numirp.block.ModBlocks", "blockDecor")
    {
        @Override
        void action()
        {
            Carving.chisel.addVariation("marble", block, 0, 99);
            block.setHarvestLevel("chisel", 0, 0);
        }
    };

    new ClassBlockCompat("mariculture.core.Core", "limestone")
    {
        @Override
        void action()
        {
            Carving.chisel.addVariation("limestone", block, 0, 99);
            block.setHarvestLevel("chisel", 0, 0);
        }
    };
    new ClassBlockCompat("emasher.core.EmasherCore", "limestone")
    {
        @Override
        void action()
        {
            Carving.chisel.addVariation("limestone", block, 0, 99);
            block.setHarvestLevel("chisel", 0, 0);
        }
    };

    new ClassCompat("Reika.GeoStrata.GeoStrata")
    {
        @Override
        void action() throws Exception
        {
            Block[] blocks = (Block[]) cl.getField("blocks").get(null);

            Carving.chisel.addVariation("marble", blocks[0], 2, 99);
            blocks[0].setHarvestLevel("chisel", 0, 2);

            Carving.chisel.addVariation("limestone", blocks[0], 3, 99);
            blocks[0].setHarvestLevel("chisel", 0, 3);
        }
    };
}
 
Example #24
Source File: HexxitGear.java    From HexxitGear with GNU General Public License v3.0 4 votes vote down vote up
@PostInit
public void postInit(FMLPostInitializationEvent evt) {
    GameRegistry.registerPlayerTracker(PlayerTracker.instance);
    HexxitGearRegistry.init();
}
 
Example #25
Source File: AdvancedMod.java    From AdvancedMod with GNU General Public License v3.0 4 votes vote down vote up
@Mod.EventHandler
public void postInit(FMLPostInitializationEvent event){
    proxy.postInit();
    Log.info("Post Initialization Complete!");
}
 
Example #26
Source File: BRLoader.java    From BigReactors with MIT License 4 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent evt) {
	proxy.postInit();
}
 
Example #27
Source File: MoCreatures.java    From mocreaturesdev with GNU General Public License v3.0 4 votes vote down vote up
@PostInit
public void postInit(FMLPostInitializationEvent event)
{
    proxy.ConfigPostInit(event);
    DimensionManager.registerDimension(WyvernLairDimensionID, WyvernLairDimensionID);
}
 
Example #28
Source File: exaliquo.java    From Ex-Aliquo with MIT License 4 votes vote down vote up
@EventHandler
public void postInit(FMLPostInitializationEvent event)
{
	Registries.postInitHammers();
	
	if (Configurations.isOre)
	{
		Registries.registerNihiloOreDict();
	}
	GeneralAliquo.initGeneralStuff();
	Crossmod.initCross();
	OreDictDrops.CheckMetals();
	if (isTConLoaded)
	{
		exaliquo.logger.log(Level.INFO,"Loading Tinker's Construct Compat");
		TConstruct.initTConstruct();
	}
	if (isNaturaLoaded)
	{
		exaliquo.logger.log(Level.INFO,"Loading Natura Compat");
		Natura.initNatura();
	}
	if (isArsMagicaLoaded)
	{
		exaliquo.logger.log(Level.INFO,"Loading Ars Magica 2 Compat");
		ArsMagica.initArsMagica();
	}
	if (isThaumcraftLoaded)
	{
		exaliquo.logger.info("Loading Thaumcraft 4 Compat");
		Thaumcraft.initThaumcraft();
	}
	if(isGrowthcraftLoaded)
	{
		exaliquo.logger.info("Loading Growthcraft Compat");
		Growthcraft.initGrowthcraft();
	}
	if (isMaricultureLoaded)
	{
		exaliquo.logger.info("Loading Mariculture Compat");
		Mariculture.initMariculture();
	}
	if (isMFRLoaded)
	{
		exaliquo.logger.info("Loading MFR Compat");
		MineFactoryReloaded.initMFR();
	}
	if (isMetallurgyLoaded)
	{
		exaliquo.logger.info("Loading Metallurgy Compat");
		Metallurgy.initMetallurgy();
	}
	if (isDartcraftLoaded)
	{
		exaliquo.logger.info("Loading Dartcraft Compat");
		Dartcraft.initDartcraft();
	}
	if (isForestryLoaded)
	{
		ForestryReflection.initProxy();
	}
	if (isThermalExpansionLoaded)
	{
		exaliquo.logger.info("Loading Thermal Expansion Compat");
		ThermalExpansion.initThermalExpansion();
	}
}
 
Example #29
Source File: SPDummyContainer.java    From Sound-Physics with GNU General Public License v3.0 4 votes vote down vote up
@Subscribe
public void postInit(FMLPostInitializationEvent event) 
{

}
 
Example #30
Source File: LookingGlass.java    From LookingGlass with GNU General Public License v3.0 4 votes vote down vote up
@EventHandler
public void postinit(FMLPostInitializationEvent event) {}