From c3278b495ebace05c45ef8056848a5f6690afc9b Mon Sep 17 00:00:00 2001 From: isXander Date: Wed, 24 Apr 2024 23:06:15 +0100 Subject: Fix conflict with crowdin translate --- build.gradle.kts | 2 +- changelog.md | 34 ++-------------------- .../yacl3/gui/image/YACLImageReloadListener.java | 5 ++-- 3 files changed, 6 insertions(+), 35 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index e9271ec..eeab5cb 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -22,7 +22,7 @@ val isForgeLike = isNeoforge || isForge val mcVersion = stonecutter.current.version group = "dev.isxander" -val versionWithoutMC = "3.4.0" +val versionWithoutMC = "3.4.1" version = "$versionWithoutMC+${stonecutter.current.project}" val snapshotVer = "${grgit.branch.current().name.replace('/', '.')}-SNAPSHOT" diff --git a/changelog.md b/changelog.md index eabe152..7903862 100644 --- a/changelog.md +++ b/changelog.md @@ -1,4 +1,4 @@ -# YetAnotherConfigLib 3.4.0 +# YetAnotherConfigLib 3.4.1 This build supports the following versions: - Fabric 1.20.1 @@ -7,37 +7,7 @@ This build supports the following versions: - Forge 1.20.1 - NeoForge 1.20.4 -## For developers... - -This is the first build which uses a new build toolchain to support multiple minecraft versions in the same codebase. -With this change, the artifact of the mod has changed. - -```groovy -modImplementation "dev.isxander:yet-another-config-lib:{modversion}+{mcversion}-{loader}" -// for example... -modImplementation "dev.isxander:yet-another-config-lib:3.4.0+1.20.1-fabric" -``` - -If you are using YACL in an architectury project (one with a common subproject), you will from now on depend on -the fabric version of YACL. There is no longer any common artifact. I don't believe there to be any issues with doing it -like this. - -## Additions - -- New colour picker widget by [Superkat32](https://github.com/isXander/YetAnotherConfigLib/pull/140) - - This works with existing colour options. - -![Colour picker example](https://i.imgur.com/G6Yx6RU.png) - -- Added a custom tab API so categories can provide their own GUI, instead of YACL options. - - Mod developers can make their category class implement `CustomTabProvider`. Javadoc is available. -- Add a new Kotlin DSL for creating your YACL UIs. This is a wrapper on top of the java builder interface providing extra functionality for Kotlin users. - - YACL does not provide any kotlin libraries, nor does it depend on them. If you would like to use this DSL, make sure your own mod depends on your loader's Kotlin mod. - - This is included in the main artifact. You don't need additional dependencies. - - An example usage can be found [in the testmod](https://github.com/isXander/YetAnotherConfigLib/blob/multiversion/dev/src/testmod/kotlin/dev/isxander/yacl3/test/DslTest.kt) -- Improved the backend of dropdown controllers by [Crendgrim](https://github.com/isXander/YetAnotherConfigLib/pull/162) - ## Bug Fixes -- Fix GIFs not being preloaded in the resource reloader +- Fix conflict with Crowdin Translate diff --git a/src/main/java/dev/isxander/yacl3/gui/image/YACLImageReloadListener.java b/src/main/java/dev/isxander/yacl3/gui/image/YACLImageReloadListener.java index 1852d98..243f22f 100644 --- a/src/main/java/dev/isxander/yacl3/gui/image/YACLImageReloadListener.java +++ b/src/main/java/dev/isxander/yacl3/gui/image/YACLImageReloadListener.java @@ -10,6 +10,7 @@ import net.minecraft.server.packs.resources.PreparableReloadListener; import net.minecraft.server.packs.resources.Resource; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.util.profiling.ProfilerFiller; +import org.jetbrains.annotations.NotNull; import java.util.ArrayList; import java.util.List; @@ -25,7 +26,7 @@ public class YACLImageReloadListener /*?}*/ { @Override - public CompletableFuture reload( + public @NotNull CompletableFuture reload( PreparationBarrier preparationBarrier, ResourceManager resourceManager, ProfilerFiller preparationsProfiler, @@ -34,7 +35,7 @@ public class YACLImageReloadListener Executor gameExecutor ) { Map imageResources = resourceManager.listResources( - "", + "textures", location -> ImageRendererManager.PRELOADED_IMAGE_FACTORIES .stream() .anyMatch(factory -> factory.predicate().test(location)) -- cgit