-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
112 lines (90 loc) · 2.94 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
107
108
109
110
111
112
buildscript {
ext.kotlin_version = '1.4.21'
repositories {
jcenter()
maven {
name = "forge"
url = "https://files.minecraftforge.net/maven"
}
}
dependencies {
classpath group: "net.minecraftforge.gradle", name: "ForgeGradle", version: "4.+", changing: true
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
apply plugin: "net.minecraftforge.gradle"
apply plugin: 'kotlin'
version = modVersion
group = modGroup
archivesBaseName = modBaseName
compileJava {
options.compilerArgs << '-parameters'
}
compileKotlin {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
kotlinOptions {
jvmTarget = "1.8"
javaParameters = true
}
}
configurations {
embed
compile.extendsFrom(embed)
}
minecraft {
// the mappings can be changed at any time, and must be in the following format.
// snapshot_YYYYMMDD snapshot are built nightly.
// stable_# stables are built at the discretion of the MCP team.
// Use non-default mappings at your own risk. they may not always work.
// simply re-run your setup task after changing the mappings to update your workspace.
mappings channel: 'snapshot', version: '20201028-1.16.3'
// makeObfSourceJar = false // an Srg named sources jar is made by default. uncomment this to disable.
runs {
server {
workingDirectory project.file('run')
// Recommended logging data for a userdev environment
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'
// Recommended logging level for the console
property 'forge.logging.console.level', 'debug'
mods {
autocrat {
source sourceSets.main
}
}
}
data {
workingDirectory project.file('run')
// Recommended logging data for a userdev environment
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'
// Recommended logging level for the console
property 'forge.logging.console.level', 'debug'
args '--mod', 'autocrat', '--all', '--output', file('src/generated/resources/')
mods {
autocrat {
source sourceSets.main
}
}
}
}
}
repositories {
mavenCentral()
jcenter()
maven {
name = 'kotlinforforge'
url = 'https://thedarkcolour.github.io/KotlinForForge/'
}
maven {
name "obw's maven"
url "https://maven.offbeatwit.ch/repository/releases/"
}
}
dependencies {
minecraft "net.minecraftforge:forge:1.16.5-36.0.42"
implementation "thedarkcolour:kotlinforforge:1.7.0"
embed "io.github.hedgehog1029:frame:1.4.2"
}
jar {
from configurations.embed.collect { it.isDirectory() ? it : zipTree(it) }
}