Skip to content

Commit a2c8796

Browse files
committed
Merge remote-tracking branch 'upstream/26.1' into 26.1
2 parents 3c40192 + ed48417 commit a2c8796

File tree

222 files changed

+1920
-1786
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

222 files changed

+1920
-1786
lines changed

.github/workflows/dependency_graph.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ jobs:
2424
- name: Checkout repository
2525
uses: actions/checkout@v6
2626

27-
- name: Set up Java 21
27+
- name: Set up Java 25
2828
uses: actions/setup-java@v5
2929
with:
30-
java-version: "21"
30+
java-version: "25"
3131
distribution: "microsoft"
3232

3333
- name: Grant execute permission for gradlew

.github/workflows/gradle.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,10 @@ jobs:
3838
- name: Checkout repository
3939
uses: actions/checkout@v6
4040

41-
- name: Set up Java 21
41+
- name: Set up Java 25
4242
uses: actions/setup-java@v5
4343
with:
44-
java-version: "21"
44+
java-version: "25"
4545
distribution: "microsoft"
4646

4747
- name: Grant execute permission for gradlew

.github/workflows/publish.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,10 @@ jobs:
4444
# Include all tags in case the new tag already exists.
4545
fetch-tags: true
4646

47-
- name: Set up Java 21
47+
- name: Set up Java 25
4848
uses: actions/setup-java@v5
4949
with:
50-
java-version: "21"
50+
java-version: "25"
5151
distribution: "microsoft"
5252

5353
- name: Grant execute permission for gradlew

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Wurst Client v7.53 (MC1.21.11) - Modified by CevAPI
1+
# Wurst Client v7.53 (MC26.1) - Modified by CevAPI
22

33
![CevAPI Logo](https://i.imgur.com/kBIn9Ab.png)
44

@@ -12,7 +12,9 @@
1212
- [1.21.1 - Not Updated](https://github.com/cev-api/Wurst7-CevAPI/tree/1.21.1)
1313
- [1.21.8 - Not Updated](https://github.com/cev-api/Wurst7-CevAPI/tree/1.21.8)
1414
- [1.21.10 - Not Updated](https://github.com/cev-api/Wurst7-CevAPI/tree/1.21.10)
15-
- [1.21.11 - Latest/Recommended (Based on 1.21.10)](https://github.com/cev-api/Wurst7-CevAPI/tree/master)
15+
- [1.21.11 - Recommended](https://github.com/cev-api/Wurst7-CevAPI/tree/1.21.11)
16+
- [26.1 - Latest](https://github.com/cev-api/Wurst7-CevAPI/tree/master)
17+
1618

1719
### Download
1820
Pre-compiled copies are available on the [Release Page](https://github.com/cev-api/Wurst7-CevAPI/releases).

build.gradle

Lines changed: 16 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ buildscript {
55
}
66

77
plugins {
8-
id "fabric-loom" version "${loom_version}"
9-
id "com.diffplug.spotless" version "8.4.0"
8+
id "net.fabricmc.fabric-loom" version "${loom_version}"
9+
id "com.diffplug.spotless" version "8.3.0"
1010
}
1111

1212
def ENV = System.getenv()
@@ -64,23 +64,20 @@ repositories {
6464
dependencies {
6565
// To change the versions see the gradle.properties file
6666
minecraft "com.mojang:minecraft:${project.minecraft_version}"
67-
mappings loom.officialMojangMappings()
68-
modImplementation "net.fabricmc:fabric-loader:${project.loader_version}"
69-
// Use Fabric Loader JUnit only for gametests, not for plain unit tests
70-
// Standard JUnit for unit tests
71-
testImplementation "org.junit.jupiter:junit-jupiter:5.10.2"
72-
testRuntimeOnly "org.junit.platform:junit-platform-launcher:1.10.2"
67+
implementation "net.fabricmc:fabric-loader:${project.loader_version}"
68+
testImplementation "org.junit.jupiter:junit-jupiter:5.13.4"
69+
testRuntimeOnly "org.junit.platform:junit-platform-launcher:1.13.4"
7370

7471
// Fabric API. This is technically optional, but you probably want it anyway.
75-
modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_api_version}"
72+
implementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_api_version}"
7673

7774
// net.wurstclient.ai.PathPos extends net.minecraft.util.math.BlockPos,
7875
// which uses javax.annotation.concurrent.Immutable, which is part of
7976
// the JSR305 library.
8077
//
8178
// In other words, Wurst won't compile without this library,
8279
// even though it's Minecraft that actually uses it.
83-
modImplementation "com.google.code.findbugs:jsr305:3.0.2"
80+
implementation "com.google.code.findbugs:jsr305:3.0.2"
8481
}
8582

8683
fabricApi.configureTests {
@@ -232,9 +229,8 @@ tasks.configureEach {
232229
}
233230

234231
tasks.withType(JavaCompile).configureEach {
235-
// Minecraft 1.20.5 (24w14a) upwards uses Java 21.
236-
it.options.release = 21
237-
it.options.compilerArgs += "-Xlint:deprecation"
232+
// Minecraft 26.1 (26.1-snapshot-1) upwards uses Java 25.
233+
it.options.release = 25
238234
}
239235

240236
java {
@@ -243,8 +239,8 @@ java {
243239
// If you remove this line, sources will not be generated.
244240
withSourcesJar()
245241

246-
sourceCompatibility = JavaVersion.VERSION_21
247-
targetCompatibility = JavaVersion.VERSION_21
242+
sourceCompatibility = JavaVersion.VERSION_25
243+
targetCompatibility = JavaVersion.VERSION_25
248244
}
249245

250246
jar {
@@ -259,8 +255,9 @@ jar {
259255
exclude("intentionally_untranslated.json")
260256
}
261257

262-
tasks.named("remapJar") {
263-
archiveVersion = "${project.version}_v${forkReleaseVersion}"
258+
tasks.configureEach {
259+
if(name == "remapJar")
260+
archiveVersion = "${project.version}_v${forkReleaseVersion}"
264261
}
265262

266263
import com.diffplug.spotless.generic.LicenseHeaderStep
@@ -287,9 +284,6 @@ spotless {
287284

288285
test {
289286
useJUnitPlatform()
290-
// Ensure Fabric Loader JUnit can see the test classes as a classpath group
291-
// to avoid "hasn't been exposed to the game" errors in-dev.
292-
systemProperty "fabric.classPathGroups", "default,test"
293287
}
294288

295289
def getGhVersion() {
@@ -341,8 +335,8 @@ task github(dependsOn: build) {
341335
ghRelease = releaseBuilder.create()
342336
}
343337

344-
ghRelease.uploadAsset(remapJar.archiveFile.get().getAsFile(), "application/java-archive")
345-
ghRelease.uploadAsset(remapSourcesJar.archiveFile.get().getAsFile(), "application/java-archive")
338+
ghRelease.uploadAsset(jar.archiveFile.get().getAsFile(), "application/java-archive")
339+
ghRelease.uploadAsset(sourcesJar.archiveFile.get().getAsFile(), "application/java-archive")
346340
}
347341
}
348342

gradle.properties

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,15 @@ org.gradle.configuration-cache=true
66
# Fabric Properties
77
# check these at https://fabricmc.net/develop/ and
88
# https://modrinth.com/mod/fabric-api/versions
9-
minecraft_version=1.21.11
10-
yarn_mappings=1.21.11+build.3
9+
minecraft_version=26.1
1110
loader_version=0.18.4
12-
loom_version=1.14-SNAPSHOT
11+
loom_version=1.15-SNAPSHOT
1312

1413
# Fabric API
15-
fabric_api_version=0.140.2+1.21.11
14+
fabric_api_version=0.144.0+26.1
1615

1716
# Mod Properties
18-
mod_version=v7.53-CevAPI-MC1.21.11
17+
mod_version=v7.53-CevAPI-MC26.1
1918
fork_release_version=0.48
2019
maven_group=net.wurstclient
2120
archives_base_name=Wurst-Client
@@ -25,6 +24,6 @@ mod_loader=Fabric
2524
gh_repo_id=cev-api/Wurst7-CevAPI
2625

2726
# Dependencies
28-
# check at https://modrinth.com/mod/sodium/versions?l=fabric&g=1.21.11
27+
# check at https://modrinth.com/mod/sodium/versions?l=fabric&g=26.1
2928
sodium_version=mc1.21.11-0.8.6-fabric
30-
do_mod_compat_test=true
29+
do_mod_compat_test=false

src/gametest/java/net/wurstclient/gametest/SingleplayerTest.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
import net.fabricmc.fabric.api.client.gametest.v1.TestInput;
1616
import net.fabricmc.fabric.api.client.gametest.v1.context.ClientGameTestContext;
17-
import net.fabricmc.fabric.api.client.gametest.v1.context.TestClientWorldContext;
17+
import net.fabricmc.fabric.api.client.gametest.v1.context.TestClientLevelContext;
1818
import net.fabricmc.fabric.api.client.gametest.v1.context.TestServerContext;
1919
import net.fabricmc.fabric.api.client.gametest.v1.context.TestSingleplayerContext;
2020
import net.minecraft.world.item.Item;
@@ -26,7 +26,7 @@ public abstract class SingleplayerTest
2626
protected final ClientGameTestContext context;
2727
protected final TestSingleplayerContext spContext;
2828
protected final TestInput input;
29-
protected final TestClientWorldContext world;
29+
protected final TestClientLevelContext world;
3030
protected final TestServerContext server;
3131
protected final Logger logger = WurstTest.LOGGER;
3232

@@ -36,7 +36,7 @@ public SingleplayerTest(ClientGameTestContext context,
3636
this.context = context;
3737
this.spContext = spContext;
3838
this.input = context.getInput();
39-
this.world = spContext.getClientWorld();
39+
this.world = spContext.getClientLevel();
4040
this.server = spContext.getServer();
4141
}
4242

@@ -48,7 +48,7 @@ public final void run()
4848
runImpl();
4949
assertScreenshotEquals(
5050
getClass().getSimpleName().toLowerCase() + "_cleanup",
51-
"https://i.imgur.com/i2Nr9is.png");
51+
"https://i.imgur.com/XF1SILt.png");
5252
}
5353

5454
/**
@@ -117,10 +117,10 @@ protected final void assertOneItemInSlot(int slot, Item item)
117117
ItemStack stack = context
118118
.computeOnClient(mc -> mc.player.getInventory().getItem(slot));
119119
if(!stack.is(item) || stack.getCount() != 1)
120-
throw new RuntimeException(
121-
"Expected 1 " + item.getName().getString() + " at slot " + slot
122-
+ ", found " + stack.getCount() + " "
123-
+ stack.getItem().getName().getString() + " instead");
120+
throw new RuntimeException("Expected 1 "
121+
+ item.getName(item.getDefaultInstance()).getString()
122+
+ " at slot " + slot + ", found " + stack.getCount() + " "
123+
+ stack.getItemName().getString() + " instead");
124124
}
125125

126126
protected final void assertScreenshotEquals(String fileName,
@@ -154,6 +154,6 @@ protected final void assertNoItemInSlot(int slot)
154154
if(!stack.isEmpty())
155155
throw new RuntimeException("Expected no item in slot " + slot
156156
+ ", found " + stack.getCount() + " "
157-
+ stack.getItem().getName().getString() + " instead");
157+
+ stack.getItemName().getString() + " instead");
158158
}
159159
}

src/gametest/java/net/wurstclient/gametest/WurstClientTestHelper.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,5 +280,4 @@ public static String tryUploadToImgur(Path imagePath)
280280
return null;
281281
}
282282
}
283-
284283
}

src/gametest/java/net/wurstclient/gametest/WurstTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
import net.fabricmc.fabric.api.client.gametest.v1.FabricClientGameTest;
2020
import net.fabricmc.fabric.api.client.gametest.v1.TestInput;
2121
import net.fabricmc.fabric.api.client.gametest.v1.context.ClientGameTestContext;
22-
import net.fabricmc.fabric.api.client.gametest.v1.context.TestClientWorldContext;
22+
import net.fabricmc.fabric.api.client.gametest.v1.context.TestClientLevelContext;
2323
import net.fabricmc.fabric.api.client.gametest.v1.context.TestServerContext;
2424
import net.fabricmc.fabric.api.client.gametest.v1.context.TestSingleplayerContext;
2525
import net.fabricmc.fabric.api.client.gametest.v1.world.TestWorldBuilder;
@@ -80,7 +80,7 @@ private void testInWorld(ClientGameTestContext context,
8080
TestSingleplayerContext spContext)
8181
{
8282
TestInput input = context.getInput();
83-
TestClientWorldContext world = spContext.getClientWorld();
83+
TestClientLevelContext world = spContext.getClientLevel();
8484
TestServerContext server = spContext.getServer();
8585

8686
// Disable chunk fade

src/gametest/java/net/wurstclient/gametest/mixin/ScreenMixin.java

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,13 @@
77
*/
88
package net.wurstclient.gametest.mixin;
99

10-
import net.minecraft.client.gui.GuiGraphics;
10+
import org.spongepowered.asm.mixin.Mixin;
11+
import org.spongepowered.asm.mixin.Shadow;
12+
import org.spongepowered.asm.mixin.injection.At;
13+
import org.spongepowered.asm.mixin.injection.Inject;
14+
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
15+
16+
import net.minecraft.client.gui.GuiGraphicsExtractor;
1117
import net.minecraft.client.gui.components.Renderable;
1218
import net.minecraft.client.gui.components.events.AbstractContainerEventHandler;
1319
import net.minecraft.client.gui.screens.Screen;
@@ -31,9 +37,9 @@ public abstract class ScreenMixin extends AbstractContainerEventHandler
3137
* Replaces the panorama background with a gray background to make test
3238
* screenshots consistent.
3339
*/
34-
@Inject(method = "renderPanorama", at = @At("HEAD"), cancellable = true)
35-
public void renderPanoramaBackground(GuiGraphics context, float deltaTicks,
36-
CallbackInfo ci)
40+
@Inject(method = "extractPanorama", at = @At("HEAD"), cancellable = true)
41+
public void renderPanoramaBackground(GuiGraphicsExtractor context,
42+
float deltaTicks, CallbackInfo ci)
3743
{
3844
context.fill(0, 0, width, height, CommonColors.GRAY);
3945
ci.cancel();

0 commit comments

Comments
 (0)