This commit is contained in:
2026-08-27 17:50:36 +02:00
commit 5a0e6520f4
51 changed files with 14027 additions and 0 deletions

27
ptlinux/gamebox.py Normal file
View File

@@ -0,0 +1,27 @@
"""Native X11 command construction for the clean borderless game window."""
from __future__ import annotations
import sys
from typing import Sequence
from .settings import Settings
def build_gamebox_command(
game_command: Sequence[str],
settings: Settings,
) -> list[str]:
if not game_command:
raise ValueError("game command cannot be empty")
command = [
sys.executable,
"-m",
"ptlinux.gamebox_runtime",
"--window-title",
"PristonTale EU",
]
if settings.borderless:
command.append("--borderless")
command.extend(("--", *[str(value) for value in game_command]))
return command