Adding to your Mod
- Add the Amalgamation Maven repository to your repositories
repositories {
maven {
url "https://dl.cloudsmith.io/public/mythic_goose/amalgamtion/maven/"
}
}
- Add Amalgamation as a dependency using its latest version under dependencies (please go to Modrinth if you're after an older version)
dependencies {
implementation 'org.mythic_goose.amalgamation:amalgamation-fabric-26.2:0.0.0'
}
Note: There is both a Fabric and a NeoForge version available. So replace 'amalgamation-fabric-26.2' or 'amalgamation-neoforge-26.2' with the appropriate loader of your target modloader. If you are using a multi-loader setup, you will need to include both versions as dependencies as well as 'amalgamation-common-26.2'.
- Applying your MOD_ID to the Registry Classes
In order to use Amalgamation, you will need to apply your MOD_ID to all the registry classes and attachment and registrationBackend. This is done by calling the following methods in your main mod class:
NeoForgeRegistrationBackend.init(eventBus);
NeoForgeAttachmentHelper.init(MOD_ID, eventBus);
DeferredRegister.setModId("your_mod_id");
Note: This should be done in the constructor of your main mod class & BEFORE EVERYTHING ELSE