-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathbuild.gradle
57 lines (48 loc) · 1.51 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
buildscript {
repositories {
maven { url = "https://maven.minecraftforge.net" }
mavenCentral()
}
dependencies {
classpath group: "net.minecraftforge.gradle", name: "ForgeGradle", version: "5.1.+", changing: true
}
}
//Apply plugins
apply plugin: "net.minecraftforge.gradle"
//Set file name.
version = "V25"
group = "minecrafttransportsimulator"
archivesBaseName = "MTS Official Pack"
//Options for Java version to compile to.
sourceCompatibility = targetCompatibility = "1.8"
compileJava {
options.compilerArgs << "-Xlint:deprecation" << "-Xlint:unchecked"
}
//Minecraft mappings and run configs.
minecraft {
// The mappings can be changed at any time, and must be in the following format.
// Channel: Version:
// snapshot YYYYMMDD Snapshot are built nightly.
// stable # Stables are built at the discretion of the MCP team.
// official MCVersion Official field/method names from Mojang mapping files
mappings channel: "official", version: "1.16.5"
//Run configurations.
runs {
client {
workingDirectory project.file("run")
}
server {
workingDirectory project.file("runServer")
}
}
}
//Specify dependencies.
dependencies {
//Minecraft to use.
minecraft "net.minecraftforge:forge:1.16.5-36.2.23"
}
//Now compile the mod.
jar.finalizedBy("reobfJar")
tasks.withType(JavaCompile).configureEach {
options.encoding = "UTF-8" // Use the UTF-8 charset for Java compilation
}