8000 Add `non-native-dumper.py` option to include the parent name in the struct entry. by Synthlight · Pull Request #1023 · praydog/REFramework · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add non-native-dumper.py option to include the parent name in the struct entry. #1023

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion reversing/rsz/non-native-dumper.py
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@ def generate_field_entries(il2cpp_dump, natives, key, il2cpp_entry, use_typedefs
return fields_out, struct_str, i, struct_i


def main(out_postfix="", il2cpp_path="", natives_path=None, use_typedefs=False, use_hashkeys=False):
def main(out_postfix="", il2cpp_path="", natives_path=None, use_typedefs=False, use_hashkeys=False, include_parents=False):
if il2cpp_path is None:
return

Expand Down Expand Up @@ -462,6 +462,9 @@ def main(out_postfix="", il2cpp_path="", natives_path=None, use_typedefs=False,

json_entry["crc"] = entry["crc"]

if include_parents and "parent" in entry:
json_entry["parent"] = entry["parent"]

struct_str = "// " + entry["fqn"] + "\n"
struct_str = struct_str + "struct " + key + " {\n"

Expand Down
2 changes: 2 additions & 0 deletions reversing/rsz/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ Uses [Unicorn](https://github.com/unicorn-engine/unicorn) to emulate all of the
* path to `native_layouts_(exe_name).json` that was generated by `emulation-dumper.py`
* `use_typedefs`
* `use_hashkeys`
* `include_parents`
* Will add the parent object name to the struct or omitted if not found.

### Outputs
`rsz(out_postfix).json`
0