Another fucking AOW2 fork
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

build.bat 1.4KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. @TITLE All Out War 2 - The Epsilon Project build script
  2. @ECHO OFF
  3. SET PATH=%CD%\tools;%PATH%
  4. SET OUTDIR=%CD%\out
  5. IF "%1" == "/norev" (
  6. SET COMPRESSION=-mx=0
  7. ) ELSE (
  8. SET COMPRESSION=-mm=lzma -mx=9
  9. )
  10. IF NOT EXIST "%OUTDIR%" MKDIR "%OUTDIR%"
  11. :: Get Git informatiuon
  12. git rev-parse --abbrev-ref HEAD > %TEMP%/Epbranch
  13. SET /P GIT_BRANCH=<%TEMP%/Epbranch
  14. git rev-list --count %GIT_BRANCH% > %TEMP%/Epver
  15. SET /P GIT_NUMBER=<%TEMP%/Epver
  16. echo %GIT_NUMBER%
  17. IF NOT "%GIT_BRANCH%" == "master" (
  18. SET PK3BRANCH=-%GIT_BRANCH%
  19. )
  20. :: Generate gitcommit.py
  21. python "tools\gitcommit.py" "src\core\acs_source\a_gitcommit.acs"
  22. :: Generate acsconstants.txt
  23. "tools\acsconstants.exe" "src\core\acs_source\aow2scrp.acs" "src\core\actors\acsconstants.txt"
  24. :: Compile ACS
  25. IF NOT EXIST "src\core\acs" MKDIR "src\core\acs"
  26. acc "src\core\acs_source\aow2scrp.acs" "src\core\acs\aow2scrp.o"
  27. :: Create the actual PK3s
  28. COPY readme.txt src\core\
  29. IF "%1" == "/norev" SET GIT_NUMBER=dev
  30. SET OUTFILE=%OUTDIR%\aow2_epsilon%PK3BRANCH%-r%GIT_NUMBER%.pk3
  31. SET MUSFILE=%OUTDIR%\epsilon_music%PK3BRANCH%-r%GIT_NUMBER%.pk3
  32. IF EXIST "%OUTFILE%" DEL "%OUTFILE%"
  33. IF EXIST "%MUSFILE%" DEL "%MUSFILE%"
  34. PUSHD src
  35. PUSHD core
  36. 7za a -tzip "%OUTFILE%" %COMPRESSION% *.* -r -xr!*.dbs -xr!*.backup1 -xr!*.backup2 -xr!*.backup3 -xr!*.bak
  37. POPD
  38. PUSHD music
  39. 7za a -tzip "%MUSFILE%" %COMPRESSION% *.* -r -xr!*.dbs -xr!*.backup1 -xr!*.backup2 -xr!*.backup3 -xr!*.bak
  40. POPD
  41. POPD