mirror of
https://github.com/Xeeynamo/sotn-decomp.git
synced 2024-11-23 13:09:44 +00:00
29 lines
918 B
Python
29 lines
918 B
Python
#!/usr/bin/env python3
|
|
|
|
def add_custom_arguments(parser):
|
|
parser.add_argument(
|
|
"--overlay",
|
|
default="dra",
|
|
dest='overlay',
|
|
help="Defines which overlay to use for the diff (main, dra, st/mad, etc.)",
|
|
)
|
|
|
|
|
|
def apply(config, args):
|
|
overlay = args.overlay or 'dra'
|
|
isMapOverlay = overlay.startswith("st/")
|
|
name = overlay[3:] if isMapOverlay else overlay
|
|
longname = f'st{overlay[3:]}' if isMapOverlay else overlay
|
|
|
|
if isMapOverlay:
|
|
config['baseimg'] = 'iso/' + (f'ST/{name}/{name}.BIN').upper()
|
|
else:
|
|
config['baseimg'] = 'iso/' + (f'{name}.BIN').upper()
|
|
|
|
config["arch"] = "mipsel"
|
|
config['myimg'] = 'build/' + (f'{name}.bin').upper()
|
|
config['mapfile'] = f'build/{longname}.map'
|
|
config['source_directories'] = [
|
|
f'src/{overlay}', 'include', f'asm/{overlay}']
|
|
config['objdump_executable'] = 'mipsel-linux-gnu-objdump'
|