From 9c83adc3c1dfe75ab9dcbe1aa977a2d8af83f3e6 Mon Sep 17 00:00:00 2001 From: Thomas <1688389+Rakambda@users.noreply.github.com> Date: Tue, 22 Oct 2024 21:20:56 +0200 Subject: [PATCH] Add Fabric 1.21.2 support (#762) * Add Fabric 1.21.2 support * Update cloth --- datapack/pack.mcmeta | 2 +- .../fabric/common/FallingTreeCommonsImpl.java | 2 +- .../fabric/common/wrapper/PlayerWrapper.java | 2 +- gradle.properties | 4 ++-- gradle/libs.versions.toml | 12 ++++++------ 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/datapack/pack.mcmeta b/datapack/pack.mcmeta index a72b325e..81f5409f 100644 --- a/datapack/pack.mcmeta +++ b/datapack/pack.mcmeta @@ -1,6 +1,6 @@ { "pack" : { - "pack_format" : 48, + "pack_format" : 55, "description" : { "text" : "Add FallingTree enchantments" } diff --git a/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/FallingTreeCommonsImpl.java b/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/FallingTreeCommonsImpl.java index 7feb875e..f8a7cb61 100644 --- a/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/FallingTreeCommonsImpl.java +++ b/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/FallingTreeCommonsImpl.java @@ -203,7 +203,7 @@ private Optional getRegistryElement(Registry registryKey, ResourceLoca @NotNull private Stream getRegistryTagContent(@NotNull Registry registry, @NotNull TagKey tag){ - return registry.getTag(tag).stream() + return registry.get(tag).stream() .flatMap(a -> a.stream().map(Holder::value)); } diff --git a/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/wrapper/PlayerWrapper.java b/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/wrapper/PlayerWrapper.java index 37fb2566..c8c07db1 100644 --- a/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/wrapper/PlayerWrapper.java +++ b/fabric/src/main/java/fr/rakambda/fallingtree/fabric/common/wrapper/PlayerWrapper.java @@ -36,7 +36,7 @@ public void sendMessage(@NotNull IComponent component, @NotNull NotificationMode } } else{ - raw.sendSystemMessage(text); + raw.displayClientMessage(text, true); } } diff --git a/gradle.properties b/gradle.properties index b1068606..bcef7537 100644 --- a/gradle.properties +++ b/gradle.properties @@ -5,8 +5,8 @@ org.gradle.daemon=false modId=fallingtree modName=FallingTree includeFabric=true -includeForge=true -includeNeoForge=true +includeForge=false +includeNeoForge=false # Repository repoUser=Rakambda repoName=FallingTree diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 784a8695..a22da8e0 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -7,17 +7,17 @@ gson-version = "2.11.0" log4j2-version = "2.24.1" # Minecraft / Loaders -minecraftVersion = "1.21.1" -fabric-loader-version = "0.16.2" -fabric-api-version = "0.102.1+1.21.1" +minecraftVersion = "1.21.2" +fabric-loader-version = "0.16.7" +fabric-api-version = "0.106.1+1.21.2" forge-version = "1.21.1-52.0.4" neoforge-version = "21.1.22" # Mod dependencies -modmenu-version = "11.0.3" -clothConfigVersion = "15.0.130" +modmenu-version = "12.0.0-beta.1" +clothConfigVersion = "16.0.141" -fabric-loom-version = "1.7+" +fabric-loom-version = "1.8+" forge-plugin-version = "[6.0.24,6.2)" curse-version = "1.4.0" modrinth-version = "2.8.7"