-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
69 lines (56 loc) · 1.56 KB
/
build.gradle
File metadata and controls
69 lines (56 loc) · 1.56 KB
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
plugins {
id 'java-library'
id 'maven-publish'
id 'net.neoforged.moddev' version '2.0.141'
id 'idea'
}
version = mod_version
group = mod_group_id
sourceSets.main.resources {
// Include resources generated by data generators
srcDir('src/generated/resources')
// Exclude common development-only resources
exclude("**/*.bbmodel")
}
base {
archivesName = mod_id
}
// Minecraft 1.21.1 uses Java 21
java.toolchain.languageVersion = JavaLanguageVersion.of(21)
neoForge {
// Specify the version of NeoForge to use.
version = project.neo_version
// Mappings setup (Parchment maps parameter names and javadocs cleanly)
parchment {
mappingsVersion = project.parchment_mappings_version
minecraftVersion = project.parchment_minecraft_version
}
// Default run configurations.
runs {
client {
client()
systemProperty 'neoforge.enabledGameTestNamespaces', project.mod_id
}
server {
server()
programArgument '--nogui'
systemProperty 'neoforge.enabledGameTestNamespaces', project.mod_id
}
}
// Register our mod so it gets compiled and packed
mods {
keybind_fix {
sourceSet sourceSets.main
}
}
}
repositories {
mavenCentral()
}
dependencies {
// Standard NeoForge environment is automatically set up by ModDevGradle.
// Additional mod or library dependencies can be added here if needed.
}
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
}