Skip to content

Commit

Permalink
fix black issues
Browse files Browse the repository at this point in the history
  • Loading branch information
ethteck committed Feb 2, 2024
1 parent 6710c93 commit 0d94b5e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
2 changes: 1 addition & 1 deletion tools/build/configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def write_ninja_rules(
ninja.variable("python", sys.executable)

ld_args = f"-T ver/$version/build/undefined_syms.txt -T ver/$version/undefined_syms_auto.txt -T ver/$version/undefined_funcs_auto.txt -Map $mapfile --no-check-sections -T $in -o $out"
ld = f"{cross}ld" if not 'PAPERMARIO_LD' in os.environ else os.environ['PAPERMARIO_LD']
ld = f"{cross}ld" if not "PAPERMARIO_LD" in os.environ else os.environ["PAPERMARIO_LD"]

if shift:
# For the shiftable build, we link twice to resolve some addresses that gnu ld can't figure out all in one go.
Expand Down
6 changes: 3 additions & 3 deletions tools/splat_ext/pm_sprites.py
Original file line number Diff line number Diff line change
Expand Up @@ -424,9 +424,9 @@ def get_sprite_name_from_offset(offset: int, offsets: List[int], names: List[str
raster_attributes["special"] = f"{back_raster.width & 0xFF:X},{back_raster.height & 0xFF:X}"
else:
back_name_offset = raster_sets[sprite_idx + 1].raster_offsets[i]
raster_attributes[
"back"
] = f"{get_sprite_name_from_offset(back_name_offset, sprite_offsets, raster_names)}.png"
raster_attributes["back"] = (
f"{get_sprite_name_from_offset(back_name_offset, sprite_offsets, raster_names)}.png"
)
if back_raster.palette_idx != raster.palette_idx:
raster_attributes[BACK_PALETTE_XML] = f"{back_raster.palette_idx:X}"

Expand Down
6 changes: 1 addition & 5 deletions tools/star_rod_idx_to_c.py
Original file line number Diff line number Diff line change
Expand Up @@ -385,11 +385,7 @@ def transform_symbol_name(symbol):
var_name = (
var_names[1]
if i == 0x4
else var_names[3]
if i == 0x14
else var_names[4]
if i == 0x18
else var_names[17]
else var_names[3] if i == 0x14 else var_names[4] if i == 0x18 else var_names[17]
)
addr = unpack_from(f">I", staticNpc, curr_base + i)[0]
if not addr == 0:
Expand Down

0 comments on commit 0d94b5e

Please sign in to comment.