2023-05-03 09:53:43 +02:00
|
|
|
plugins {
|
2023-08-02 04:27:53 +02:00
|
|
|
id "com.github.johnrengelman.shadow" version "8.1.1"
|
2023-05-03 09:53:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
architectury {
|
|
|
|
platformSetupLoomIde()
|
|
|
|
fabric()
|
|
|
|
}
|
|
|
|
|
|
|
|
loom {
|
2023-07-04 16:14:39 +02:00
|
|
|
runs {
|
|
|
|
data {
|
|
|
|
inherit client
|
|
|
|
name "Data Generation"
|
|
|
|
vmArg "-Dfabric-api.datagen"
|
2023-07-16 02:28:38 +02:00
|
|
|
vmArg "-Dfabric-api.datagen.output-dir=${project(":common").file("src/main/generated")}"
|
2023-07-04 16:14:39 +02:00
|
|
|
vmArg "-Dfabric-api.datagen.modid=dimdoors"
|
|
|
|
|
|
|
|
runDir "build/datagen"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-05-03 09:53:43 +02:00
|
|
|
accessWidenerPath = project(":common").loom.accessWidenerPath
|
|
|
|
}
|
|
|
|
|
|
|
|
configurations {
|
|
|
|
common
|
|
|
|
shadowCommon // Don't use shadow from the shadow plugin since it *excludes* files.
|
|
|
|
compileClasspath.extendsFrom common
|
|
|
|
runtimeClasspath.extendsFrom common
|
|
|
|
developmentFabric.extendsFrom common
|
|
|
|
}
|
|
|
|
|
2023-05-08 15:16:31 +02:00
|
|
|
def includeCompile(entry) {
|
|
|
|
project.dependencies {
|
|
|
|
modApi(entry)
|
|
|
|
include(entry)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-08-13 08:30:13 +02:00
|
|
|
repositories {
|
|
|
|
maven {
|
|
|
|
url = "https://maven.terraformersmc.com/releases/"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-05-03 09:53:43 +02:00
|
|
|
dependencies {
|
|
|
|
modImplementation "net.fabricmc:fabric-loader:${rootProject.fabric_loader_version}"
|
|
|
|
modApi "net.fabricmc.fabric-api:fabric-api:${rootProject.fabric_api_version}"
|
|
|
|
// Remove the next line if you don't want to depend on the API
|
|
|
|
modApi "dev.architectury:architectury-fabric:${rootProject.architectury_version}"
|
2023-08-13 08:30:13 +02:00
|
|
|
modApi "me.shedaniel.cloth:cloth-config-fabric:10.1.105"
|
2023-05-03 09:53:43 +02:00
|
|
|
|
2023-05-08 15:16:31 +02:00
|
|
|
includeCompile("curse.maven:cardinal-components-base-${project.project.cardinal_components}:${project.cardinal_components_base}")
|
|
|
|
includeCompile("curse.maven:cardinal-components-item-${project.project.cardinal_components}:${project.cardinal_components_item}")
|
|
|
|
includeCompile("curse.maven:cardinal-components-entity-${project.project.cardinal_components}:${project.cardinal_components_entity}")
|
|
|
|
includeCompile("curse.maven:cardinal-components-level-${project.project.cardinal_components}:${project.cardinal_components_level}")
|
|
|
|
includeCompile("curse.maven:cardinal-components-world-${project.project.cardinal_components}:${project.cardinal_components_world}")
|
|
|
|
includeCompile("curse.maven:cardinal-components-chunk-${project.project.cardinal_components}:${project.cardinal_components_chunk}")
|
|
|
|
|
2023-05-03 09:53:43 +02:00
|
|
|
common(project(path: ":common", configuration: "namedElements")) { transitive false }
|
|
|
|
shadowCommon(project(path: ":common", configuration: "transformProductionFabric")) { transitive false }
|
2023-05-12 16:13:06 +02:00
|
|
|
|
2023-05-13 15:04:26 +02:00
|
|
|
includeCompile "com.flowpowered:flow-math:1.0.3"
|
|
|
|
includeCompile "org.jgrapht:jgrapht-core:1.1.0"
|
|
|
|
includeCompile "com.github.DimensionalDevelopment:poly2tri.java:0.1.1"
|
|
|
|
|
2023-05-12 16:13:06 +02:00
|
|
|
modApi "mcp.mobius.waila:wthit:fabric-${wthitVersion}"
|
|
|
|
modApi "lol.bai:badpackets:fabric-0.2.0"
|
|
|
|
modApi "com.sk89q.worldedit:worldedit-fabric-mc${rootProject.minecraft_version}:${rootProject.worldedit}"
|
2023-08-13 08:30:13 +02:00
|
|
|
modApi "mcp.mobius.waila:wthit:fabric-${wthitVersion}"
|
|
|
|
modApi "com.terraformersmc:modmenu:6.3.1"
|
|
|
|
|
|
|
|
modRuntimeOnly "me.shedaniel:RoughlyEnoughItems-fabric:$rei_version"
|
|
|
|
modCompileOnly "me.shedaniel:RoughlyEnoughItems-api-fabric:$rei_version"
|
|
|
|
modCompileOnly "me.shedaniel:RoughlyEnoughItems-default-plugin-fabric:$rei_version"
|
2023-05-03 09:53:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
processResources {
|
|
|
|
inputs.property "version", project.version
|
|
|
|
|
|
|
|
filesMatching("fabric.mod.json") {
|
|
|
|
expand "version": project.version
|
|
|
|
}
|
2023-07-04 16:14:39 +02:00
|
|
|
|
|
|
|
from(rootProject.file("common/src/main/resources")) {
|
|
|
|
include("**/**")
|
|
|
|
duplicatesStrategy = DuplicatesStrategy.WARN
|
|
|
|
}
|
2023-05-03 09:53:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
shadowJar {
|
|
|
|
exclude "architectury.common.json"
|
|
|
|
|
|
|
|
configurations = [project.configurations.shadowCommon]
|
2023-08-02 04:27:53 +02:00
|
|
|
archiveClassifier = "dev-shadow"
|
2023-05-03 09:53:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
remapJar {
|
|
|
|
injectAccessWidener = true
|
2023-08-02 04:31:07 +02:00
|
|
|
inputFile.set(shadowJar.archiveFile)
|
2023-05-03 09:53:43 +02:00
|
|
|
dependsOn shadowJar
|
2023-08-02 04:27:53 +02:00
|
|
|
archiveClassifier = "fabric"
|
2023-05-03 09:53:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
jar {
|
2023-08-02 04:27:53 +02:00
|
|
|
archiveClassifier = "dev"
|
2023-05-03 09:53:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
sourcesJar {
|
|
|
|
def commonSources = project(":common").sourcesJar
|
|
|
|
dependsOn commonSources
|
|
|
|
from commonSources.archiveFile.map { zipTree(it) }
|
2023-07-16 02:28:38 +02:00
|
|
|
duplicatesStrategy = DuplicatesStrategy.WARN
|
2023-05-03 09:53:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
components.java {
|
|
|
|
withVariantsFromConfiguration(project.configurations.shadowRuntimeElements) {
|
|
|
|
skip()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-07-04 16:14:39 +02:00
|
|
|
sourceSets {
|
|
|
|
main {
|
|
|
|
java {
|
|
|
|
srcDir "src/main/datagen"
|
|
|
|
}
|
|
|
|
resources {
|
|
|
|
srcDirs += [
|
2023-07-16 02:28:38 +02:00
|
|
|
project(":common").file("src/main/generated")
|
2023-07-04 16:14:39 +02:00
|
|
|
]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|