Skip to content

Commit

Permalink
headers: account for all remainders
Browse files Browse the repository at this point in the history
  • Loading branch information
bwrsandman committed Sep 22, 2024
1 parent 8f092bf commit d70bf45
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions scripts/headers/bw1_decomp_gen/generate_headers.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ def is_globals_helper_struct(name: str) -> bool:
"SetRenderModeData",
"ModAddedGlobals_t",
"globals_Script",
"SetRenderModeData__callback"
]


Expand Down Expand Up @@ -132,7 +133,7 @@ def is_ignore_struct(data_type) -> bool:
remainder_primitives,
remainder,
) = partition([
lambda x: type(x) is Struct and is_globals_helper_struct(x.name),
lambda x: is_globals_helper_struct(x.name),
lambda x: type(x) is Struct and (x.name.endswith('Vftable') or x.name.startswith('vt_')),
lambda x: type(x) is Union and x.name.endswith('Base'),
lambda x: type(x) is FuncPtr and ('Vftable__' in x.name or x.name.startswith('vt_')),
Expand Down Expand Up @@ -239,9 +240,6 @@ def get_path(name):

# TODO: create header for globals_t with actual addresses and remove from ignored count
to_ignore += globals_t
# TODO: get to 0 orphan functions
# TODO: get to 0 orphan structs
# TODO: get to 0 orphan entries

output_path = Path("generated_headers_output")
if output_path.exists():
Expand Down

0 comments on commit d70bf45

Please sign in to comment.