@echo off
set cdpt=%~dp0
cd %cdpt%
set "space=     "

rem EN version
call .\add\plugin_src\compile.bat en
echo %cdpt%
cd %cdpt%
path .\cross_tools
echo %space% INCLUDE "local/en.asm" > local.asm
sjasmplus --exp="export.asm"  --color=off --dos866 bge_eng.asm 2> bge_EN.log
echo.>> bge_EN.log
echo.>> bge_EN.log

hrust13 bge_main bge_main.hst
hrust13 bge_3 bge_3.hst
hrust13 bge_6 bge_6.hst
hrust13 bge_7 bge_7.hst

sjasmplus --color=off --dos866 loader.asm 2>> bge_EN.log

rem pause
del *.hst
del bge_EN.trd
ren bge_xxx.trd bge_EN.trd

rem RU version
call .\add\plugin_src\compile.bat ru
echo %cdpt%
cd %cdpt%
path .\cross_tools
echo %space% INCLUDE "local/ru.asm" > local.asm
sjasmplus --exp="export.asm" --color=off --dos866  bge_rus.asm 2> bge_RU.log
echo.>> bge_RU.log
echo.>> bge_RU.log

hrust13 bge_main bge_main.hst
hrust13 bge_3 bge_3.hst
hrust13 bge_6 bge_6.hst
hrust13 bge_7 bge_7.hst

sjasmplus --color=off --dos866 loader.asm 2>> bge_RU.log

del bge_RU.trd
ren bge_xxx.trd bge_RU.trd
