Skip to content

Commit 4b6652b

Browse files
committed
1.20.4
1 parent 21feeb6 commit 4b6652b

File tree

18 files changed

+251
-22
lines changed

18 files changed

+251
-22
lines changed

build.gradle

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,9 @@ allprojects {
7777
// The following line declares the yarn mappings you may select this one as well.
7878
// mappings "net.fabricmc:yarn:1.17.1+build.32:v2"
7979
//launchImplementation('dev.babbaj:nether-pathfinder:1.3.0')
80-
implementation 'dev.babbaj:nether-pathfinder:1.4.1'
80+
implementation "dev.babbaj:nether-pathfinder:${nether_pathfinder_version}"
81+
82+
implementation 'com.google.code.findbugs:jsr305:3.0.2'
8183
}
8284

8385
unimined.minecraft(sourceSets.main, true) {
@@ -86,7 +88,7 @@ allprojects {
8688
mappings {
8789
intermediary()
8890
mojmap()
89-
parchment("2023.10.22")
91+
parchment("1.20.2", "2023.10.22")
9092
}
9193
}
9294

buildSrc/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,5 +40,5 @@ dependencies {
4040
implementation group: 'com.google.code.gson', name: 'gson', version: '2.9.0'
4141
implementation group: 'commons-io', name: 'commons-io', version: '2.7'
4242

43-
implementation group: 'xyz.wagyourtail.unimined', name: 'xyz.wagyourtail.unimined.gradle.plugin', version: '1.0.5'
43+
implementation group: 'xyz.wagyourtail.unimined', name: 'xyz.wagyourtail.unimined.gradle.plugin', version: '1.1.0'
4444
}

fabric/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ dependencies {
4545
common sourceSet.output
4646
shadowCommon sourceSet.output
4747
}
48-
include 'dev.babbaj:nether-pathfinder:1.3.0'
48+
include "dev.babbaj:nether-pathfinder:${nether_pathfinder_version}"
4949
}
5050

5151
processResources {

fabric/src/main/resources/fabric.mod.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
{
32
"schemaVersion": 1,
43
"id": "baritone",
@@ -26,6 +25,6 @@
2625

2726
"depends": {
2827
"fabricloader": ">=0.14.22",
29-
"minecraft": "1.20.2"
28+
"minecraft": "1.20.4"
3029
}
3130
}

forge/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ dependencies {
5656
common sourceSet.output
5757
shadowCommon sourceSet.output
5858
}
59-
shadowCommon 'dev.babbaj:nether-pathfinder:1.3.0'
59+
shadowCommon "dev.babbaj:nether-pathfinder:${nether_pathfinder_version}"
6060
}
6161

6262
processResources {

forge/src/main/resources/META-INF/mods.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,6 @@ A Minecraft pathfinder bot.
3535
modId="minecraft"
3636
mandatory=true
3737
# This version range declares a minimum of the current minecraft version up to but not including the next major version
38-
versionRange="[1.20.2]"
38+
versionRange="[1.20.4]"
3939
ordering="NONE"
4040
side="BOTH"

gradle.properties

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
11
org.gradle.jvmargs=-Xmx4G
22

3-
available_loaders=fabric,forge,tweaker
3+
available_loaders=fabric,forge,neoforge,tweaker
44

55
mod_version=1.10.2
66
maven_group=baritone
77
archives_base_name=baritone
88

9-
minecraft_version=1.20.2
10-
forge_version=48.0.1
9+
minecraft_version=1.20.4
10+
11+
forge_version=49.0.3
12+
neoforge_version=0-beta
13+
1114
fabric_version=0.14.22
15+
16+
nether_pathfinder_version=1.4.1

neoforge/build.gradle

Lines changed: 134 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,134 @@
1+
/*
2+
* This file is part of Baritone.
3+
*
4+
* Baritone is free software: you can redistribute it and/or modify
5+
* it under the terms of the GNU Lesser General Public License as published by
6+
* the Free Software Foundation, either version 3 of the License, or
7+
* (at your option) any later version.
8+
*
9+
* Baritone is distributed in the hope that it will be useful,
10+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
* GNU Lesser General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU Lesser General Public License
15+
* along with Baritone. If not, see <https://www.gnu.org/licenses/>.
16+
*/
17+
18+
import baritone.gradle.task.CreateDistTask
19+
import baritone.gradle.task.ProguardTask
20+
21+
plugins {
22+
id "com.github.johnrengelman.shadow" version "8.0.0"
23+
}
24+
25+
archivesBaseName = archivesBaseName + "-neoforge"
26+
27+
unimined.minecraft {
28+
mappings {
29+
devFallbackNamespace "intermediary"
30+
}
31+
32+
neoForged {
33+
loader project.neoforge_version
34+
mixinConfig ["mixins.baritone.json"]
35+
}
36+
37+
minecraftRemapper.config {
38+
// neoforge adds 1 conflict, where 2 interfaces have a method with the same name on yarn/mojmap,
39+
// but the method has different names in the intermediary mappings.
40+
// this is a conflict because they have a class that extends both interfaces.
41+
// this shouldn't be a problem as long as named mappings don't make the name of those 2 methods different.
42+
ignoreConflicts(true)
43+
}
44+
45+
}
46+
47+
//loom {
48+
// forge {
49+
// mixinConfig 'mixins.baritone.json'
50+
// }
51+
//}
52+
53+
configurations {
54+
common
55+
shadowCommon // Don't use shadow from the shadow plugin because we don't want IDEA to index this.
56+
compileClasspath.extendsFrom common
57+
runtimeClasspath.extendsFrom common
58+
}
59+
60+
dependencies {
61+
// because of multiple sourcesets `common project(":")` doesn't work
62+
for (sourceSet in rootProject.sourceSets) {
63+
if (sourceSet == rootProject.sourceSets.test) continue
64+
if (sourceSet == rootProject.sourceSets.schematica_api) continue
65+
common sourceSet.output
66+
shadowCommon sourceSet.output
67+
}
68+
shadowCommon "dev.babbaj:nether-pathfinder:${nether_pathfinder_version}"
69+
}
70+
71+
processResources {
72+
inputs.property "version", project.version
73+
74+
filesMatching("META-INF/mods.toml") {
75+
expand "version": project.version
76+
}
77+
}
78+
79+
shadowJar {
80+
configurations = [project.configurations.shadowCommon]
81+
archiveClassifier.set "dev-shadow"
82+
}
83+
84+
remapJar {
85+
inputFile.set shadowJar.archiveFile
86+
dependsOn shadowJar
87+
archiveClassifier.set null
88+
}
89+
90+
jar {
91+
archiveClassifier.set "dev"
92+
93+
manifest {
94+
attributes(
95+
'MixinConfigs': 'mixins.baritone.json',
96+
"MixinConnector": "baritone.launch.BaritoneMixinConnector",
97+
98+
'Implementation-Title': 'Baritone',
99+
'Implementation-Version': version,
100+
)
101+
}
102+
}
103+
104+
components.java {
105+
withVariantsFromConfiguration(project.configurations.shadowRuntimeElements) {
106+
skip()
107+
}
108+
}
109+
110+
task proguard(type: ProguardTask) {
111+
url 'https://github.com/Guardsquare/proguard/releases/download/v7.2.1/proguard-7.2.1.zip'
112+
extract 'proguard-7.2.1/lib/proguard.jar'
113+
compType "neoforge"
114+
}
115+
116+
task createDist(type: CreateDistTask, dependsOn: proguard) {
117+
compType "neoforge"
118+
}
119+
120+
build.finalizedBy(createDist)
121+
122+
publishing {
123+
publications {
124+
mavenFabric(MavenPublication) {
125+
artifactId = rootProject.archives_base_name + "-" + project.name
126+
from components.java
127+
}
128+
}
129+
130+
// See https://docs.gradle.org/current/userguide/publishing_maven.html for information on how to set up publishing.
131+
repositories {
132+
// Add repositories to publish to here.
133+
}
134+
}

neoforge/gradle.properties

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#
2+
# This file is part of Baritone.
3+
#
4+
# Baritone is free software: you can redistribute it and/or modify
5+
# it under the terms of the GNU Lesser General Public License as published by
6+
# the Free Software Foundation, either version 3 of the License, or
7+
# (at your option) any later version.
8+
#
9+
# Baritone is distributed in the hope that it will be useful,
10+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
# GNU Lesser General Public License for more details.
13+
#
14+
# You should have received a copy of the GNU Lesser General Public License
15+
# along with Baritone. If not, see <https://www.gnu.org/licenses/>.
16+
#
17+
18+
loom.platform=forge
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
/*
2+
* This file is part of Baritone.
3+
*
4+
* Baritone is free software: you can redistribute it and/or modify
5+
* it under the terms of the GNU Lesser General Public License as published by
6+
* the Free Software Foundation, either version 3 of the License, or
7+
* (at your option) any later version.
8+
*
9+
* Baritone is distributed in the hope that it will be useful,
10+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
* GNU Lesser General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU Lesser General Public License
15+
* along with Baritone. If not, see <https://www.gnu.org/licenses/>.
16+
*/
17+
18+
package baritone.launch;
19+
20+
import net.neoforged.fml.common.Mod;
21+
22+
@Mod("baritoe")
23+
public class BaritoneForgeModXD {
24+
}

0 commit comments

Comments
 (0)