[Bukkit] Add 1.20.1 support to adapter

This commit is contained in:
Maddy Miller 2023-06-13 00:25:28 +10:00
parent c5188212b5
commit 1f22906aca

View File

@ -180,8 +180,8 @@ public PaperweightAdapter() throws NoSuchFieldException, NoSuchMethodException {
CraftServer.class.cast(Bukkit.getServer());
int dataVersion = CraftMagicNumbers.INSTANCE.getDataVersion();
if (dataVersion != 3463) {
throw new UnsupportedClassVersionError("Not 1.20!");
if (dataVersion != 3463 && dataVersion != 3465) {
throw new UnsupportedClassVersionError("Not 1.20(.1)!");
}
serverWorldsField = CraftServer.class.getDeclaredField("worlds");