119 lines
3.4 KiB
Groovy
119 lines
3.4 KiB
Groovy
plugins {
|
|
id 'com.github.johnrengelman.shadow'
|
|
id "me.shedaniel.unified-publishing"
|
|
}
|
|
|
|
loom {
|
|
forge {
|
|
mixinConfig("colorwheel.mixins.iris.json", "colorwheel.mixins.flw.json", "colorwheel.mixins.mc.json")
|
|
}
|
|
runs {
|
|
client {
|
|
property 'mixin.env.remapRefMap', 'true'
|
|
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"
|
|
}
|
|
}
|
|
}
|
|
|
|
architectury {
|
|
platformSetupLoomIde()
|
|
forge()
|
|
}
|
|
|
|
configurations {
|
|
common {
|
|
canBeResolved = true
|
|
canBeConsumed = false
|
|
}
|
|
compileClasspath.extendsFrom common
|
|
runtimeClasspath.extendsFrom common
|
|
developmentForge.extendsFrom common
|
|
|
|
// Files in this configuration will be bundled into your mod using the Shadow plugin.
|
|
// Don't use the `shadow` configuration from the plugin itself as it's meant for excluding files.
|
|
shadowBundle {
|
|
canBeResolved = true
|
|
canBeConsumed = false
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
forge "net.minecraftforge:forge:$rootProject.forge_version"
|
|
|
|
common(project(path: ':common', configuration: 'namedElements')) { transitive false }
|
|
shadowBundle project(path: ':common', configuration: 'transformProductionForge')
|
|
|
|
modLocalRuntime "dev.engine-room.flywheel:flywheel-forge-${minecraft_version}:${flywheel_version}"
|
|
modLocalRuntime "dev.engine-room.vanillin:vanillin-forge-${minecraft_version}:${vanillin_version}"
|
|
|
|
modLocalRuntime "org.embeddedt:celeritas-forge-mc20.1:${celeritas_version}"
|
|
|
|
modLocalRuntime("com.simibubi.create:create-${minecraft_version}:${create_forge_version}:slim") { transitive = false }
|
|
modLocalRuntime("net.createmod.ponder:Ponder-Forge-${minecraft_version}:${ponder_version}")
|
|
modLocalRuntime("com.tterrag.registrate:Registrate:${registrate_forge_version}")
|
|
localRuntime "io.github.llamalad7:mixinextras-forge:${mixin_extras_version}"
|
|
}
|
|
|
|
processResources {
|
|
inputs.property 'version', project.version
|
|
|
|
filesMatching('META-INF/mods.toml') {
|
|
expand version: project.version
|
|
}
|
|
}
|
|
|
|
shadowJar {
|
|
configurations = [project.configurations.shadowBundle]
|
|
archiveClassifier = 'dev-shadow'
|
|
}
|
|
|
|
remapJar {
|
|
inputFile.set shadowJar.archiveFile
|
|
}
|
|
|
|
unifiedPublishing {
|
|
project {
|
|
displayName = "$project.version-forge"
|
|
version = "$project.version"
|
|
releaseType = "beta"
|
|
changelog = new File("${rootProject.rootDir.toPath().toString()}/CHANGELOG.md").getText('UTF-8')
|
|
gameVersions = ["1.20.1"]
|
|
gameLoaders = ["forge"]
|
|
|
|
mainPublication remapJar
|
|
|
|
relations {
|
|
depends {
|
|
curseforge = "oculus"
|
|
modrinth = "oculus"
|
|
}
|
|
optional {
|
|
curseforge = "create"
|
|
modrinth = "create"
|
|
}
|
|
optional {
|
|
curseforge = "vanillin"
|
|
modrinth = "flw-vanillin"
|
|
}
|
|
optional {
|
|
curseforge = "colorwheel-patcher"
|
|
modrinth = "colorwheel-patcher"
|
|
}
|
|
}
|
|
|
|
if (System.getenv("CF_TOKEN") != null) {
|
|
curseforge {
|
|
token = System.getenv("CF_TOKEN")
|
|
id = "1254143"
|
|
}
|
|
}
|
|
|
|
if (System.getenv("MODRINTH_TOKEN") != null) {
|
|
modrinth {
|
|
token = System.getenv("MODRINTH_TOKEN")
|
|
id = "BzHgFoGz"
|
|
}
|
|
}
|
|
}
|
|
}
|