From 2b3923880a937648ec25e9c2ae8fe4ce86250c60 Mon Sep 17 00:00:00 2001 From: clayjohn Date: Mon, 5 May 2025 00:19:32 -0700 Subject: [PATCH] Continue checking for a texture decompression path even if end of import file is not reached --- core/io/resource_importer.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/io/resource_importer.cpp b/core/io/resource_importer.cpp index 51cdbb7ae47..a13c76a0ed8 100644 --- a/core/io/resource_importer.cpp +++ b/core/io/resource_importer.cpp @@ -121,6 +121,12 @@ Error ResourceFormatImporter::_get_path_and_type(const String &p_path, PathAndTy } } + if (p_load && !path_found && decomp_path_found) { + print_verbose(vformat("No natively supported texture format found for %s, using decompressable format %s.", p_path, decomp_path)); + r_path_and_type.path = decomp_path; + return OK; + } + #ifdef TOOLS_ENABLED if (r_path_and_type.metadata && !r_path_and_type.path.is_empty()) { Dictionary meta = r_path_and_type.metadata;