-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathbuild.gradle
106 lines (86 loc) · 2.82 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
plugins {
alias quilt.plugins.quilt.loom
}
project.configurations.runtimeClasspath {
exclude(group: "loom_mappings_1_21_1_layered_hash_653365834_v2.net.fabricmc", module: "fabric-loader")
}
dependencies {
minecraft libs.minecraft
mappings(loom.layered {
it.officialMojangMappings()
it.parchment("${libs.parchment.mappings.get()}@zip")
})
modImplementation fabric.fabric.loader
modImplementation (fabric.fabric.api) {
exclude group: "net.fabricmc", module: "fabric-loader"
}
compileOnly project(":Common")
modImplementation (libs.resourcefulconfig.fabric) {
exclude group: "net.fabricmc", module: "fabric-loader"
}
modImplementation libs.commonnetworking.fabric
modImplementation fabric.trinkets
modImplementation fabric.bundles.cca
modCompileOnly (fabric.modmenu) {
transitive = false
}
modLocalRuntime (fabric.modmenu) {
transitive = false
}
modCompileOnly fabric.cameraoverhaul
// modLocalRuntime fabric.cameraoverhaul
// modLocalRuntime fabric.cloth
modCompileOnly libs.figura.fabric
// modLocalRuntime libs.figura.fabric
// localRuntime libs.bundles.figura.runtime
// modCompileOnly "${libs.emi.fabric.get()}:api"
}
loom {
mods {
"${mod_id}" {
// Tell Loom about each source set used by your mod here. This ensures that your mod's classes are properly transformed by Loader.
sourceSet("main")
}
}
if (project(":Common").file("src/main/resources/${mod_id}.accesswidener").exists()) {
accessWidenerPath.set(project(":Common").file("src/main/resources/${mod_id}.accesswidener"))
}
mixin {
defaultRefmapName.set("${mod_id}.refmap.json")
}
runs {
client {
client()
setConfigName("Fabric Client")
ideConfigGenerated(true)
runDir("run")
if (rootProject.hasProperty('mc_uuid')) {
programArgs("--uuid", rootProject.mc_uuid)
}
if (rootProject.hasProperty('mc_username')) {
programArgs("--username", rootProject.mc_username)
}
if (rootProject.hasProperty('mc_java_agent_path')) {
vmArg("-javaagent:${rootProject.mc_java_agent_path}")
}
}
server {
server()
setConfigName("Fabric Server")
ideConfigGenerated(true)
runDir("run/server")
}
}
}
tasks.named("compileJava", JavaCompile) {
source(project(":Common").sourceSets.main.allJava)
}
tasks.named("javadoc", Javadoc) {
source(project(":Common").sourceSets.main.allJava)
}
tasks.named("sourcesJar", Jar) {
from(project(":Common").sourceSets.main.allSource)
}
processResources {
from project(":Common").sourceSets.main.resources
}