2021-02-16 21:39:05 +01:00
|
|
|
buildscript {
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
jcenter()
|
|
|
|
mavenLocal()
|
|
|
|
mavenCentral()
|
|
|
|
|
|
|
|
maven { url 'https://files.minecraftforge.net/maven' }
|
|
|
|
maven { url 'https://plugins.gradle.org/m2' }
|
2021-03-28 04:56:09 +02:00
|
|
|
maven { url 'https://repo.spongepowered.org/repository/maven-public' }
|
2021-02-16 21:39:05 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '2.3-SNAPSHOT'
|
|
|
|
classpath group: 'org.spongepowered', name: 'mixingradle', version: '0.6-SNAPSHOT'
|
|
|
|
classpath group: 'com.github.jengelman.gradle.plugins', name: 'shadow', version: '4.0.4'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
apply plugin: "net.minecraftforge.gradle.forge"
|
|
|
|
apply plugin: "org.spongepowered.mixin"
|
|
|
|
apply plugin: "com.github.johnrengelman.shadow"
|
|
|
|
apply plugin: "java"
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
|
|
|
|
mavenLocal()
|
|
|
|
mavenCentral()
|
|
|
|
jcenter()
|
|
|
|
|
2021-03-28 04:56:09 +02:00
|
|
|
maven {
|
|
|
|
url = 'https://repo.spongepowered.org/repository/maven-public'
|
2021-02-16 21:39:05 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-03-28 04:56:09 +02:00
|
|
|
version = "1.0.0.0"
|
2021-05-14 17:09:21 +02:00
|
|
|
group = "de.enzaxd.viaforge"
|
2021-02-16 21:39:05 +01:00
|
|
|
archivesBaseName = "ViaForge"
|
|
|
|
|
|
|
|
sourceCompatibility = JavaVersion.VERSION_1_8
|
|
|
|
targetCompatibility = JavaVersion.VERSION_1_8
|
2021-05-14 17:09:21 +02:00
|
|
|
compileJava.options.encoding = 'UTF-8'
|
2021-02-16 21:39:05 +01:00
|
|
|
|
|
|
|
minecraft {
|
2021-03-28 04:56:09 +02:00
|
|
|
version = "1.12.2-14.23.5.2768"
|
2021-02-16 21:39:05 +01:00
|
|
|
runDir = 'run'
|
|
|
|
mappings = "stable_39"
|
|
|
|
makeObfSourceJar = true
|
|
|
|
}
|
|
|
|
|
|
|
|
sourceSets {
|
|
|
|
main.java.srcDirs += 'src/main/java'
|
|
|
|
main.java.srcDirs += '../shared/main/java'
|
|
|
|
main.resources.srcDirs += '../shared/main/resources'
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenLocal()
|
|
|
|
mavenCentral()
|
|
|
|
jcenter()
|
|
|
|
|
|
|
|
maven { url 'https://jitpack.io' }
|
2021-03-28 04:56:09 +02:00
|
|
|
maven {
|
|
|
|
name = 'spongepowered-repo'
|
|
|
|
url = 'https://repo.spongepowered.org/maven/'
|
|
|
|
}
|
2021-02-16 21:39:05 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2021-03-28 04:56:09 +02:00
|
|
|
compile("org.spongepowered:mixin:0.8") {
|
2021-02-16 21:39:05 +01:00
|
|
|
exclude module: "launchwrapper"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
processResources {
|
|
|
|
inputs.property "version", project.version
|
|
|
|
inputs.property "mcversion", project.minecraft.version
|
|
|
|
|
|
|
|
from(sourceSets.main.resources.srcDirs) {
|
|
|
|
include 'mcmod.info'
|
|
|
|
|
|
|
|
expand 'version':project.version, 'mcversion':project.minecraft.version
|
|
|
|
}
|
|
|
|
|
|
|
|
from(sourceSets.main.resources.srcDirs) {
|
|
|
|
exclude 'mcmod.info'
|
|
|
|
}
|
|
|
|
|
|
|
|
rename '(.+_at.cfg)', 'META-INF/$1'
|
|
|
|
}
|
|
|
|
|
|
|
|
mixin {
|
|
|
|
add sourceSets.main, "mixins.viaforge.refmap.json"
|
|
|
|
}
|
|
|
|
|
|
|
|
jar {
|
|
|
|
manifest.attributes(
|
|
|
|
"MixinConfigs": "mixins.viaforge.json",
|
|
|
|
"tweakClass": "org.spongepowered.asm.launch.MixinTweaker",
|
|
|
|
"TweakOrder": 0,
|
2021-05-14 17:09:21 +02:00
|
|
|
"FMLCorePluginContainsFMLMod": "de.enzaxd.viaforge.injection.MixinLoader"
|
2021-02-16 21:39:05 +01:00
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
apply plugin: "idea"
|
|
|
|
|
|
|
|
idea {
|
|
|
|
module {
|
|
|
|
inheritOutputDirs = true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
shadowJar {
|
|
|
|
dependencies {
|
|
|
|
include(dependency('org.spongepowered:mixin'))
|
|
|
|
}
|
|
|
|
|
|
|
|
exclude 'dummyThing'
|
|
|
|
exclude 'LICENSE.txt'
|
|
|
|
|
|
|
|
classifier = ""
|
|
|
|
}
|
|
|
|
|
|
|
|
reobf { shadowJar { mappingType = "SEARGE" } }
|
|
|
|
tasks.reobfShadowJar.mustRunAfter shadowJar
|
|
|
|
|
|
|
|
configurations {
|
|
|
|
external
|
|
|
|
compile.extendsFrom external
|
|
|
|
}
|
|
|
|
|
|
|
|
build.dependsOn shadowJar
|