Jump to content

Including another mods from in my project in the run config of another mod from the same project


Recommended Posts

Posted

 

Hi!

I've a single, multiproject setup in IDEA, with, say, ModA and ModB in it, and ModB depend on the code of ModA. It's working fine so far, they only problem is run configurations

 

How do I include ModA in the run config of ModB?

 

I've tried to add a new "mod" unders the mods list of the run config of ModB, like so:


 

runs {
        server {
            workingDirectory runDir

            // Recommended logging data for a userdev environment
            property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'

            // Recommended logging level for the console
            property 'forge.logging.console.level', 'debug'

            mods {
                moda {
                    source project(':moda').sourceSets.main
                }
                
                modb {
                    source sourceSets.main
                }
            }
        }

    client {
        //same stuff basically
        }
}

but that project(':moda').sourceSets.main, for some reasons, seems to resolve to the source set of the root project, not the one of the subproject "moda"

 

How do I do that?

thank you!

Posted

Are these going to be shipped in the same jar?

This is my Forum Signature, I am currently attempting to transform it into a small guide for fixing easier issues using spoiler blocks to keep things tidy.

 

As the most common issue I feel I should put this outside the main bulk:

The only official source for Forge is https://files.minecraftforge.net, and the only site I trust for getting mods is CurseForge.

If you use any site other than these, please take a look at the StopModReposts project and install their browser extension, I would also advise running a virus scan.

 

For players asking for assistance with Forge please expand the spoiler below and read the appropriate section(s) in its/their entirety.

  Reveal hidden contents

 

Posted

Does simply adding the other mod project as a dependency not add it to the runtime?

This is my Forum Signature, I am currently attempting to transform it into a small guide for fixing easier issues using spoiler blocks to keep things tidy.

 

As the most common issue I feel I should put this outside the main bulk:

The only official source for Forge is https://files.minecraftforge.net, and the only site I trust for getting mods is CurseForge.

If you use any site other than these, please take a look at the StopModReposts project and install their browser extension, I would also advise running a virus scan.

 

For players asking for assistance with Forge please expand the spoiler below and read the appropriate section(s) in its/their entirety.

  Reveal hidden contents

 

Posted (edited)

No. I have this as a dependency to allow modB to complie (Idea see the dependency in gradle and set it's project correctly):

 

implementation project(':moda')

 

But the runconfig don't see the dependency and so modA is not added to the mods list when Idea/forgegradle launch modb (and I get an error from FML becase ModB required ModA to be present  and ModA is missing)

 

I've to edit the Idea runconfigs XMLs to manually  add modA to the mods to loads and I'm trying to find a way to add it in the build.gradle file to avoid that manual work every time I upgrade to a new forge version and recreate the run configs

 

Edited by anothertime
Posted

How important is it for them to be in the same project space for you?

This is my Forum Signature, I am currently attempting to transform it into a small guide for fixing easier issues using spoiler blocks to keep things tidy.

 

As the most common issue I feel I should put this outside the main bulk:

The only official source for Forge is https://files.minecraftforge.net, and the only site I trust for getting mods is CurseForge.

If you use any site other than these, please take a look at the StopModReposts project and install their browser extension, I would also advise running a virus scan.

 

For players asking for assistance with Forge please expand the spoiler below and read the appropriate section(s) in its/their entirety.

  Reveal hidden contents

 

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.