From d1f85d61d49a69707d2f0869d18f4ae9177acd4e Mon Sep 17 00:00:00 2001 From: mike-r129 Date: Thu, 18 Jun 2026 00:53:03 -0600 Subject: [PATCH] Fix custom-path object import not reading the header --- fast64_internal/z64/utility.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/fast64_internal/z64/utility.py b/fast64_internal/z64/utility.py index 76159807b..4ea8b168c 100644 --- a/fast64_internal/z64/utility.py +++ b/fast64_internal/z64/utility.py @@ -493,7 +493,9 @@ def ootGetObjectPath(isCustomExport: bool, exportPath: str, folderName: str, inc def ootGetObjectHeaderPath(isCustomExport: bool, exportPath: str, folderName: str, include_extracted: bool) -> str: extracted = bpy.context.scene.fast64.oot.get_extracted_path() if include_extracted else "." if isCustomExport: - filepath = exportPath + # The custom .c references _WIDTH/_HEIGHT defines from its sibling .h, read that too. + root, ext = os.path.splitext(exportPath) + filepath = root + ".h" if ext == ".c" else exportPath else: filepath = os.path.join( ootGetPath(exportPath, isCustomExport, f"{extracted}/assets/objects/", folderName, False, False),