Merge pull request #13 from Faraphel/dev

v0.6
This commit is contained in:
Faraphel 2021-06-16 01:14:37 +02:00 committed by GitHub
commit 4f57e99508
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
24 changed files with 448 additions and 381 deletions

1
.gitignore vendored
View file

@ -87,3 +87,4 @@
/build/ /build/
/test/ /test/
/distribution.txt /distribution.txt
/error.log

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 70 KiB

After

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

After

Width:  |  Height:  |  Size: 88 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 83 KiB

After

Width:  |  Height:  |  Size: 88 KiB

BIN
file/lecode-JAP.bin Normal file

Binary file not shown.

BIN
file/lecode-KOR.bin Normal file

Binary file not shown.

BIN
file/lecode-USA.bin Normal file

Binary file not shown.

View file

@ -3,6 +3,7 @@ from PIL import Image, ImageFont, ImageDraw
from tkinter import messagebox, filedialog, ttk from tkinter import messagebox, filedialog, ttk
from threading import Thread from threading import Thread
import subprocess import subprocess
import traceback
import requests import requests
import zipfile import zipfile
import shutil import shutil
@ -26,6 +27,7 @@ class ClassApp():
from source.restart import restart from source.restart import restart
from source.patch_img_desc import patch_img_desc from source.patch_img_desc import patch_img_desc
from source.patch_ct_icon import patch_ct_icon from source.patch_ct_icon import patch_ct_icon
from source.log_error import log_error
App = ClassApp() App = ClassApp()

View file

@ -49,8 +49,9 @@ options = {
"build_exe": { "build_exe": {
"include_files": include_files, "include_files": include_files,
"includes": ["tkinter", "requests"], "includes": ["tkinter", "requests"],
"include_msvcr": True,
"packages": [], "packages": [],
"excludes": [] "excludes": [],
} }
} }

View file

@ -9,6 +9,7 @@ from .check_update import check_update
from .translate import translate from .translate import translate
def __init__(self): def __init__(self):
try:
self.language = self.get_language() self.language = self.get_language()
self.root = Tk() self.root = Tk()
@ -51,6 +52,7 @@ def __init__(self):
def use_path(): def use_path():
def func(): def func():
try:
self.frame_action.grid_forget() self.frame_action.grid_forget()
path = entry_game_path.get() path = entry_game_path.get()
if not (os.path.exists(path)): if not (os.path.exists(path)):
@ -64,15 +66,18 @@ def __init__(self):
"Êtes-vous sûr de vouloir l'utiliser ?")): "Êtes-vous sûr de vouloir l'utiliser ?")):
self.path_mkwf = os.path.realpath(path + "/../../") self.path_mkwf = os.path.realpath(path + "/../../")
elif extension.upper() in ["ISO", "WBFS", "WIA", "CSIO"]: elif extension.upper() in ["ISO", "WBFS", "WIA", "CSIO"]:
self.path_mkwf, i = os.path.realpath(path + "/../MKWiiFaraphel"), 1 # Fiding a directory name that dosen't already exist
directory_name, i = "MKWiiFaraphel", 1
while True: while True:
self.path_mkwf = os.path.realpath(path + f"/../{directory_name}")
if not(os.path.exists(self.path_mkwf)): break if not(os.path.exists(self.path_mkwf)): break
self.path_mkwf, i = os.path.realpath(path + f"/../MKWiiFaraphel ({i})"), i + 1 directory_name, i = f"MKWiiFaraphel ({i})", i + 1
if os.path.exists(self.path_mkwf + "/DATA/"): self.path_mkwf += "/DATA/"
self.Progress(show=True, indeter=True, statut=self.translate("Extraction du jeu...")) self.Progress(show=True, indeter=True, statut=self.translate("Extraction du jeu..."))
subprocess.call(["./tools/wit/wit", "EXTRACT", path, "--DEST", self.path_mkwf] subprocess.call(["./tools/wit/wit", "EXTRACT", get_nodir(path), "--DEST", directory_name]
, creationflags=CREATE_NO_WINDOW) , creationflags=CREATE_NO_WINDOW, cwd=get_dir(path))
self.Progress(show=False) self.Progress(show=False)
else: else:
@ -85,6 +90,8 @@ def __init__(self):
self.translate("Cette ROM est déjà moddé, " + self.translate("Cette ROM est déjà moddé, " +
"il est déconseillé de l'utiliser pour installer le mod")) "il est déconseillé de l'utiliser pour installer le mod"))
except: self.log_error()
finally:
self.frame_action.grid(row=3, column=1, sticky="NEWS") self.frame_action.grid(row=3, column=1, sticky="NEWS")
self.Progress(show=False) self.Progress(show=False)
@ -129,3 +136,6 @@ def __init__(self):
self.progressbar = ttk.Progressbar(self.root) self.progressbar = ttk.Progressbar(self.root)
self.progresslabel = Label(self.root) self.progresslabel = Label(self.root)
except:
self.log_error()

View file

@ -6,13 +6,17 @@ import sys
import os import os
VERSION_FILE_URL = "https://raw.githubusercontent.com/Faraphel/MKWF-Install/master/version" VERSION_FILE_URL = "https://raw.githubusercontent.com/Faraphel/MKWF-Install/master/version"
def check_update(self): def check_update(self):
try: try:
gitversion = requests.get(VERSION_FILE_URL, allow_redirects=True).json() gitversion = requests.get(VERSION_FILE_URL, allow_redirects=True).json()
with open("version", "rb") as f: with open("./version", "rb") as f:
locversion = json.load(f) locversion = json.load(f)
if float(gitversion["version"]) > float(locversion["version"]): if ((float(gitversion["version"]) > float(locversion["version"])) or
(float(gitversion["version"]) == float(locversion["version"])) and
float(gitversion["subversion"]) > float(locversion["subversion"])):
if messagebox.askyesno(self.translate("Mise à jour disponible !"), self.translate("Une mise à jour est disponible, souhaitez-vous l'installer ?") + if messagebox.askyesno(self.translate("Mise à jour disponible !"), self.translate("Une mise à jour est disponible, souhaitez-vous l'installer ?") +
f"\n\nVersion : {locversion['version']}.{locversion['subversion']} -> {gitversion['version']}.{gitversion['subversion']}\n"+\ f"\n\nVersion : {locversion['version']}.{locversion['subversion']} -> {gitversion['version']}.{gitversion['subversion']}\n"+\
f"Changelog :\n{gitversion['changelog']}"): f"Changelog :\n{gitversion['changelog']}"):
@ -34,5 +38,5 @@ def check_update(self):
os.startfile(os.path.realpath("./Updater/Updater.exe")) os.startfile(os.path.realpath("./Updater/Updater.exe"))
sys.exit() sys.exit()
except Exception as e: except:
print(e) self.log_error()

View file

@ -2,6 +2,7 @@ import json
def create_lecode_config(self): def create_lecode_config(self):
try:
def get_star_text(track): def get_star_text(track):
if "warning" in track: warning = "!" * track["warning"] if "warning" in track: warning = "!" * track["warning"]
else: warning = "" else: warning = ""
@ -72,3 +73,6 @@ def create_lecode_config(self):
for _ in range(1, 4-(i%4)): # Complete cup if track are missing for _ in range(1, 4-(i%4)): # Complete cup if track are missing
ctfile.write(f' T T44; T44; 0x00; "_"; ""; "-"\n') ctfile.write(f' T T44; T44; 0x00; "_"; ""; "-"\n')
rctfile.write(f' T T44; T44; 0x00; "_"; ""; "-"\n') rctfile.write(f' T T44; T44; 0x00; "_"; ""; "-"\n')
except:
self.log_error()

View file

@ -1,9 +1,10 @@
get_filename = lambda file: ".".join(file.split(".")[:-1]) get_filename = lambda file: ".".join(file.split(".")[:-1])
get_nodir = lambda file: file.split("/")[-1].split("\\")[-1] get_nodir = lambda file: file.replace("\\", "/").split("/")[-1]
get_dir = lambda file: "/".join(file.replace("\\", "/").split("/")[:-1])
get_extension = lambda file: file.split(".")[-1] get_extension = lambda file: file.split(".")[-1]
CREATE_NO_WINDOW = 0x08000000 CREATE_NO_WINDOW = 0x08000000
VERSION = "0.8" VERSION = "0.8.1"
def filecopy(src, dst): def filecopy(src, dst):
with open(src, "rb") as f1: with open(src, "rb") as f1:

View file

@ -11,6 +11,7 @@ from .definition import *
def install_mod(self): def install_mod(self):
def func(): def func():
try:
with open("./fs.json") as f: with open("./fs.json") as f:
fs = json.load(f) fs = json.load(f)
@ -48,8 +49,9 @@ def install_mod(self):
if extension == "szs": if extension == "szs":
if not (os.path.realpath(path) in extracted_file): if not (os.path.realpath(path) in extracted_file):
subprocess.call(["./tools/szs/wszst", "EXTRACT", path, "-d", path + ".d", "--overwrite"] subprocess.run(["./tools/szs/wszst", "EXTRACT", get_nodir(path), "-d", get_nodir(path) + ".d",
, creationflags=CREATE_NO_WINDOW) "--overwrite"], creationflags=CREATE_NO_WINDOW, cwd=get_dir(path),
check=True, stdout=subprocess.PIPE)
extracted_file.append(os.path.realpath(path)) extracted_file.append(os.path.realpath(path))
szs_extract_path = path + ".d" szs_extract_path = path + ".d"
@ -77,39 +79,53 @@ def install_mod(self):
for file in extracted_file: for file in extracted_file:
self.Progress(statut=self.translate("Recompilation de")+f"\n{get_nodir(file)}", add=1) self.Progress(statut=self.translate("Recompilation de")+f"\n{get_nodir(file)}", add=1)
subprocess.call(["./tools/szs/wszst", "CREATE", file + ".d", "-d", file, subprocess.run(["./tools/szs/wszst", "CREATE", get_nodir(file) + ".d", "-d", get_nodir(file),
"--overwrite"], creationflags=CREATE_NO_WINDOW) "--overwrite"], creationflags=CREATE_NO_WINDOW, cwd=get_dir(file),
check=True, stdout=subprocess.PIPE)
if os.path.exists(file + ".d"): shutil.rmtree(file + ".d") if os.path.exists(file + ".d"): shutil.rmtree(file + ".d")
self.Progress(statut=self.translate("Patch main.dol"), add=1) self.Progress(statut=self.translate("Patch main.dol"), add=1)
subprocess.call(["./tools/szs/wstrt", "patch", self.path_mkwf + "/sys/main.dol", "--clean-dol", subprocess.run(["./tools/szs/wstrt", "patch", get_nodir(self.path_mkwf) + "/sys/main.dol", "--clean-dol",
"--add-lecode"], creationflags=CREATE_NO_WINDOW) "--add-lecode"], creationflags=CREATE_NO_WINDOW, cwd=get_dir(self.path_mkwf),
check=True, stdout=subprocess.PIPE)
self.Progress(statut=self.translate("Patch lecode-PAL.bin"), add=1) self.Progress(statut=self.translate("Patch lecode-PAL.bin"), add=1)
subprocess.call( shutil.copytree("./file/Track/", self.path_mkwf+"/files/Race/Course/", dirs_exist_ok=True)
["./tools/szs/wlect", "patch", "./file/lecode-PAL.bin", "-od", self.path_mkwf + "/files/rel/lecode-PAL.bin", if not(os.path.exists(self.path_mkwf+"/tmp/")): os.makedirs(self.path_mkwf+"/tmp/")
"--track-dir", self.path_mkwf + "/files/Race/Course/", "--copy-tracks", "./file/Track/", filecopy("./file/CTFILE.txt", self.path_mkwf+"/tmp/CTFILE.txt")
"--move-tracks", self.path_mkwf + "/files/Race/Course/", "--le-define", filecopy("./file/lpar-default.txt", self.path_mkwf + "/tmp/lpar-default.txt")
"./file/CTFILE.txt", "--lpar", "./file/lpar-default.txt", "--overwrite"], creationflags=CREATE_NO_WINDOW) filecopy("./file/lecode-PAL.bin", self.path_mkwf + "/tmp/lecode-PAL.bin")
subprocess.run(
["./tools/szs/wlect", "patch", "./tmp/lecode-PAL.bin", "-od", "./files/rel/lecode-PAL.bin",
"--track-dir", "./files/Race/Course/", "--move-tracks", "./files/Race/Course/", "--le-define",
"./tmp/CTFILE.txt", "--lpar", "./tmp/lpar-default.txt", "--overwrite"],
creationflags=CREATE_NO_WINDOW, cwd=self.path_mkwf, check=True, stdout=subprocess.PIPE)
shutil.rmtree(self.path_mkwf + "/tmp/")
outputformat = self.listbox_outputformat.get() outputformat = self.listbox_outputformat.get()
self.Progress(statut=self.translate("Conversion en")+f" {outputformat}", add=1) self.Progress(statut=self.translate("Conversion en")+f" {outputformat}", add=1)
if outputformat in ["ISO", "WBFS", "CISO"]: if outputformat in ["ISO", "WBFS", "CISO"]:
self.path_mkwf_format = os.path.realpath(self.path_mkwf + "/../MKWFaraphel." + outputformat.lower()) self.path_mkwf_format = os.path.realpath(self.path_mkwf + "/../MKWFaraphel." + outputformat.lower())
subprocess.call(["./tools/wit/wit", "COPY", self.path_mkwf, "--DEST", subprocess.run(["./tools/wit/wit", "COPY", get_nodir(self.path_mkwf), "--DEST",
self.path_mkwf_format, f"--{outputformat.lower()}", "--overwrite"] get_nodir(self.path_mkwf_format), f"--{outputformat.lower()}", "--overwrite"],
, creationflags=CREATE_NO_WINDOW) CREATE_NO_WINDOW, cwd=get_dir(self.path_mkwf),
check=True, stdout=subprocess.PIPE)
shutil.rmtree(self.path_mkwf) shutil.rmtree(self.path_mkwf)
self.Progress(statut=self.translate("Changement de l'ID du jeu"), add=1) self.Progress(statut=self.translate("Changement de l'ID du jeu"), add=1)
subprocess.call(["./tools/wit/wit", "EDIT", self.path_mkwf_format, "--id", "RMCP60"] subprocess.run(["./tools/wit/wit", "EDIT", get_dir(self.path_mkwf_format), "--id", "RMCP60"],
, creationflags=CREATE_NO_WINDOW) creationflags=CREATE_NO_WINDOW, cwd=get_dir(self.path_mkwf_format),
check=True, stdout=subprocess.PIPE)
self.Progress(show=False)
messagebox.showinfo(self.translate("Fin"), self.translate("L'installation est terminé !")) messagebox.showinfo(self.translate("Fin"), self.translate("L'installation est terminé !"))
except: self.log_error()
finally: self.Progress(show=False)
t = Thread(target=func) t = Thread(target=func)
t.setDaemon(True) t.setDaemon(True)
t.start() t.start()

7
source/log_error.py Normal file
View file

@ -0,0 +1,7 @@
import traceback
from tkinter import messagebox
def log_error(self):
error = traceback.format_exc()
with open("./error.log", "a") as f: f.write(f"---\n{error}\n")
messagebox.showerror(self.translate("Erreur"), self.translate("Une erreur est survenue :") + f"\n{error}\n\n")

View file

@ -84,16 +84,19 @@ trackname_color = {
"★☆☆!! ": "\c{YOR6}★☆☆\c{off} ", "★☆☆!! ": "\c{YOR6}★☆☆\c{off} ",
} }
def patch_bmg(self, gamefile): # gamefile est le fichier .szs trouvé dans le /files/Scene/UI/ du jeu def patch_bmg(self, gamefile): # gamefile est le fichier .szs trouvé dans le /files/Scene/UI/ du jeu
try:
bmglang = gamefile[-len("E.txt"):-len(".txt")] # Langue du fichier bmglang = gamefile[-len("E.txt"):-len(".txt")] # Langue du fichier
self.Progress(statut=self.translate("Patch des textes " + bmglang), add=1) self.Progress(statut=self.translate("Patch des textes " + bmglang), add=1)
subprocess.call(["./tools/szs/wszst", "EXTRACT", gamefile, "-d", gamefile + ".d", "--overwrite"] subprocess.run(["./tools/szs/wszst", "EXTRACT", get_nodir(gamefile), "-d", get_nodir(gamefile) + ".d",
, creationflags=CREATE_NO_WINDOW) "--overwrite"], creationflags=CREATE_NO_WINDOW, cwd=get_dir(gamefile))
# Common.bmg # Common.bmg
bmgtracks = subprocess.check_output(["./tools/szs/wbmgt", "CAT", gamefile + ".d/message/Common.bmg"], bmgtracks = subprocess.run(["./tools/szs/wbmgt", "CAT", get_nodir(gamefile) + ".d/message/Common.bmg"],
creationflags=CREATE_NO_WINDOW) creationflags=CREATE_NO_WINDOW, cwd=get_dir(gamefile),
check=True, stdout=subprocess.PIPE).stdout
bmgtracks = bmgtracks.decode() bmgtracks = bmgtracks.decode()
trackheader = "#--- standard track names" trackheader = "#--- standard track names"
trackend = "2328" trackend = "2328"
@ -124,23 +127,29 @@ def patch_bmg(self, gamefile): # gamefile est le fichier .szs trouvé dans le /
Tname = bmgtrack[bmgtrack.find("= ") + 2:] Tname = bmgtrack[bmgtrack.find("= ") + 2:]
f.write(f" {Tid}\t= {prefix}{Tname}\n") f.write(f" {Tid}\t= {prefix}{Tname}\n")
bmgtext = subprocess.check_output(["tools/szs/wctct", "bmg", "--le-code", "--long", "./file/CTFILE.txt", if not(os.path.exists("./file/tmp/")): os.makedirs("./file/tmp/")
"--patch-bmg", "OVERWRITE=" + gamefile + ".d/message/Common.bmg",
"--patch-bmg", "OVERWRITE=./file/ExtraCommon.txt"], filecopy(gamefile+".d/message/Common.bmg", "./file/tmp/Common.bmg")
creationflags=CREATE_NO_WINDOW).decode() bmgtext = subprocess.run(["tools/szs/wctct", "bmg", "--le-code", "--long", "./file/CTFILE.txt", "--patch-bmg",
rbmgtext = subprocess.check_output(["tools/szs/wctct", "bmg", "--le-code", "--long", "./file/RCTFILE.txt", "OVERWRITE=./file/tmp/Common.bmg", "--patch-bmg", "OVERWRITE=./file/ExtraCommon.txt"],
"--patch-bmg", "OVERWRITE=" + gamefile + ".d/message/Common.bmg", creationflags=CREATE_NO_WINDOW, check=True, stdout=subprocess.PIPE).stdout.decode()
"--patch-bmg", "OVERWRITE=./file/ExtraCommon.txt"], rbmgtext = subprocess.run(["tools/szs/wctct", "bmg", "--le-code", "--long", "./file/RCTFILE.txt", "--patch-bmg",
creationflags=CREATE_NO_WINDOW).decode() "OVERWRITE=./file/tmp/Common.bmg", "--patch-bmg", "OVERWRITE=./file/ExtraCommon.txt"],
creationflags=CREATE_NO_WINDOW, check=True, stdout=subprocess.PIPE).stdout.decode()
shutil.rmtree(gamefile + ".d") shutil.rmtree(gamefile + ".d")
os.remove("./file/tmp/Common.bmg")
os.remove("./file/ExtraCommon.txt") os.remove("./file/ExtraCommon.txt")
def finalise(common_file, bmgtext): def finalise(common_file, bmgtext):
for console in trackname_color: bmgtext = bmgtext.replace(console, trackname_color[console]) for console in trackname_color: bmgtext = bmgtext.replace(console, trackname_color[console])
with open(common_file, "w", encoding="utf-8") as f: f.write(bmgtext) with open(common_file, "w", encoding="utf-8") as f: f.write(bmgtext)
subprocess.call(["./tools/szs/wbmgt", "ENCODE", common_file, "--overwrite"], creationflags=CREATE_NO_WINDOW) subprocess.run(["./tools/szs/wbmgt", "ENCODE", get_nodir(common_file), "--overwrite"],
creationflags=CREATE_NO_WINDOW, cwd=get_dir(common_file))
os.remove(common_file) os.remove(common_file)
finalise(f"./file/Common_{bmglang}.txt", bmgtext) finalise(f"./file/Common_{bmglang}.txt", bmgtext)
finalise(f"./file/Common_R{bmglang}.txt", rbmgtext) finalise(f"./file/Common_R{bmglang}.txt", rbmgtext)
except:
self.log_error()

View file

@ -5,6 +5,7 @@ import os
def patch_ct_icon(self): def patch_ct_icon(self):
try:
with open("./ct_config.json", encoding="utf8") as f: config = json.load(f) with open("./ct_config.json", encoding="utf8") as f: config = json.load(f)
cup_number = len(config["cup"]) + math.ceil(len(config["tracks_list"]) / 4) cup_number = len(config["cup"]) + math.ceil(len(config["tracks_list"]) / 4)
@ -39,3 +40,6 @@ def patch_ct_icon(self):
ct_icon.paste(cup_icon, (0, i * 128)) ct_icon.paste(cup_icon, (0, i * 128))
ct_icon.save("./file/ct_icons.tpl.png") ct_icon.save("./file/ct_icons.tpl.png")
except:
self.log_error()

View file

@ -9,6 +9,7 @@ from .definition import *
def patch_file(self): def patch_file(self):
def func(): def func():
try:
if os.path.exists("./file/Track-WU8/"): if os.path.exists("./file/Track-WU8/"):
total_track = len(os.listdir("./file/Track-WU8/")) total_track = len(os.listdir("./file/Track-WU8/"))
else: else:
@ -29,14 +30,14 @@ def patch_file(self):
for i, file in enumerate(fc["img"]): for i, file in enumerate(fc["img"]):
self.Progress(statut=self.translate("Conversion des images")+f"\n({i + 1}/{len(fc['img'])}) {file}", add=1) self.Progress(statut=self.translate("Conversion des images")+f"\n({i + 1}/{len(fc['img'])}) {file}", add=1)
subprocess.call(["./tools/szs/wimgt", "ENCODE", "./file/" + file, "-x", fc["img"][file], "--overwrite"] subprocess.run(["./tools/szs/wimgt", "ENCODE", "./file/" + file, "-x", fc["img"][file], "--overwrite"],
, creationflags=CREATE_NO_WINDOW) creationflags=CREATE_NO_WINDOW)
for file in glob.glob(self.path_mkwf+"/files/Scene/UI/MenuSingle_?.szs"): for file in glob.glob(self.path_mkwf+"/files/Scene/UI/MenuSingle_?.szs"):
self.patch_bmg(file) self.patch_bmg(file)
if not(os.path.exists("./file/auto-add/")): if not(os.path.exists("./file/auto-add/")):
subprocess.call(["./tools/szs/wszst", "AUTOADD", self.path_mkwf + "/files/Race/Course/", "--DEST", subprocess.run(["./tools/szs/wszst", "AUTOADD", self.path_mkwf + "/files/Race/Course/", "--DEST",
"./file/auto-add/"], creationflags=CREATE_NO_WINDOW) "./file/auto-add/"], creationflags=CREATE_NO_WINDOW)
max_process = 8 max_process = 8
@ -69,6 +70,9 @@ def patch_file(self):
self.button_install_mod.grid(row=2, column=1, sticky="NEWS") self.button_install_mod.grid(row=2, column=1, sticky="NEWS")
self.listbox_outputformat.grid(row=2, column=2, sticky="NEWS") self.listbox_outputformat.grid(row=2, column=2, sticky="NEWS")
except:
self.log_error()
t = Thread(target=func) t = Thread(target=func)
t.setDaemon(True) t.setDaemon(True)
t.start() t.start()

View file

@ -5,6 +5,7 @@ from .definition import *
def patch_img_desc(self): def patch_img_desc(self):
try:
il = Image.open("./file/img_desc/illustration.png") il = Image.open("./file/img_desc/illustration.png")
il_16_9 = il.resize((832, 456)) il_16_9 = il.resize((832, 456))
il_4_3 = il.resize((608, 456)) il_4_3 = il.resize((608, 456))
@ -23,3 +24,6 @@ def patch_img_desc(self):
new_4_3.paste(il_4_3, (0, 0), il_4_3) new_4_3.paste(il_4_3, (0, 0), il_4_3)
new_4_3.paste(img_lang_4_3, (0, 0), img_lang_4_3) new_4_3.paste(img_lang_4_3, (0, 0), img_lang_4_3)
new_4_3.save(f"./file/strapA_608x456{get_filename(get_nodir(file_lang))}.png") new_4_3.save(f"./file/strapA_608x456{get_filename(get_nodir(file_lang))}.png")
except:
self.log_error()

View file

@ -1 +1 @@
{"en": {"Cette action va extraire / utiliser la ROM s\u00e9lectionn\u00e9, pr\u00e9parer les fichiers et installer le mod. Voulez-vous continuer ?": "This will extract the selected ROM, prepare files and install mod. Do you wish to continue ?", "Fonctionnalit\u00e9 exp\u00e9rimentale": "Experimental functionality", "Tout faire": "Do everything", "Cr\u00e9ation des images descriptives": "Creation of descriptive images", "Cr\u00e9ation de ct_icon.png": "Creating ct_icon.png", "Patch des textes ": "Patching text ", "Al\u00e9atoire: Toutes les pistes": "Random: All tracks", "Al\u00e9atoire: Pistes Originales": "Random: Original tracks", "Al\u00e9atoire: Custom Tracks": "Random: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Random: New tracks", "MKWFaraphel Installateur": "MKWFaraphel Installer", "Jeu Wii": "Wii game", "Jeu original": "Original game", "Erreur": "Error", "Le chemin de fichier est invalide": "The file path in invalid", "Attention": "Warning", "Ce dossier sera \u00e9cras\u00e9 si vous installer le mod !\n\u00cates-vous s\u00fbr de vouloir l'utiliser ?": "This directory will be overwritten if you install the mod !\nAre you sure you want to use it ?", "Extraction du jeu...": "Extracting the game...", "Le type de fichier n'est pas reconnu": "This file type is not supported", "Cette ROM est d\u00e9j\u00e0 modd\u00e9, il est d\u00e9conseill\u00e9 de l'utiliser pour installer le mod": "This game is already modded, it is not recommended to use it to install the mod", "Extraire le fichier": "Extract file", "Preparer les fichiers": "Prepare files", "Action": "Action", "Installer le mod": "Install mod", "Dossier": "Directory", "Langage : ": "Language : ", "Mise \u00e0 jour disponible !": "Update available !", "Une mise \u00e0 jour est disponible, souhaitez-vous l'installer ?": "An update is available, do you want to install it ?", "T\u00e9l\u00e9chargement de Updater en cours...": "Downloading the Updater...", "fin du t\u00e9l\u00e9chargement, d\u00e9but de l'extraction...": "end of the download, extracting...", "fin de l'extraction": "finished extracting", "lancement de l'application...": "starting application...", "Modification de": "Modifying", "Recompilation de": "Recompilating", "Conversion en": "Converting to", "Changement de l'ID du jeu": "editing game's ID", "Fin": "End", "L'installation est termin\u00e9 !": "The mod has been installed !", "Conversion des fichiers": "Converting files", "Conversion des images": "Converting images", "Conversion des textes": "Converting texts", "Conversion des courses": "Converting races", "Configuration de LE-CODE": "Configurating LE-CODE"}, "ge": {"Al\u00e9atoire: Toutes les pistes": "Zuf\u00e4llig: Alle Spuren", "Al\u00e9atoire: Pistes Originales": "Zuf\u00e4llig: Original-Spuren", "Al\u00e9atoire: Custom Tracks": "Zuf\u00e4llig: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Zuf\u00e4llig: Neue Spuren"}, "it": {"Al\u00e9atoire: Toutes les pistes": "Casuale: Tutte le tracce", "Al\u00e9atoire: Pistes Originales": "Casuale: Tracce originali", "Al\u00e9atoire: Custom Tracks": "Casuale: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Casuale: Nuovi brani"}, "sp": {"Al\u00e9atoire: Toutes les pistes": "Aleatorio: Todas las pistas", "Al\u00e9atoire: Pistes Originales": "Aleatorio: Pistas originales", "Al\u00e9atoire: Custom Tracks": "Aleatorio: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Aleatorio: Pistas nuevas"}, "selected": "fr"} {"en": {"Une erreur est survenue :": "An error occured :", "Cette action va extraire / utiliser la ROM s\u00e9lectionn\u00e9, pr\u00e9parer les fichiers et installer le mod. Voulez-vous continuer ?": "This will extract the selected ROM, prepare files and install mod. Do you wish to continue ?", "Fonctionnalit\u00e9 exp\u00e9rimentale": "Experimental functionality", "Tout faire": "Do everything", "Cr\u00e9ation des images descriptives": "Creation of descriptive images", "Cr\u00e9ation de ct_icon.png": "Creating ct_icon.png", "Patch des textes ": "Patching text ", "Al\u00e9atoire: Toutes les pistes": "Random: All tracks", "Al\u00e9atoire: Pistes Originales": "Random: Original tracks", "Al\u00e9atoire: Custom Tracks": "Random: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Random: New tracks", "MKWFaraphel Installateur": "MKWFaraphel Installer", "Jeu Wii": "Wii game", "Jeu original": "Original game", "Erreur": "Error", "Le chemin de fichier est invalide": "The file path in invalid", "Attention": "Warning", "Ce dossier sera \u00e9cras\u00e9 si vous installer le mod !\n\u00cates-vous s\u00fbr de vouloir l'utiliser ?": "This directory will be overwritten if you install the mod !\nAre you sure you want to use it ?", "Extraction du jeu...": "Extracting the game...", "Le type de fichier n'est pas reconnu": "This file type is not supported", "Cette ROM est d\u00e9j\u00e0 modd\u00e9, il est d\u00e9conseill\u00e9 de l'utiliser pour installer le mod": "This game is already modded, it is not recommended to use it to install the mod", "Extraire le fichier": "Extract file", "Preparer les fichiers": "Prepare files", "Action": "Action", "Installer le mod": "Install mod", "Dossier": "Directory", "Langage : ": "Language : ", "Mise \u00e0 jour disponible !": "Update available !", "Une mise \u00e0 jour est disponible, souhaitez-vous l'installer ?": "An update is available, do you want to install it ?", "T\u00e9l\u00e9chargement de Updater en cours...": "Downloading the Updater...", "fin du t\u00e9l\u00e9chargement, d\u00e9but de l'extraction...": "end of the download, extracting...", "fin de l'extraction": "finished extracting", "lancement de l'application...": "starting application...", "Modification de": "Modifying", "Recompilation de": "Recompilating", "Conversion en": "Converting to", "Changement de l'ID du jeu": "editing game's ID", "Fin": "End", "L'installation est termin\u00e9 !": "The mod has been installed !", "Conversion des fichiers": "Converting files", "Conversion des images": "Converting images", "Conversion des textes": "Converting texts", "Conversion des courses": "Converting races", "Configuration de LE-CODE": "Configurating LE-CODE"}, "ge": {"Al\u00e9atoire: Toutes les pistes": "Zuf\u00e4llig: Alle Spuren", "Al\u00e9atoire: Pistes Originales": "Zuf\u00e4llig: Original-Spuren", "Al\u00e9atoire: Custom Tracks": "Zuf\u00e4llig: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Zuf\u00e4llig: Neue Spuren"}, "it": {"Al\u00e9atoire: Toutes les pistes": "Casuale: Tutte le tracce", "Al\u00e9atoire: Pistes Originales": "Casuale: Tracce originali", "Al\u00e9atoire: Custom Tracks": "Casuale: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Casuale: Nuovi brani"}, "sp": {"Al\u00e9atoire: Toutes les pistes": "Aleatorio: Todas las pistas", "Al\u00e9atoire: Pistes Originales": "Aleatorio: Pistas originales", "Al\u00e9atoire: Custom Tracks": "Aleatorio: Custom Tracks", "Al\u00e9atoire: Pistes Nouvelles": "Aleatorio: Pistas nuevas"}, "selected": "fr"}

View file

@ -1,7 +1,7 @@
{ {
"version": "0.5", "version": "0.6",
"subversion": "1", "subversion": "0",
"changelog": "- les courses Mario Kart Tour ne fonctionnaient pas", "changelog": "- The image of the score system explanation now have explain the star's color\n- Microsoft Visual C++ should now be included with the installer, avoiding an error with vcruntime140.dll\n- Update will now be detected by the installer when changing subversion (0.5.1 -> 0.5.2 will be detected)\n- A new file named \"error.log\" can now be generated when an error is occurring, helping debugging\n- Updated cx_freeze so that having special character in path don't cause issue (.exe version)\n- Fixed an issue where having a dump with a DATA directory would cause the installer to not work",
"download_bin": "https://github.com/Faraphel/MKWF-Install/releases/download/0.5.1/MKWF.v0.5.1.zip", "download_bin": "https://github.com/Faraphel/MKWF-Install/releases/download/0.6/MKWF.v0.6.zip",
"updater_bin": "https://github.com/Faraphel/MKWF-Install/raw/master/Updater/Updater.zip" "updater_bin": "https://github.com/Faraphel/MKWF-Install/raw/master/Updater/Updater.zip"
} }