Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

[1.15.2] How to get my mod config's directory ?


uiytt
 Share

Recommended Posts

If you have registered your configuration file, it should be in run/config/whatyounamedit.toml The default name would be modid-side.toml If you do not know where your run folder is, it should be in the same directory as your src folder that you are currently working on. Note you do have to run the game once to generate the configuration file.

Link to comment
Share on other sites

1 hour ago, ChampionAsh5357 said:

If you have registered your configuration file, it should be in run/config/whatyounamedit.toml The default name would be modid-side.toml If you do not know where your run folder is, it should be in the same directory as your src folder that you are currently working on. Note you do have to run the game once to generate the configuration file.

Oh wait, I don't know how the config file work after 1.11, can you link me to any tuto there is on this subject (I didn't found any)

Link to comment
Share on other sites

I would recommend going into net.minecraftforge.common.ForgeModConfig and the net.minecraftforge.fml.config package in the source and looking at how they setup and register it. Then all you need to do is register the config in your main mod file's constructor using ModLoadingContext#registerConfig. The best I can do for a visual example is my classes for the Config and Main Mod File.

  • Like 1
Link to comment
Share on other sites

1 hour ago, ChampionAsh5357 said:

I would recommend going into net.minecraftforge.common.ForgeModConfig and the net.minecraftforge.fml.config package in the source and looking at how they setup and register it. Then all you need to do is register the config in your main mod file's constructor using ModLoadingContext#registerConfig. The best I can do for a visual example is my classes for the Config and Main Mod File.

Thanks, I have another question. If I didn't register a config,

How can I get in my Init event the config folder (where every config are store in).

I would like to use another storage system way more enjoyable to use and thus I need to know where is the folder where it's supposed to go ^^

Link to comment
Share on other sites

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
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.

 Share



×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.