2022-12-18 22:07:24 +01:00
|
|
|
buildscript {
|
|
|
|
dependencies {
|
2024-07-31 14:32:24 +02:00
|
|
|
classpath 'com.github.dexman545:Outlet:1.6.1'
|
2022-12-18 22:07:24 +01:00
|
|
|
}
|
|
|
|
}
|
2020-01-16 12:35:46 +01:00
|
|
|
plugins {
|
2024-09-26 00:51:30 +02:00
|
|
|
id 'fabric-loom' version '1.7-SNAPSHOT'
|
2022-12-18 22:07:24 +01:00
|
|
|
id 'com.modrinth.minotaur' version '2.+'
|
2024-07-31 14:32:24 +02:00
|
|
|
id 'org.ajoberstar.reckon' version '0.13.1'
|
2018-09-12 01:29:35 +02:00
|
|
|
}
|
2024-07-31 14:32:24 +02:00
|
|
|
apply plugin: 'io.github.dexman545.outlet'
|
2018-09-12 01:29:35 +02:00
|
|
|
|
2021-08-04 15:38:03 +02:00
|
|
|
java {
|
|
|
|
toolchain {
|
2024-09-26 22:36:35 +02:00
|
|
|
languageVersion = JavaLanguageVersion.of(21)
|
2021-08-04 15:38:03 +02:00
|
|
|
}
|
2022-06-25 00:19:55 +02:00
|
|
|
withSourcesJar()
|
2021-06-26 13:15:42 +02:00
|
|
|
}
|
2021-02-13 20:53:11 +01:00
|
|
|
|
2022-12-18 22:07:24 +01:00
|
|
|
outlet.allowSnapshotsForProject = false
|
|
|
|
outlet.mcVersionRange = project.minecraft_version_range
|
|
|
|
|
2021-06-26 13:15:42 +02:00
|
|
|
group = project.group
|
|
|
|
description = project.displayname
|
|
|
|
archivesBaseName = project.name
|
2021-02-13 20:53:11 +01:00
|
|
|
|
2021-12-22 10:15:09 +01:00
|
|
|
loom {
|
|
|
|
mixin.defaultRefmapName = 'unicopia.mixin.refmap.json'
|
|
|
|
accessWidenerPath = file('src/main/resources/unicopia.aw')
|
2024-03-27 20:44:12 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
fabricApi {
|
|
|
|
configureDataGeneration {
|
|
|
|
modId = 'unicopia'
|
2024-03-12 19:54:19 +01:00
|
|
|
}
|
2021-08-04 15:38:03 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
reckon {
|
|
|
|
scopeFromProp()
|
2022-12-15 12:15:50 +01:00
|
|
|
stageFromProp 'beta', 'rc', 'final'
|
2021-08-04 15:38:03 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenLocal()
|
2023-05-31 19:05:18 +02:00
|
|
|
flatDir { dirs 'lib' }
|
2023-08-04 19:25:52 +02:00
|
|
|
maven { name 'trinkets'; url 'https://maven.ladysnake.org/releases' }
|
2022-12-15 12:15:50 +01:00
|
|
|
maven { name 'mod-menu'; url 'https://maven.terraformersmc.com/' }
|
2023-01-09 01:27:22 +01:00
|
|
|
maven { name 'minelp-snapshot'; url 'https://repo.minelittlepony-mod.com/maven/snapshot' }
|
|
|
|
maven { name 'minelp-releases'; url 'https://repo.minelittlepony-mod.com/maven/release' }
|
2023-05-25 20:02:08 +02:00
|
|
|
maven { name 'TerraformersMC'; url 'https://maven.terraformersmc.com/' }
|
2024-09-26 00:51:30 +02:00
|
|
|
maven { name 'Iris Deps'; url "https://maven.covers1624.net/" }
|
2024-03-31 17:47:40 +02:00
|
|
|
maven { name 'Greenhouse Maven For Farmers delight'; url 'https://maven.greenhouseteam.dev/releases/' }
|
|
|
|
maven { name 'Porting Lib For Farmers delight'; url = 'https://mvn.devos.one/releases/' }
|
2024-02-08 23:59:21 +01:00
|
|
|
maven { name 'Modrinth'; url 'https://api.modrinth.com/maven' }
|
|
|
|
maven { name 'JitPack'; url 'https://jitpack.io'; content { includeGroup "com.github.Virtuoel" } }
|
2018-09-12 01:29:35 +02:00
|
|
|
}
|
|
|
|
|
2019-01-07 09:35:11 +01:00
|
|
|
dependencies {
|
2021-06-26 13:15:42 +02:00
|
|
|
minecraft "com.mojang:minecraft:${project.minecraft_version}"
|
|
|
|
mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2"
|
|
|
|
modApi "net.fabricmc:fabric-loader:${project.loader_version}"
|
|
|
|
modApi "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"
|
|
|
|
|
2021-08-04 15:38:03 +02:00
|
|
|
modApi "com.minelittlepony:minelittlepony:${project.minelp_version}"
|
2020-04-22 22:41:00 +02:00
|
|
|
|
2021-08-04 15:38:03 +02:00
|
|
|
modApi "com.minelittlepony:kirin:${project.kirin_version}"
|
|
|
|
include "com.minelittlepony:kirin:${project.kirin_version}"
|
2020-01-16 12:35:46 +01:00
|
|
|
|
2022-12-29 22:23:49 +01:00
|
|
|
modApi "com.sollace:fabwork:${project.fabwork_version}"
|
|
|
|
include "com.sollace:fabwork:${project.fabwork_version}"
|
|
|
|
|
2023-05-31 19:05:18 +02:00
|
|
|
compileOnly "com.sollace:Romanizer:Romanizer:1.0.2"
|
|
|
|
include "com.sollace:Romanizer:Romanizer:1.0.2"
|
2023-05-21 14:52:09 +02:00
|
|
|
|
2022-12-07 21:47:33 +01:00
|
|
|
modCompileOnly "com.terraformersmc:modmenu:${project.modmenu_version}"
|
2024-09-26 00:51:30 +02:00
|
|
|
|
|
|
|
modImplementation "com.terraformersmc.terraform-api:terraform-wood-api-v1:${project.terraformer_api_version}"
|
|
|
|
include "com.terraformersmc.terraform-api:terraform-wood-api-v1:${project.terraformer_api_version}"
|
|
|
|
|
|
|
|
modImplementation "com.github.MattiDragon:TlaApi:${project.tla_version}"
|
|
|
|
include "com.github.MattiDragon:TlaApi:${project.tla_version}"
|
|
|
|
|
2024-09-18 17:52:44 +02:00
|
|
|
if (project.use_trinkets == '1') {
|
|
|
|
modCompileOnly "dev.emi:trinkets:${project.trinkets_version}"
|
|
|
|
modCompileOnly "dev.onyxstudios.cardinal-components-api:cardinal-components-base:5.3.0"
|
|
|
|
modCompileOnly "dev.onyxstudios.cardinal-components-api:cardinal-components-entity:5.3.0"
|
|
|
|
} else {
|
|
|
|
modCompileOnly "dev.emi:trinkets-dummy:${project.trinkets_version}"
|
|
|
|
}
|
2023-08-04 19:25:52 +02:00
|
|
|
|
2024-09-26 00:51:30 +02:00
|
|
|
if (project.use_farmers_delight == '1') {
|
|
|
|
modImplementation "vectorwing:FarmersDelight-Refabricated:${project.farmers_delight_version}", {
|
|
|
|
exclude group: "net.fabricmc"
|
|
|
|
}
|
|
|
|
}
|
2024-02-11 01:28:39 +01:00
|
|
|
if (project.use_pehkui == '1') {
|
|
|
|
modCompileOnly "maven.modrinth:pehkui:${project.pehkui_version}", { exclude group: "net.fabricmc.fabric-api" }
|
|
|
|
modCompileOnly "com.github.Virtuoel:KanosConfig:0.4.1", { exclude group: "net.fabricmc.fabric-api" }
|
|
|
|
}
|
|
|
|
|
|
|
|
if (project.use_sodium == '1') {
|
2024-02-20 19:40:04 +01:00
|
|
|
modCompileOnly "maven.modrinth:indium:${project.indium_version}", { exclude group: "net.fabricmc.fabric-api" }
|
2024-02-11 01:28:39 +01:00
|
|
|
modCompileOnly "maven.modrinth:sodium:${project.sodium_version}", { exclude group: "net.fabricmc.fabric-api" }
|
2024-09-21 22:41:21 +02:00
|
|
|
if (project.use_iris == '1') {
|
|
|
|
modCompileOnly "maven.modrinth:iris:${project.iris_version}", { exclude group: "net.fabricmc.fabric-api" }
|
|
|
|
modImplementation "org.anarres:jcpp:1.4.14"
|
|
|
|
modImplementation "org.antlr:antlr4-runtime:4.13.1"
|
|
|
|
modImplementation "io.github.douira:glsl-transformer:2.0.1"
|
|
|
|
}
|
2024-02-11 01:28:39 +01:00
|
|
|
}
|
2024-02-08 23:59:21 +01:00
|
|
|
|
2023-05-31 20:43:58 +02:00
|
|
|
if (project.tmi_type == 'emi') {
|
2023-05-30 23:52:02 +02:00
|
|
|
modCompileOnly "dev.emi:emi-fabric:${project.emi_version}"
|
2024-09-26 00:51:30 +02:00
|
|
|
}
|
|
|
|
if (project.tmi_type == 'rei') {
|
|
|
|
modCompileOnly "me.shedaniel:RoughlyEnoughItems-default-plugin-fabric:${project.rei_version}"
|
|
|
|
modCompileOnly "me.shedaniel:RoughlyEnoughItems-fabric:${project.rei_version}"
|
|
|
|
modCompileOnly "dev.architectury:architectury-fabric:${project.rei_architectury_version}"
|
|
|
|
modCompileOnly "me.shedaniel.cloth:basic-math:${project.rei_cloth_basic_math_version}"
|
|
|
|
modCompileOnly "me.shedaniel.cloth:cloth-config-fabric:${project.rei_cloth_config_version}"
|
2023-05-31 20:43:58 +02:00
|
|
|
}
|
2021-06-26 13:15:42 +02:00
|
|
|
}
|
|
|
|
|
2024-03-31 17:47:40 +02:00
|
|
|
remapJar {
|
|
|
|
addNestedDependencies = true
|
2024-03-12 19:54:19 +01:00
|
|
|
}
|
|
|
|
|
2021-06-26 13:15:42 +02:00
|
|
|
processResources {
|
2021-08-04 15:38:03 +02:00
|
|
|
inputs.property "version", project.version.toString()
|
2021-02-10 19:36:19 +01:00
|
|
|
|
2021-06-26 13:15:42 +02:00
|
|
|
filesMatching("fabric.mod.json") {
|
2023-09-10 17:35:11 +02:00
|
|
|
expand "version": project.version.toString(),
|
|
|
|
"minecraftVersion": project.minecraft_version_range,
|
|
|
|
"loaderVersion": ">=${project.loader_version}",
|
|
|
|
"fabricVersion": ">=${project.fabric_version}",
|
|
|
|
"fabworkVersion": ">=${project.fabwork_version}",
|
|
|
|
"kirinVersion": ">=${project.kirin_version}"
|
2021-02-18 23:07:22 +01:00
|
|
|
}
|
2021-06-26 13:15:42 +02:00
|
|
|
}
|
2021-02-18 23:07:22 +01:00
|
|
|
|
2021-06-26 13:15:42 +02:00
|
|
|
tasks.withType(JavaCompile) {
|
|
|
|
options.encoding = "UTF-8"
|
|
|
|
}
|
2022-12-18 22:07:24 +01:00
|
|
|
|
|
|
|
tasks.modrinth {
|
|
|
|
onlyIf {
|
|
|
|
def stage = version.version.stage.value
|
|
|
|
stage == null || stage.name != 'beta'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
modrinth {
|
|
|
|
token = System.env.MODRINTH_KEY
|
|
|
|
projectId = project.modrinth_project_id
|
|
|
|
//featured = true
|
|
|
|
versionNumber = version.toString()
|
|
|
|
versionName = archivesBaseName + '-' + version
|
|
|
|
changelog = "[Changelog](https://github.com/Sollace/Unicopia/releases/tag/${version.toString()})"
|
|
|
|
uploadFile = remapJar
|
|
|
|
outlet.mcVersions().each{ver ->
|
|
|
|
gameVersions.add ver
|
|
|
|
}
|
|
|
|
dependencies {
|
2023-10-04 15:56:10 +02:00
|
|
|
required.project 'P7dR8mSH'
|
|
|
|
optional.project '5aaWibi9'
|
|
|
|
optional.project 'JBjInUXM'
|
|
|
|
optional.project 'fRiHVvU7'
|
2022-12-18 22:07:24 +01:00
|
|
|
}
|
|
|
|
}
|