import io.github.rancraftplayz.jarmerger.JarMergerPlugin buildscript { dependencies{ classpath files('plugins/DHJarMerger-1.0.jar') } } plugins { id "architectury-plugin" version "3.4-SNAPSHOT" id "dev.architectury.loom" version "0.10.0-SNAPSHOT" apply false } apply plugin: JarMergerPlugin architectury { minecraft = rootProject.minecraft_version } subprojects { p -> apply plugin: "dev.architectury.loom" loom { silentMojangMappingsLicense() } configurations { common shadowMe implementation.extendsFrom shadowMe } dependencies { minecraft "com.mojang:minecraft:${rootProject.minecraft_version}" // The following line declares the mojmap mappings mappings loom.officialMojangMappings() if (p != project(":forge")) { // We depend on fabric loader here to use the fabric @Environment annotations and get the mixin dependencies // Do NOT use other classes from fabric loader unless working with fabric modImplementation "net.fabricmc:fabric-loader:${rootProject.fabric_loader_version}" } if (p != project(":core")) { common(project(":core")) { transitive false } shadowMe(project(":core")) { transitive false } } } } allprojects { p -> apply plugin: "java" apply plugin: "architectury-plugin" apply plugin: "maven-publish" archivesBaseName = rootProject.archives_base_name version = rootProject.mod_version group = rootProject.maven_group repositories { mavenCentral() // used to download and compile dependencies from git repos maven { url 'https://jitpack.io' } } tasks.withType(JavaCompile) { if (p != project(":core")) { // Minecraft 1.18 (1.18-pre2) upwards uses Java 17. options.release = 17 } } java { withSourcesJar() } if (p == project(":core") || p == project(":common")) { runClient.enabled = false runServer.enabled = false } }