Skip to content

Commit 2d53c9b

Browse files
Merge branch 'WiIIiam278:master' into master
2 parents 88e4fbc + af512d4 commit 2d53c9b

7 files changed

Lines changed: 21 additions & 8 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,4 +132,5 @@ jobs:
132132
1.21.7
133133
1.21.8
134134
1.21.9
135+
1.21.11
135136
java: 21

.github/workflows/release.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,4 +121,5 @@ jobs:
121121
1.21.7
122122
1.21.8
123123
1.21.9
124+
1.21.11
124125
java: 21

build.gradle

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,9 +171,10 @@ publishing {
171171
}
172172

173173
tasks {
174-
var papi = papi_proxy_bridge_minimum_version
175174
runVelocity {
176-
velocityVersion("${velocity_api_version}-SNAPSHOT")
175+
var snapshotSuffix = velocity_snapshot.toBoolean() ? "-SNAPSHOT" : ""
176+
println "Using Velocity API version: ${velocity_api_version}${snapshotSuffix}"
177+
velocityVersion("${velocity_api_version}" + snapshotSuffix)
177178

178179
downloadPlugins {
179180
// github ("WiIIiam278", "PAPIProxyBridge", "1.7.1", "PAPIProxyBridge-Velocity-1.7.1.jar")

gradle.properties

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@ javaVersion=21
33
org.gradle.jvmargs='-Dfile.encoding=UTF-8'
44
org.gradle.daemon=true
55

6-
plugin_version=1.7.9
6+
plugin_version=1.7.11
77
plugin_archive=velocitab
88
plugin_description=A beautiful and versatile TAB list plugin for Velocity proxies
99

10-
velocity_api_version=3.4.0
11-
velocity_minimum_build=539
10+
velocity_api_version=3.5.0
11+
velocity_snapshot=true
12+
velocity_minimum_build=584
1213
papi_proxy_bridge_minimum_version=1.8

src/main/java/net/william278/velocitab/config/Metadata.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ public void validateApiVersion(@NotNull Version version) {
5050

5151
public void validateBuild(@NotNull Version version) {
5252
int serverBuild = getBuildNumber(version.toString());
53-
if (serverBuild < velocityMinimumBuild) {
53+
if (serverBuild > 0 && serverBuild < velocityMinimumBuild) {
5454
throw new IllegalStateException("Your Velocity build version (#" + serverBuild + ") is not supported! " +
5555
"Disabling Velocitab. Please update to at least Velocity v" + velocityApiVersion
5656
+ " build #" + velocityMinimumBuild + " or newer.");
@@ -70,6 +70,12 @@ private int getBuildNumber(@NotNull String proxyVersion) {
7070
if (matcher.find(1)) {
7171
return Integer.parseInt(matcher.group(1));
7272
}
73+
74+
final Matcher simpleMatcher = Pattern.compile("^(\\d+)\\.(\\d+)\\.(\\d+)$").matcher(proxyVersion);
75+
if (simpleMatcher.matches()) {
76+
return 0;
77+
}
78+
7379
throw new IllegalArgumentException("No build number found for proxy version: " + proxyVersion);
7480
}
7581

src/main/java/net/william278/velocitab/packet/Protocol770Adapter.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,9 @@ public Protocol770Adapter(@NotNull Velocitab plugin) {
3939
ProtocolVersion.MINECRAFT_1_21_5,
4040
ProtocolVersion.MINECRAFT_1_21_6,
4141
ProtocolVersion.MINECRAFT_1_21_7,
42-
ProtocolVersion.MINECRAFT_1_21_9
42+
ProtocolVersion.MINECRAFT_1_21_9,
43+
ProtocolVersion.MINECRAFT_1_21_11,
44+
ProtocolVersion.MINECRAFT_26_1
4345
));
4446
}
4547

src/main/java/net/william278/velocitab/packet/ScoreboardManager.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,8 @@ public void registerPacket() {
424424
.mapping(0x60, MINECRAFT_1_20_5, false)
425425
.mapping(0x67, MINECRAFT_1_21_2, false)
426426
.mapping(0x66, MINECRAFT_1_21_5, false)
427-
.mapping(0x6B, MINECRAFT_1_21_9, false);
427+
.mapping(0x6B, MINECRAFT_1_21_9, false)
428+
.mapping(0x6D, MINECRAFT_26_1, false);
428429
packetRegistration.register();
429430
} catch (Throwable e) {
430431
plugin.log(Level.ERROR, "Failed to register UpdateTeamsPacket", e);

0 commit comments

Comments
 (0)