How do you make your mod do something if it detects another active mod?

Started by TheOriginalGoatMan2 on Sat, 02/20/2021 - 09:39

Topic category: Advanced modding

Last seen on 16:42, 11. Apr 2021
Joined Jul 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
How do you make your mod do something if it detects another active mod?
Sat, 02/20/2021 - 09:39

So, my mod adds Nether Iron Ore, but I want it to be disabled if the Charm mod is active, as that adds Pig Iron Ore. How would I go about doing this? I know this is possible, as Charm does it for Quark.

Last seen on 20:42, 11. Apr 2021
Joined Apr 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
You will need to do custom…
Sun, 02/21/2021 - 23:01

You will need to do custom coding. Basically you will need to create additional generation condition and if statement inside that checks ModList.get().isLoaded(“modid”);.