[2024.2, forge1.20.1] How do I specify the load order and version range of Required Mods I add?

Started by .erdrik on

Topic category: Help with Minecraft modding (Java Edition)

Joined Oct 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
[2024.2, forge1.20.1] How do I specify the load order and version range of Required Mods I add?

As the topic title says, how do I specify the load order and version range of Required Mods I add?

This seems like it should be a base required functionality, but I can't seem to do anything to change it, and the mods.toml always displays:

versionRange="[0,)"
ordering="NONE" 

I tried running my mod with just that but forge throws an error during load:

 


Suspected Mod: 
    Erdrik's Modular Library (erdriks_modular_library), Version: 0.0.0
        at TRANSFORMER/erdriks_modular_library@0.0.0/net.mcreator.erdriksmodularlibrary.init.ErdriksModularLibraryModEntities.<clinit>(ErdriksModularLibraryModEntities.java:26)
Stacktrace:
    at net.mcreator.erdriksmodularlibrary.init.ErdriksModularLibraryModEntities.<clinit>(ErdriksModularLibraryModEntities.java:26) ~[erdriks_modular_library-0.0.0-forge-1.20.1.jar%23191!/:?] {re:classloading}
-- MOD erdriks_modular_library --
Details:
    Mod File: /D:/ErdMachine/MyDocs/Minecraft Mod Projects/erdriks_modular_turrets/run/mods/erdriks_modular_library-0.0.0-forge-1.20.1.jar
    Failure message: Erdrik's Modular Library (erdriks_modular_library) has failed to load correctly
        java.lang.NoSuchMethodError: 'net.minecraft.world.entity.EntityType$Builder net.minecraft.world.entity.EntityType$Builder.m_20704_(net.minecraft.world.entity.EntityType$EntityFactory, net.minecraft.world.entity.MobCategory)'
    Mod Version: 0.0.0
    Mod Issue URL: NOT PROVIDED
    Exception message: java.lang.NoSuchMethodError: 'net.minecraft.world.entity.EntityType$Builder net.minecraft.world.entity.EntityType$Builder.m_20704_(net.minecraft.world.entity.EntityType$EntityFactory, net.minecraft.world.entity.MobCategory)'
Stacktrace:
    at net.mcreator.erdriksmodularlibrary.init.ErdriksModularLibraryModEntities.<clinit>(ErdriksModularLibraryModEntities.java:26) ~[erdriks_modular_library-0.0.0-forge-1.20.1.jar%23191!/:?] {re:classloading}
    at net.mcreator.erdriksmodularlibrary.ErdriksModularLibraryMod.<init>(ErdriksModularLibraryMod.java:44) ~[erdriks_modular_library-0.0.0-forge-1.20.1.jar%23191!/:?] {re:classloading}

Joined Oct 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Nevermind. I figured it out…
Tue, 10/22/2024 - 20:37

Nevermind. I figured it out.

between the part of the mods.toml that has "# Start of user code block dependencies configuration" and "# End of user code block dependencies configuration" apparently allows custom code that is not overridden when the workspace is rebuilt.

Sorry for the wasted post. :/

Joined Oct 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I still get the crash and…
Tue, 10/22/2024 - 20:41

I still get the crash and error though.

( how do I edit my posts?? )

Joined Oct 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Ok, so this is weird.  The…
Tue, 10/22/2024 - 21:37

Ok, so this is weird. 

The forge version that is installed with [2024.2] of MCreator (as shown when I run the mod from within mcreator) is 47.3.0

The forge version that is installed with my actual install of minecraft is 47.3.10

Out of curiosity I exported my mod and the library Im trying to make it dependent on into my actual minecraft mods folder and it successfully loaded. But It fails when I run it in MCreator.

The only difference that I can tell is the versions of forge. My mod's dependencies work in forge 47.3.10, but not from within MCreator's forge version 47.3.0.

I don't suppose there is some way to have MCreator install and use forge 47.3.10 ?