@echo off setlocal EnableExtensions set "SCRIPT_DIR=%~dp0" set "PAPYRUS_RESULT=0" echo Building Commonwealth Online plugin... call "%SCRIPT_DIR%build.bat" if errorlevel 1 exit /b 1 echo. echo Building PrismaUI_F4... call "%SCRIPT_DIR%build-prismaui.bat" if errorlevel 1 exit /b 1 echo. echo Compiling Papyrus scripts... call "%SCRIPT_DIR%compile-papyrus.bat" "%~1" if errorlevel 1 set "PAPYRUS_RESULT=1" echo. echo Staging mod package... call "%SCRIPT_DIR%stage-mod.bat" if errorlevel 1 exit /b 1 if "%PAPYRUS_RESULT%"=="1" ( echo. echo Papyrus compilation failed, but the repo build folder was staged for inspection: echo %SCRIPT_DIR%build\Fallout 4\Data echo Fix the Papyrus compile errors before deploying. exit /b 1 ) echo. echo All builds finished. Mod package is in: echo %SCRIPT_DIR%build\Fallout 4\Data echo. echo Merge build\Fallout 4 into your Fallout 4 install, echo or run deploy-all.bat to install directly. endlocal exit /b 0