mirror of
https://github.com/ProjectLeonida/mandy.git
synced 2026-12-06 09:38:37 +00:00
tools/leonida_mods.py manages the port's mods folder: create, install, list, check, enable, disable, pack, remove and a gta6rt launcher, with a Tkinter window behind Mods.bat on Windows. Packages are plain ZIPs with mod.json at the top level; the installer refuses paths that climb out of the package and never touches game data. mods/ ships four archetype-swap examples, three of them installed disabled. Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
27 lines
787 B
Batchfile
27 lines
787 B
Batchfile
@echo off
|
|
title Leonida - Mod Manager
|
|
rem Double-click to open the mod manager window. It manages <port>\mods and never touches the game package.
|
|
setlocal
|
|
cd /d "%~dp0"
|
|
set "PY="
|
|
for %%V in (3.14 3.13 3.12 3) do (
|
|
if not defined PY (
|
|
py -%%V -c "import sys; sys.exit(0 if sys.version_info >= (3, 12) else 1)" >nul 2>nul && set "PY=py -%%V"
|
|
)
|
|
)
|
|
if not defined PY (
|
|
where python >nul 2>nul && (
|
|
python -c "import sys; sys.exit(0 if sys.version_info >= (3, 12) else 1)" >nul 2>nul && set "PY=python"
|
|
)
|
|
)
|
|
if not defined PY (
|
|
echo Python 3.12 or newer is needed: https://www.python.org/downloads/
|
|
echo Tick "Add python.exe to PATH" during setup.
|
|
pause
|
|
exit /b 1
|
|
)
|
|
%PY% -I "%~dp0tools\leonida_mods.py" gui %*
|
|
set "RC=%ERRORLEVEL%"
|
|
if not "%RC%"=="0" pause
|
|
exit /b %RC%
|