load all model folders except item

This commit is contained in:
Lukas Rieger (Blue) 2023-01-14 00:15:30 +01:00
parent 45331b8103
commit d9b6c526f8
No known key found for this signature in database
GPG Key ID: 2D09EC5ED2687FF2

View File

@ -36,7 +36,6 @@
import java.util.Set;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.CompletionException;
import java.util.regex.Pattern;
import java.util.stream.Stream;
@DebugDump
@ -238,7 +237,7 @@ private void loadResources(Path root) throws IOException {
list(root.resolve("assets"))
.map(path -> path.resolve("models"))
.flatMap(ResourcePack::list)
.filter(path -> Pattern.matches("blocks?", path.getFileName().toString()))
.filter(path -> !path.getFileName().toString().equals("item"))
.filter(Files::isDirectory)
.flatMap(ResourcePack::walk)
.filter(path -> path.getFileName().toString().endsWith(".json"))