set CA_DIR="%~dp0"..\
set CA_COM="BKTurbo8.exe"
set CA_B2O="BKbin2obj.exe"

set ASSEMBLER=%CA_DIR%%CA_COM%
set BIN2OBJ=%CA_DIR%%CA_B2O%

%ASSEMBLER% -l co xenon_loader_s.asm
ren xenon_loader_s.bin XENON.bin


%BIN2OBJ% -sbin -lPlay1 -fPlay1End Play1.dat
%BIN2OBJ% -sbin -lPlay2 -fPlay2End Play2.dat
%BIN2OBJ% -sbin -lOutPicture -fOutPictureEnd OutPicture.dat
%BIN2OBJ% -sbin -lGamePanel -fGamePanelEnd GamePanel.dat

%ASSEMBLER% cl xenon_gm1_part1.asm
%ASSEMBLER% -l cl xenon_gm1_part2.asm
%ASSEMBLER% -l li XENON.GM1 xenon_gm1_part1.obj Play1.obj Play2.obj OutPicture.obj GamePanel.obj xenon_gm1_part2.obj


%ASSEMBLER% -l -r co xenon_game_orig.asm
%BIN2OBJ% -sbin xenon_game_orig.raw
del xenon_game_orig.raw
%ASSEMBLER% -s01000 li XENON.GM2 xenon_game_orig.obj


md out
copy *.bin out\*
copy *.lst out\*

del *.bin
del *.obj
del *.lst
