From eb4cf556275bda19726786c139a14493412f99f7 Mon Sep 17 00:00:00 2001 From: duncathan Date: Fri, 10 Dec 2021 19:14:22 -0600 Subject: [PATCH] add needles to other_tsc --- caver/patcher.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/caver/patcher.py b/caver/patcher.py index 1f9e1b5..c7c59f8 100644 --- a/caver/patcher.py +++ b/caver/patcher.py @@ -88,12 +88,12 @@ def patch_map(mapname: str, mapdata: dict[str, dict], TscFile, output_dir: Path) mappath.write_bytes(bytes(chars)) output_dir.joinpath("data", "Plaintext", f"{mapname}.txt").write_text(TscFile.getPlaintext(tsc_file)) -def patch_other(filename: str, scripts: dict[str, str], TscFile, output_dir: Path): +def patch_other(filename: str, scripts: dict[str, dict[str, str]], TscFile, output_dir: Path): filepath = output_dir.joinpath("data", f"{filename}.tsc") tsc_file = TscFile.new(TscFile, filepath.read_bytes(), logging.getLogger("caver")) for event, script in scripts.items(): - TscFile.placeScriptAtEvent(tsc_file, script, event, filename) + TscFile.placeScriptAtEvent(tsc_file, script["script"], event, filename, script.get("needle", "