49 lines
1.2 KiB
Groovy
49 lines
1.2 KiB
Groovy
|
|
buildscript {
|
|
repositories {
|
|
jcenter()
|
|
maven { url = "http://files.minecraftforge.net/maven" }
|
|
mavenCentral()
|
|
}
|
|
dependencies {
|
|
classpath "net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT"
|
|
}
|
|
}
|
|
|
|
apply plugin: 'net.minecraftforge.gradle.forge'
|
|
|
|
minecraft {
|
|
version = mc_version + "-" + forge_version
|
|
runDir = "../run"
|
|
|
|
mappings = mcp_mappings
|
|
|
|
replaceIn 'MatterLink.kt'
|
|
replace '@VERSION@', mod_version
|
|
}
|
|
|
|
processResources {
|
|
// this will ensure that this task is redone when the versions change.
|
|
inputs.property "version", project.version
|
|
inputs.property "mcversion", project.minecraft.version
|
|
|
|
// replace stuff in mcmod.info, nothing else
|
|
from(project(":core").sourceSets.main.resources.srcDirs) {
|
|
include 'mcmod.info'
|
|
|
|
// replace version and mcversion
|
|
expand 'version': project.version, 'mcversion': project.minecraft.version
|
|
}
|
|
|
|
// copy everything else except the mcmod.info
|
|
from(project(":core").sourceSets.main.resources.srcDirs) {
|
|
exclude 'mcmod.info'
|
|
}
|
|
|
|
}
|
|
|
|
reobf {
|
|
shadowJar { mappingType = 'SEARGE' }
|
|
}
|
|
|
|
tasks.reobfShadowJar.mustRunAfter shadowJar |