Fixed a bunch of code inconsistencies
This commit is contained in:
@@ -46,6 +46,7 @@ DCTS format (little-endian throughout):
|
||||
item stream. Every pool entry starts 4-byte aligned.
|
||||
"""
|
||||
|
||||
import argparse
|
||||
import json
|
||||
import os
|
||||
import struct
|
||||
@@ -428,9 +429,18 @@ def process_json(json_path):
|
||||
|
||||
|
||||
def main():
|
||||
args = sys.argv[1:]
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Generate DCTS binary cutscene files from raw JSONC "
|
||||
"cutscene definitions"
|
||||
)
|
||||
parser.add_argument(
|
||||
'paths', nargs='*',
|
||||
help='JSONC cutscene file(s) to process. If omitted, processes all '
|
||||
'assetsraw/cutscenes/*.jsonc'
|
||||
)
|
||||
args = parser.parse_args()
|
||||
|
||||
if not args:
|
||||
if not args.paths:
|
||||
cutscenes_dir = os.path.join(ASSETSRAW_DIR, 'cutscenes')
|
||||
if not os.path.isdir(cutscenes_dir):
|
||||
print(f"No directory found: {cutscenes_dir}")
|
||||
@@ -447,7 +457,7 @@ def main():
|
||||
process_json(p)
|
||||
return
|
||||
|
||||
for p in args:
|
||||
for p in args.paths:
|
||||
process_json(p)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user