Page 1 of 1

Can modpacks have mods that depend on each other?

PostPosted: Tue Aug 27, 2019 11:03
by Red_King_Cyclops
I'm making a mod with many dependencies, and I was wondering if it would be possible to include my mod and all its dependencies in a single modpack.

Re: Can modpacks have mods that depend on each other?

PostPosted: Tue Aug 27, 2019 12:06
by Linuxdirk
If the dependencies allow redistribution then yes.

Re: Can modpacks have mods that depend on each other?

PostPosted: Fri Aug 30, 2019 00:17
by neoh4x0r
Linuxdirk wrote:If the dependencies allow redistribution then yes.

The license must allow redistribution, but I don't think that is what the question is really asking...

I take the question: Can modpacks have mods that depend on each other? to mean that
mod A depends on B (....which depends on A, which depends on B, etc...).

In other words, such a dependency would result in an infinite loop when trying to resolve the dependency chain (might even result in stackoverflow exception, or similar error; crash, or hang).

It is, however, possible that they could depend on a common mod that enables them to "talk" to each other (ie share resources and/or data).

Re: Can modpacks have mods that depend on each other?

PostPosted: Fri Aug 30, 2019 00:38
by Red_King_Cyclops
Actually, I was wondering if it was technically (not legally) possible for a mod pack to contain a mod that depended on other mods in the mod pack (but not a two way dependency). I apologize for not being clear.

Re: Can modpacks have mods that depend on each other?

PostPosted: Fri Aug 30, 2019 03:00
by neoh4x0r
Red_King_Cyclops wrote:Actually, I was wondering if it was technically (not legally) possible for a mod pack to contain a mod that depended on other mods in the mod pack (but not a two way dependency). I apologize for not being clear.


Basically a mod pack just combines a bunch of separate mods into a single unit (the dependencies work the same as they do normally).

So, yeah it is possible to do it (as is done in most of the mod packs that I have downloaded...)

I just quickly looked and the following mod has dependencies on stuff included in the modpack.
[Modpack] Display Modpack [1.3] viewtopic.php?t=19365
The git source is here: https://github.com/pyrollo/display_modpack

The ontime_clocks/mod.conf: https://github.com/pyrollo/display_modp ... s/mod.conf
Code: Select all
name=ontime_clocks
description=Clocks displaing real ingame time
depends=default,dye,display_api
optional_depends=intllib

The display_api dependency is apart of the mod pack.