2018-08-08 08:46:53 +05:30
|
|
|
/*
|
|
|
|
* This file is part of Baritone.
|
|
|
|
*
|
|
|
|
* Baritone is free software: you can redistribute it and/or modify
|
2018-09-18 03:41:40 +05:30
|
|
|
* it under the terms of the GNU Lesser General Public License as published by
|
2018-08-08 08:46:53 +05:30
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
2018-08-08 09:45:22 +05:30
|
|
|
* Baritone is distributed in the hope that it will be useful,
|
2018-08-08 08:46:53 +05:30
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
2018-09-18 03:41:40 +05:30
|
|
|
* GNU Lesser General Public License for more details.
|
2018-08-08 08:46:53 +05:30
|
|
|
*
|
2018-09-18 03:41:40 +05:30
|
|
|
* You should have received a copy of the GNU Lesser General Public License
|
2018-08-08 08:46:53 +05:30
|
|
|
* along with Baritone. If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
2018-08-01 22:39:39 +05:30
|
|
|
group 'baritone'
|
2018-10-17 04:33:51 +05:30
|
|
|
version '1.0.0-hotfix-2'
|
2018-08-01 22:39:39 +05:30
|
|
|
|
|
|
|
buildscript {
|
|
|
|
repositories {
|
|
|
|
maven {
|
|
|
|
name = 'forge'
|
|
|
|
url = 'http://files.minecraftforge.net/maven'
|
|
|
|
}
|
|
|
|
maven {
|
|
|
|
name = 'SpongePowered'
|
|
|
|
url = 'http://repo.spongepowered.org/maven'
|
|
|
|
}
|
|
|
|
jcenter()
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
classpath 'net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT'
|
|
|
|
classpath 'org.spongepowered:mixingradle:0.6-SNAPSHOT'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-10-13 07:51:16 +05:30
|
|
|
|
|
|
|
import baritone.gradle.task.CreateDistTask
|
|
|
|
import baritone.gradle.task.ProguardTask
|
2018-10-13 04:26:09 +05:30
|
|
|
|
2018-08-01 22:39:39 +05:30
|
|
|
apply plugin: 'java'
|
2018-09-05 04:38:29 +05:30
|
|
|
apply plugin: 'net.minecraftforge.gradle.tweaker-client'
|
|
|
|
apply plugin: 'org.spongepowered.mixin'
|
2018-08-01 22:39:39 +05:30
|
|
|
|
|
|
|
sourceCompatibility = targetCompatibility = '1.8'
|
|
|
|
compileJava {
|
|
|
|
sourceCompatibility = targetCompatibility = '1.8'
|
|
|
|
}
|
|
|
|
|
2018-09-05 05:18:00 +05:30
|
|
|
sourceSets {
|
|
|
|
launch {
|
|
|
|
compileClasspath += main.compileClasspath + main.runtimeClasspath + main.output
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-08-01 22:39:39 +05:30
|
|
|
minecraft {
|
|
|
|
version = '1.12.2'
|
2018-11-05 04:39:40 +05:30
|
|
|
mappings = 'stable_39'
|
2018-08-01 23:35:04 +05:30
|
|
|
tweakClass = 'baritone.launch.BaritoneTweaker'
|
2018-08-01 22:39:39 +05:30
|
|
|
runDir = 'run'
|
2018-10-11 00:39:41 +05:30
|
|
|
|
|
|
|
// The sources jar should use SRG names not MCP to ensure compatibility with all mappings
|
|
|
|
makeObfSourceJar = true
|
2018-08-01 22:39:39 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
|
|
|
|
maven {
|
|
|
|
name = 'spongepowered-repo'
|
|
|
|
url = 'http://repo.spongepowered.org/maven/'
|
|
|
|
}
|
2018-10-12 01:23:20 +05:30
|
|
|
|
|
|
|
maven {
|
|
|
|
name = 'impactdevelopment-repo'
|
|
|
|
url = 'https://impactdevelopment.github.io/maven/'
|
|
|
|
}
|
2018-08-01 22:39:39 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2018-10-16 05:30:52 +05:30
|
|
|
runtime launchCompile('com.github.ImpactDevelopment:SimpleTweaker:1.2')
|
2018-09-05 05:18:00 +05:30
|
|
|
runtime launchCompile('org.spongepowered:mixin:0.7.11-SNAPSHOT') {
|
2018-08-01 22:39:39 +05:30
|
|
|
// Mixin includes a lot of dependencies that are too up-to-date
|
|
|
|
exclude module: 'launchwrapper'
|
|
|
|
exclude module: 'guava'
|
|
|
|
exclude module: 'gson'
|
|
|
|
exclude module: 'commons-io'
|
|
|
|
exclude module: 'log4j-core'
|
|
|
|
}
|
|
|
|
testImplementation 'junit:junit:4.12'
|
|
|
|
}
|
2018-08-26 12:15:33 +05:30
|
|
|
|
|
|
|
mixin {
|
|
|
|
defaultObfuscationEnv notch
|
2018-09-05 05:20:53 +05:30
|
|
|
add sourceSets.launch, 'mixins.baritone.refmap.json'
|
2018-08-26 12:15:33 +05:30
|
|
|
}
|
2018-09-05 05:18:00 +05:30
|
|
|
|
|
|
|
jar {
|
2018-09-11 23:59:54 +05:30
|
|
|
from sourceSets.launch.output, sourceSets.api.output
|
2018-10-08 04:37:35 +05:30
|
|
|
preserveFileTimestamps = false
|
|
|
|
reproducibleFileOrder = true
|
2018-09-05 05:18:00 +05:30
|
|
|
}
|
2018-10-13 04:26:09 +05:30
|
|
|
|
|
|
|
task proguard(type: ProguardTask) {
|
|
|
|
url 'https://downloads.sourceforge.net/project/proguard/proguard/6.0/proguard6.0.3.zip'
|
|
|
|
extract 'proguard6.0.3/lib/proguard.jar'
|
|
|
|
}
|
|
|
|
|
2018-10-13 07:51:16 +05:30
|
|
|
task createDist(type: CreateDistTask, dependsOn: proguard)
|
|
|
|
|
|
|
|
build.finalizedBy(createDist)
|