Jump to content

Recommended Posts

Posted

addCustomCategoryComment

Its in the Configuration class.

 

 

EDIT: NVM, I TRIED TO INIT ORE SPAWNING BEFORE LOADING THE ACTUAL ORE. BAD IDEA

Hi, here is my code but it crashes:

 

@Mod.EventHandler
public void preInit(FMLPreInitializationEvent event) {
	System.out.println(name + " is making smelting better for you!");
	Configuration config = new Configuration(event.getSuggestedConfigurationFile());
	config.load();
	boolean enableRFtLrecipe = config.get(Configuration.CATEGORY_GENERAL, "enableRFtLrecipe", true).getBoolean(true);
	if(enableRFtLrecipe)
		RFtL.init();
	boolean enableCustomFuels = config.get(Configuration.CATEGORY_GENERAL, "enableCustomFuels", true).getBoolean(true);
	if(enableCustomFuels)
		GameRegistry.registerFuelHandler(new Fuels());
	[b]config.addCustomCategoryComment(Configuration.CATEGORY_GENERAL, "TEST");[/b]
	boolean enableCustomOreSpawn = config.get(Configuration.CATEGORY_GENERAL, "enableCustomOreSpawn", true).getBoolean(true);
	if(enableCustomOreSpawn)
		GameRegistry.registerWorldGenerator(new ModWorldGen(), 1);
	config.save();
	ModItems.init();
	ModBlocks.init();
	ModCrafting.init();
	ModSmelting.init();
}

 

[22:45:56] [Client thread/ERROR] [FML]: The following problems were captured during this phase
[22:45:56] [Client thread/ERROR] [FML]: Caught exception from §4More Fuels Mod (morefuelsmod-bleeding)
java.lang.NullPointerException
at com.bored.morefuelsmod.ModWorldGen.<init>(ModWorldGen.java:20) ~[bin/:?]
at com.bored.morefuelsmod.Main.preInit(Main.java:41) ~[bin/:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_112]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_112]
at net.minecraftforge.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:639) ~[forgeSrc-1.11.2-13.20.0.2201.jar:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_112]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_112]
at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74) ~[guava-17.0.jar:?]
at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47) ~[guava-17.0.jar:?]
at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322) ~[guava-17.0.jar:?]
at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304) ~[guava-17.0.jar:?]
at com.google.common.eventbus.EventBus.post(EventBus.java:275) ~[guava-17.0.jar:?]
at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:243) ~[forgeSrc-1.11.2-13.20.0.2201.jar:?]
at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:221) ~[forgeSrc-1.11.2-13.20.0.2201.jar:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_112]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_112]
at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74) ~[guava-17.0.jar:?]
at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47) ~[guava-17.0.jar:?]
at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322) ~[guava-17.0.jar:?]
at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304) ~[guava-17.0.jar:?]
at com.google.common.eventbus.EventBus.post(EventBus.java:275) ~[guava-17.0.jar:?]
at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:145) [LoadController.class:?]
at net.minecraftforge.fml.common.Loader.preinitializeMods(Loader.java:626) [Loader.class:?]
at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:266) [FMLClientHandler.class:?]
at net.minecraft.client.Minecraft.startGame(Minecraft.java:478) [Minecraft.class:?]
at net.minecraft.client.Minecraft.run(Minecraft.java:387) [Minecraft.class:?]
at net.minecraft.client.main.Main.main(Main.java:118) [Main.class:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_112]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_112]
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_112]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_112]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_112]
at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:97) [start/:?]
at GradleStart.main(GradleStart.java:26) [start/:?]
[22:45:56] [Client thread/INFO] [sTDOUT]: [net.minecraft.init.Bootstrap:printToSYSOUT:600]: ---- Minecraft Crash Report ----
// Surprise! Haha. Well, this is awkward.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.