Version 3.2.0: fast lists with loading spinners, names from the game files, INT docs and screenshots, cleanup
This commit is contained in:
@@ -1,6 +1,9 @@
|
||||
"""Render the user-guide screenshots headless (docs/img/*.png). Read-only: never applies anything.
|
||||
|
||||
python tools/screenshots.py [--game DIR]
|
||||
python tools/screenshots.py [--game DIR] [--lang INT]
|
||||
|
||||
The app starts in the game's language as always; the screenshots then switch to --lang (default INT, the
|
||||
game's English) the way a user does, through the Language list.
|
||||
"""
|
||||
import argparse
|
||||
import os
|
||||
@@ -18,6 +21,7 @@ os.environ["ACKIT_NO_AUDIO"] = "1"
|
||||
def main():
|
||||
ap = argparse.ArgumentParser()
|
||||
ap.add_argument("--game")
|
||||
ap.add_argument("--lang", default="INT", help="language shown in the screenshots (default: INT)")
|
||||
a = ap.parse_args()
|
||||
from PySide6.QtWidgets import QApplication
|
||||
from ackit import audio
|
||||
@@ -38,7 +42,11 @@ def main():
|
||||
w = MainWindow(settings=st, runner=Runner(sync=True), game_dir=a.game)
|
||||
w.resize(1500, 950)
|
||||
w.show()
|
||||
app.processEvents() # the game loads here
|
||||
app.processEvents() # the game loads here (in the game's language)
|
||||
if a.lang and w.ws and w.language != a.lang.upper():
|
||||
w.cmb_lang.setCurrentText(a.lang.upper()) # what choosing it in the Language list does
|
||||
w.load_game(w.ws.game.root, a.lang.upper())
|
||||
app.processEvents()
|
||||
# status bar: show the store where users have it, not this temporary folder (no local user names)
|
||||
w.lbl_game.setText(w.lbl_game.text().replace(os.path.join(td, "data"), r"%APPDATA%\UnheardCity"))
|
||||
# 1: browser filtered by character
|
||||
|
||||
Reference in New Issue
Block a user