一键导入
match-data-file
Match data file describes how to add dat asegments to a C file. Use the match data file skill when you need to match a data file.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Match data file describes how to add dat asegments to a C file. Use the match data file skill when you need to match a data file.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | match-data-file |
| description | Match data file describes how to add dat asegments to a C file. Use the match data file skill when you need to match a data file. |
Code, data, rodata and bss are all defined as separate segments in snowboardkids.yaml. The first step of matching a new data segment is to update the appropriate data segment entry to mark is as defined in the existing C file (code segment).
For example if you are asked to match the data segment for code segment 0x8A40:
- [0x88D30, data, 8A40]
Should be changed to:
- [0x88D30, .data, 8A40]
Rebuild the project by running:
./tools/build-and-verify.sh
The build will now fail because we have not yet added the expected data. But these error messages can be instructive for telling us what data is needed, etc.
Examine the assembly code for the data segment, this is located in asm/data/. So our above example would be located in asm/data/8A40.data.s. Remember that the N64 rom is big endian.
Take the labeled data from the data file and add the appropriate variable definitions to the C file (`src/8A40.c in our example).
Note that the C file will have missing data definitions already but they will be externs. You should add the variable definitions in the order in which they appear in the data file (do not follow the ordering of the externs).
Rebuild the project by running:
./tools/build-and-verify.sh
You will likely encounter build errors or checksum failures. Work through the errors and resolve any checksum mismatches.
Use this skill if you need to decompile a function that uses F3DEX. The presence of the Gfx type or gRegionAllocPtr are strongly indicative of an F3DEX or S2DEX microcode function.
Decomp-Permuter is a tool that automatically permutes C files to better match a target binary. Use this skill when you are decompiling a function and it is almost matching except for some register differences (i.e. 95%+). Or if you are otherwise unable to make progress on a function decompilation. Do not use it when there are control flow or functional differences; it's often easy to resolve those by hand, and neither the scorer nor the randomizer tends to play well with them.
Match a given segment to a libultra ROM segment. Use this when converting unidentified asm libultra ranges such as osRecvMesg to matching C source.
Adding a new asset to snowboardkids.yaml requires following specific steps to ensure assets are in the correct order and properly declared. Use this skill when you need to add a new binary asset.
Convert arrays with hardcoded pointer addresses to use ROM_START/ROM_END symbols. This automates the process of adding USE_ASSET declarations, updating array initialization, and configuring YAML segments.
Renaming a C file or associated header (.h) file requires additional steps in decompilation projects or the build will fail. Use this skill when you want to rename a C file and/or a header file.