edited default value

This commit is contained in:
raphael60650 2021-07-27 21:33:02 +02:00
parent 54b5dceb78
commit 2baf246599
4 changed files with 6 additions and 5 deletions

View file

@ -1,7 +1,7 @@
import subprocess
def ctc_patch_bmg(bmgs: list, ctfile: str = "./file/CTFILE.txt"):
def patch_bmg(bmgs: list, ctfile: str = "./file/CTFILE.txt"):
"""
Patch a bmg file with a ctfile with OVERWRITE option
:param bmgs: all bmg files

View file

@ -6,8 +6,8 @@ def patch(path: str,
dest_lecode_file: str = f"./files/rel/lecode-PAL.bin",
game_track_path: str = "./files/Race/Course/",
move_track_path: str = "./files/Race/Course/",
ctfile_path: str = "./tmp/CTFILE.txt",
lpar_path: str = "./tmp/lpar-default.txt") -> None:
ctfile_path: str = "./file/CTFILE.txt",
lpar_path: str = "./file/lpar-default.txt") -> None:
"""
Patch the file with a lecode file (this is the adding track part)
:param path: path to the game file

View file

@ -1,12 +1,13 @@
import subprocess
def extract(file: str, dest_dir: str) -> None:
def extract(file: str, dest_dir: str = None) -> None:
"""
Extract an szs in a directory
:param file: .szs file
:param dest_dir: directory where to extract the file
"""
if dest_dir is None: dest_dir = file
subprocess.run(["./tools/szs/wszst", "EXTRACT", file, "--DEST", dest_dir + ".d"],
creationflags=subprocess.CREATE_NO_WINDOW)

View file

@ -23,7 +23,7 @@ def edit(file: str, region_ID: str = "P", name: str = "Mario Kart Wii") -> None:
creationflags=subprocess.CREATE_NO_WINDOW, check=True, stdout=subprocess.PIPE)
def copy(src_path, dst_path, format: str = "ISO") -> None:
def copy(src_path: str, dst_path: str, format: str = "ISO") -> None:
"""
Copy the game into an another format
:param src_path: original game path