Jump to content

In 1.13 can mods provide custom code for resourcepacks?


portablejim

Recommended Posts

In 1.12 and before, I have used an implementation of IFMLLoadingPlugin to allow an extension of DummyModContainer to be able to return a custom class to getCustomResourcePackClass(). This allowed a hidden folder-based resource pack that always loaded but is easily able to be changed at runtime by the user or bundled by the modpack dev.

 

I am wondering if this mod (source code at https://github.com/portablejim/Additional-Resources/tree/master/src/main/java/portablejim/additionalresources ) and the mod dependent on this one is able to be brought to 1.13 and what approach I should be looking at?

Edited by portablejim
Adding code link
Link to comment
Share on other sites

Also completely impossible with the new coremod system

About Me

Spoiler

My Discord - Cadiboo#8887

My WebsiteCadiboo.github.io

My ModsCadiboo.github.io/projects

My TutorialsCadiboo.github.io/tutorials

Versions below 1.14.4 are no longer supported on this forum. Use the latest version to receive support.

When asking support remember to include all relevant log files (logs are found in .minecraft/logs/), code if applicable and screenshots if possible.

Only download mods from trusted sites like CurseForge (minecraft.curseforge.com). A list of bad sites can be found here, with more information available at stopmodreposts.org

Edit your own signature at www.minecraftforge.net/forum/settings/signature/ (Make sure to check its compatibility with the Dark Theme)

Link to comment
Share on other sites

23 hours ago, diesieben07 said:

Nothing of that coremod-hackyness was required, ever.

Before 1.13 you could just add resource packs to Minecraft#defaultResourcePacks. In 1.13 the system seems to have been reworked a bit, but something similar should be possible. No need for coremods.

Thanks for the tip. It did get me there in the end.

 

For those who come after: Implement IPackFinder, look at FolderPack/FilePack/AbstractResourcePack and extend if needed, and call

((Minecraft)mc).getResourcePackList().addPackFinder()

with your implementation of IPackFinder.

Edited by portablejim
Added xkcd.
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
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.