
	TITL	CHESS GAME SOURCE LISTING
*
B22	EQU	H'22'
B8A	EQU	H'8A'
B286	EQU	H'286'
I2B4	EQU	H'2B4'
S1820	EQU	H'1820'
S1821	EQU	H'1821'
S1B00	EQU	H'1B00'
S1C00	EQU	H'1C00'
S1D00	EQU	H'1D00'
S1E00	EQU	H'1E00'
S1F00	EQU	H'1F00'
WDOS	EQU	H'6893'
I7800	EQU	H'7800'
I7B1E	EQU	H'7B1E'
I7BC0	EQU	H'7BC0'
I8000	EQU	H'8000'
*
	ORG	H'440'
*
M440	DATA	H'F7,F5,B,9,A,F6,1,FF'	________
	DATA	H'EB,F4,8,13,15,C,F8,ED'	________
	DATA	H'F6,F6,F5,F7,A,A,B,9'	________
M458	DATA	H'13,F,7,FF,3,FF,FF'	_______
M45F	DATA	H'4,4,8,4,4,8'	______
M465	DATA	H'8,1,3,3,5,9,A'	_______
M46C	DATA	H'4,2,3,5,6,3,2,4'	________
S474	RES	1
	DATA	H'FF,FF,FF,FF,FF,FF,FF,FF'	________
	DATA	H'FF,FF,FF,FF,FF,FF,FF,FF'	________
	DATA	H'FF,FF,FF,FF'	____
S489	RES	1
	DATA	H'0,0,0,0,83,0,84,FF'	________
	DATA	H'FF'	_
S493	RES	1
	DATA	H'81,81,0,81,8E,81,81,FF'	________
	DATA	H'FF'	_
S49D	RES	1
	DATA	H'0,0,0,0,0,0,0,FF'	________
	DATA	H'FF'	_
S4A7	RES	1
	DATA	H'0,0,0,0,0,0,0,FF'	________
	DATA	H'FF'	_
S4B1	RES	1
	DATA	H'0,9,0,0,0,0,0,FF'	________
	DATA	H'FF'	_
S4BB	RES	1
	DATA	H'8A,0,0,0,9,9,0,FF'	________
	DATA	H'FF'	_
S4C5	RES	1
	DATA	H'0,0,8D,0,0,0,1,FF'	________
	DATA	H'FF'	_
S4CF	RES	1
	DATA	H'C,0,E,0,0,0,4,FF'	________
	DATA	H'FF,FF,FF,FF,FF,FF,FF,FF'	________
	DATA	H'FF,FF,FF,FF,FF,FF,FF,FF'	________
	DATA	H'FF,FF,FF,FF'	____
S4EC	RES	1
	DATA	H'0,0,0,0,0,0,0,5'	________
	DATA	H'0,0,0,0,0'	_____
S4FA	RES	1
	DATA	H'0,0,0,0,0,0,0,0'	________
	DATA	H'0,0,0,0,0'	_____
S508	RES	1
	DATA	H'24'	$
S50A	RES	1
	DATA	H'54,F2,B2'	T__
S50E	RES	1
S50F	RES	1
	DATA	H'1,0,0,0,0,0,0,0'	________
	DATA	H'0'	_
S519	RES	1
	DATA	H'1,25,2F,3F,44,5D,5E,65'	_%/?D]^e
	DATA	H'89,A1,B0,C2,D7,D7,FC,FC'	________
	DATA	H'FE,FE,FB,B2,52,FA,5,5'	____R___
	DATA	H'B2,B4,B3,B2,BA,B6,50,62'	______Pb
	DATA	H'53,9A,5,C2,52,82,B2,B2'	S___R___
S542	RES	1
S543	RES	1
S544	RES	1
	DATA	H'B2'	_
S546	RES	1
S547	RES	1
S548	RES	1
S549	RES	1
S54A	RES	1
S54B	RES	1
S54C	RES	1
S54D	RES	1
S54E	RES	1
S54F	RES	1
S550	RES	1
S551	RES	1
S552	RES	1
S553	RES	1
M554	DATA	H'9'	_
S555	RES	1
S556	RES	1
S557	RES	1
S558	RES	1
S559	RES	1
S55A	RES	1
S55B	RES	1
S55C	RES	1
S55D	RES	1
S55E	RES	1
S55F	RES	1
S560	RES	1
S561	RES	1
S562	RES	1
S563	RES	1
S564	RES	1
S565	RES	1
S566	RES	1
S567	RES	1
S568	RES	1
S569	RES	1
M56A	DATA	H'55,41,10,54,40,10,23,37'	UA_T@_#7
	DATA	H'10,22,36,10'	_"6_
M576	DATA	H'78'	x
M577	DATA	H'7C'	|
A578	ACON	I8000
A57A	ACON	I8000
A57C	ACON	I7B1E
A57E	ACON	I7800
A580	ACON	I7BC0
	DATA	H'0,80,40,0,0,3B,37,0'	__@__;7_
	DATA	H'30,BC,FC,50,38,3F,3F,11'	0__P8??_
	DATA	H'80,F8,D0,0,20,3B,31,0'	____ ;1_
	DATA	H'28,F8,F4,14,20,3F,3F,10'	(___ ??_
	DATA	H'F4,C0,E0,54,32,3F,37,10'	___T2?7_
	DATA	H'D0,EE,C4,50,33,3F,37,11'	___P3?7_
	DATA	H'0,80,40,0,0,39,36,0'	__@__96_
	DATA	H'30,9C,2C,50,38,37,38,11'	0_,P878_
	DATA	H'80,18,90,0,20,39,31,0'	____ 91_
	DATA	H'28,78,B4,14,20,35,3A,10'	(x__ 5:_
	DATA	H'F4,C0,E0,54,32,34,36,10'	___T246_
	DATA	H'D0,6E,C4,50,33,35,37'	_n_P357
M5E1	DATA	H'11,57,65,6C,63,6F,6D,65'	_Welcome
	DATA	H'20,74,6F,20,43,48,45,53'	 to CHES
	DATA	H'53,21,20,43,61,72,65,20'	S! Care 
	DATA	H'66,6F,72,20,61,20,67,61'	for a ga
	DATA	H'6D,65,3F,20,28,59,20,6F'	me? (Y o
	DATA	H'72,20,4E,29,20,0,57,6F'	r N) _Wo
	DATA	H'75,6C,64,20,79,6F,75,20'	uld you 
	DATA	H'6C,69,6B,65,20,74,6F,20'	like to 
	DATA	H'61,6E,61,6C,79,7A,65,20'	analyze 
	DATA	H'61,20,70,6F,73,69,74,69'	a positi
	DATA	H'6F,6E,3F,20,28,59,20,6F'	on? (Y o
	DATA	H'72,20,4E,29,20,0,44,6F'	r N) _Do
	DATA	H'20,79,6F,75,20,77,61,6E'	 you wan
	DATA	H'74,20,74,6F,20,70,6C,61'	t to pla
	DATA	H'79,20,77,68,69,74,65,20'	y white 
	DATA	H'6F,72,20,62,6C,61,63,6B'	or black
	DATA	H'3F,20,28,57,20,6F,72,20'	? (W or 
	DATA	H'42,29,20,0,43,61,72,65'	B) _Care
	DATA	H'20,66,6F,72,20,61,6E,6F'	 for ano
	DATA	H'74,68,65,72,20,67,61,6D'	ther gam
	DATA	H'65,3F,20,28,59,20,6F,72'	e? (Y or
	DATA	H'20,4E,29,20,0,53,65,6C'	 N) _Sel
	DATA	H'65,63,74,20,6C,6F,6F,6B'	ect look
	DATA	H'20,61,68,65,61,64,20,28'	 ahead (
	DATA	H'31,2D,36,29,20,0,57,68'	1-6) _Wh
	DATA	H'6F,73,65,20,6D,6F,76,65'	ose move
	DATA	H'20,69,73,20,69,74,3F,20'	 is it? 
	DATA	H'28,57,20,6F,72,20,42,29'	(W or B)
M6C1	DATA	H'0'	_
M6C2	DATA	H'20,32,36,35,30,20'	 2650 
M6C8	DATA	H'20,50,4C,59,52,20'	 PLYR 
S6CE	RES	1
S6CF	RES	1
	DATA	H'2D'	-
S6D1	RES	1
S6D2	RES	1
	DATA	H'20,0,20,4F,2D,4F,20,20'	 _ O-O  
	DATA	H'0,4F,2D,4F,2D,4F,20,0'	_O-O-O _
	DATA	H'43,68,65,63,6B,20,0,43'	Check _C
	DATA	H'68,65,63,6B,6D,61,74,65'	heckmate
	DATA	H'0,4D,61,74,65,20,69,6E'	_Mate in
	DATA	H'20'	 
S6FC	RES	1
	DATA	H'0,59,6F,75,20,77,69,6E'	_You win
	DATA	H'0,49,20,77,69,6E,0,20'	_I win_ 
	DATA	H'49,73,20,74,68,69,73,0'	Is this_
	DATA	H'20,20,72,69,67,68,74,3F'	  right?
	DATA	H'20,0'	 _
S71F	RES	1
	DATA	H'50,4C,59,52,20'	PLYR 
S725	RES	1
	DATA	H'32,36,35,30,20,0,50,78'	2650 _Px
	DATA	H'50,65,70,20,0,49,6E,76'	Pep _Inv
	DATA	H'61,6C,69,64,20,6D,6F,76'	alid mov
	DATA	H'65,0,20,54,72,79,20,61'	e_ Try a
	DATA	H'67,61,69,6E,0,0'	gain__
A74C	ACON	B286
A74E	ACON	I2B4
M750	DATA	H'5F,19,5E,18'	__^_
M754	DATA	H'0,50,4E,42,52,51,4B,0'	_PNBRQK_
*
B75C	LODA,R0	M5E1,R1+
	RETC,EQ
	BSTA,UN	*A74E
	BCTR,UN	B75C
*
B765	LODA,R0	M6C1,R1+
	RETC,EQ
	STRA,R0	*A57E
	LODI,R0	1
	ADDR,R0	*B774+1
	STRR,R0	*B774+1
	BCTR,UN	B765
*
B774	LODA,R3	A57E+1
	ANDI,R3	H'C0'
	STRR,R3	*B774+1
	ADDI,R3	H'40'	@
	SPSL
	ANDI,R0	1
I780	ADDA,R0	A57E
I783	COMA,R0	M577
	BCFR,LT	B78D
	STRR,R3	*B774+1
	STRR,R0	*I780+1
	RETC,UN
*
B78D	LODA,R0	M576
	LODI,R2	H'40'	@
B792	STRA,R0	A580
I795	STRA,R2	A580+1
	LODI,R2	H'C'
	LODI,R3	H'4C'	L
B79C	LODA,R0	*A580,R3-
	STRA,R0	*A580,R2-
	BRNR,R2	B79C
	LODR,R2	*I795+1
	ADDI,R2	H'40'	@
	SPSL
	ANDI,R0	1
	ADDR,R0	*B792+1
	COMR,R0	*I783+1
	BCFR,EQ	B792
	LODI,R0	H'20'	 
	LODI,R2	H'C'
B7B5	STRA,R0	*A580,R2-
	BRNR,R2	B7B5
	RETC,UN
*
B7BB	EORI,R2	H'80'
	SPSU
	BCTR,LT	B7BB
	STRA,R2	S568
B7C3	BSTA,UN	*A74C
	STRZ,R1
	BSTA,UN	*A74E
I7CA	BSTA,UN	B8A
	RETC,UN

*
B7CE	BSTA,UN	*A74C
B7D1	STRA,R0	*A57E
	LODI,R1	1
I7D6	ADDA,R1	A57E+1
	STRR,R1	*I7D6+1
	RETC,UN
*
B7DC	LODI,R0	H'D'
	BSTA,UN	*A74E
	LODA,R3	M576
I7E4	STRA,R3	A578
	LODI,R0	H'20'	 
	LODI,R1	0
	LODI,R2	8
	STRA,R1	A578+1
B7F0	STRA,R0	*A578,R1-
	BRNR,R1	B7F0
	ADDI,R3	1
	STRR,R3	*I7E4+1
	BDRR,R2	B7F0
	RETC,UN
*
W7FC	DATA	H'0,0,0,0'	____
*
B800	BSTA,UN	B7DC
	EORZ,R0
	STRZ,R1
	BSTA,UN	B75C
B808	BSTA,UN	B7BB
	LODA,R0	M576
	STRA,R0	A57E
	EORZ,R0
	STRA,R0	A57E+1
	COMI,R1	H'59'	Y
	BCFA,EQ	B99F
	EORZ,R0
	STRA,R0	S551
	BSTA,UN	B851
	BSTA,UN	B899
	LODI,R0	1
I826	STRA,R0	S556
	BSTA,UN	B8D3
	LODI,R1	H'5D'	]
	BSTA,UN	B765
I831	BSTA,UN	B774
B834	LODA,R0	S550
	BRNR,R0	B843
I839	BSTA,UN	B104B
I83C	BSTA,UN	BADF
	BSTR,UN	*I831+1
	BCTR,UN	B849
*
B843	BSTR,UN	*I83C+1
	BSTR,UN	*I839+1
	BSTR,UN	*I831+1
B849	LODI,R0	1
	ADDR,R0	*I826+1
	STRR,R0	*I826+1
	BCTR,UN	B834
*
B851	PPSL	2
	LODI,R1	H'5D'	]
I855	BSTA,UN	B75C
I858	BSTA,UN	B7C3
	COMI,R1	H'57'	W
	BCTR,EQ	B86F
	EORZ,R0
I860	STRA,R0	S550
	LODI,R1	H'C'
B865	LODA,R0	M6C2,R1-
	STRA,R0	S71F,R1
	BRNR,R1	B865
	BCTR,UN	B883
*
B86F	LODI,R0	H'80'
	STRR,R0	*I860+1
	LODI,R1	6
B875	LODA,R0	M6C8,R1-
	STRA,R0	S71F,R1
	LODA,R0	M6C2,R1
	STRA,R0	S725,R1
	BRNR,R1	B875
B883	LODI,R1	H'AC'
	BSTR,UN	*I855+1
	BSTR,UN	*I858+1
B889	LODI,R0	2
I88B	STRA,R0	S557
	COMI,R1	H'31'	1
	RETC,LT
	COMI,R1	H'39'	9
	RETC,GT
	SUBI,R1	H'30'	0
	STRR,R1	*I88B+1
	RETC,UN
*
B899	LODI,R1	H'78'	x
	LODI,R0	H'FF'
B89D	STRA,R0	S474,R1-
	BRNR,R1	B89D
	LODI,R1	8
B8A4	LODA,R0	M46C,R1-
	STRA,R0	S4CF,R1
	IORI,R0	H'80'
	STRA,R0	S489,R1
	LODI,R0	1
	STRA,R0	S4C5,R1
	LODI,R0	H'81'
	STRA,R0	S493,R1
	EORZ,R0
	STRA,R0	S49D,R1
	STRA,R0	S4A7,R1
	STRA,R0	S4B1,R1
	STRA,R0	S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R0	S550
	EORI,R0	H'80'
	STRA,R0	S551
	EORZ,R0
	STRA,R0	S549
	LODI,R0	H'80'
	STRA,R0	S54F
	BSTA,UN	BB90
	LODI,R1	H'80'
BB62	LODA,R0	S6CE
	COMA,R0	S1C00,R1
	BCFR,EQ	BB72
	LODA,R0	S6CF
	COMA,R0	S1D00,R1
	BCTR,EQ	BB7A
BB72	LODA,R0	S1B00,R1
	BCTR,EQ	BB88
	STRZ,R1
	BCTR,UN	BB62
*
BB7A	STRA,R1	S54A
	BSTA,UN	BCCD
	BSTA,UN	BDC0
	ADDZ,R0
	RETC,EQ
	BSTA,UN	BDD9
BB88	LODR,R0	*IB49+1
	STRA,R0	S54A
	BCTA,UN	BB0D
*
BB90	BSTA,UN	BDC0
	STRA,R0	S559
	LODA,R0	S54F
	LODA,R2	S549
	STRA,R0	S519,R2+
	STRA,R0	S519,R2+
	STRA,R2	S549
	STRA,R0	S54E
	LODI,R1	H'15'
BBAA	STRA,R1	S542
	LODA,R0	S474,R1
	BCTR,EQ	BBBE
	COMI,R0	H'FF'
	BCTR,EQ	BBBE
	STRA,R0	S552
	EORA,R0	S551
	BSFR,LT	BBC7
BBBE	LODR,R1	*BBAA+1
	ADDI,R1	1
	COMI,R1	H'63'	c
	RETC,EQ
	BCTR,UN	BBAA
*
BBC7	LODA,R1	S552
	ANDI,R1	H'87'
	COMI,R1	H'81'
	BCFR,EQ	BBD2
	SUBI,R1	1
BBD2	ANDI,R1	7
	STRA,R1	S546
	LODA,R0	M45F,R1
	STRZ,R2
	LODA,R0	M458,R1
BBDE	PPSL	H'10'
	STRZ,R3
	LODA,R0	M440,R3+
	STRZ,R1
	LODA,R0	S542
	STRA,R0	S543
BBEB	BSTA,UN	BC57
	COMI,R2	2
	BCFR,LT	BC09
	LODA,R0	S546
	COMI,R0	2
	BCTR,LT	BC17
	BSTA,UN	BC7C
	BRNR,R2	BC09
	LODA,R0	S546
	COMI,R0	6
	BCTR,EQ	BC09
	COMI,R0	2
	BCTR,GT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'10'
	BSTA,UN	BE4A
	PPSL	H'10'
	BRNR,R0	B1022
BFF7	LODZ,R3
BFF8	ADDZ,R1
	STRZ,R3
	COMA,R0	S542
	BCFR,EQ	BFDE
	SUBZ,R1
	SUBZ,R1
	STRA,R0	S543
	LODI,R0	H'40'	@
	STRA,R0	S553
	BSTA,UN	BC7C
	LODA,R0	S542
	STRA,R2	S542
	SUBZ,R1
	STRA,R0	S543
	EORZ,R0
	STRA,R0	S553
	BSTA,UN	BC7C
	BSTR,UN	B1030
	STRA,R3	S542
B1022	COMI,R1	1
	CPSL	H'10'
	RETC,EQ
	PPSL	H'10'
	LODI,R1	1
	LODI,R2	H'FC'
	BCTA,UN	BFCE
*
B1030	LODA,R2	S54E
	SUBI,R2	1
	STRA,R2	S54E
	EORZ,R0
	STRA,R0	S1B00,R2
	RETC,UN
*
B103D	LODA,R0	S550
	RETC,EQ
I1041	LODA,R0	A57E+1
	ANDI,R0	H'C0'
	IORI,R0	6
	STRR,R0	*I1041+1
	RETC,UN
*
B104B	BSTA,UN	B10D2
	LODA,R0	S54D
	STRA,R0	S54A
	LODA,R0	S50F
	COMI,R0	1
	BCFA,EQ	B16AB
	LODI,R1	1
	BSTA,UN	B1388
B1061	BSTA,UN	BCCD
	BSTA,UN	BD36
	BRNR,R1	B1083
I1069	BSTA,UN	B10C4
	STRA,R3	S6CE
	STRA,R0	S6CF
	LODZ,R2
	STRZ,R3
	BSTR,UN	*I1069+1
	STRA,R3	S6D1
	STRA,R0	S6D2
	LODI,R1	H'C'
	BSTA,UN	B765
	BCTR,UN	B109D
*
B1083	TMI,R1	2
	BCFR,EQ	B108E
	LODI,R1	H'13'
	BSTA,UN	B765
	BCTR,UN	B109D
*
B108E	TMI,R1	4
	BCFR,EQ	B1099
	LODI,R1	H'1A'
I1094	BSTA,UN	B765
	BCTR,UN	B109D
*
B1099	LODI,R1	H'6A'	j
	BSTR,UN	*I1094+1
B109D	LODA,R0	S551
	EORI,R0	H'80'
	BSTA,UN	BDC3
	ADDZ,R0
	BCTR,EQ	B10B8
	BSTA,UN	B774
	LODA,R0	S50F
	COMI,R0	H'FF'
	BSFA,EQ	B103D
	LODI,R1	H'21'	!
	BSTA,UN	B765
B10B8	LODA,R0	S50F
	COMI,R0	H'FF'
	RETC,GT
	RETC,LT
	LODI,R1	0
	BCTA,UN	B1388
*
B10C4	LODI,R1	H'FF'
B10C6	ADDI,R1	1
	SUBI,R3	H'A'
	BCFR,LT	B10C6
	ADDI,R3	H'4A'	J
	LODI,R0	H'3A'	:
	SUBZ,R1
	RETC,UN
*
B10D2	LODA,R0	S556
	COMI,R0	1
	BCTA,EQ	B122B
	EORZ,R0
	STRA,R0	S558
	STRA,R0	S54D
	STRA,R0	S549
	STRA,R0	S54C
	LODA,R1	S557
	ADDI,R1	2
B10EC	STRA,R0	S50E,R1-
	BRNR,R1	B10EC
	STRA,R0	S561
	STRA,R0	S562
	STRA,R0	S569
	LODI,R0	1
	STRA,R0	S54F
	LODA,R0	S550
	STRA,R0	S551
	BSTA,UN	B13DA
	LODA,R0	S55C
	STRA,R0	S561
	LODA,R0	S560
	STRA,R0	S562
B1114	LODA,R0	S558
	ADDI,R0	1
	STRA,R0	S558
	EORZ,R0
	STRA,R0	S55A
	BSTA,UN	BB90
	LODA,R0	S558
	COMA,R0	S557
	BSTA,LT	B1275
	LODA,R0	S549
	LODA,R0	S519,R0
	BCTR,UN	B113A
*
B1134	LODA,R0	S54A
	LODA,R0	S1B00,R0
B113A	BCTA,EQ	B11A6
	STRA,R0	S54A
	LODA,R1	S549
	STRA,R0	S519,R1
	LODA,R0	S558
	COMA,R0	S557
	BCTR,LT	B1172
	BSTA,UN	BCCD
	BSTA,UN	BDC0
	ADDZ,R0
	BCTR,EQ	B115C
	BSTA,UN	BDD9
	BCTR,UN	B1134
*
B115C	LODA,R0	S558
	COMA,R0	S557
	BCFA,EQ	B11D1
	LODA,R0	S551
	EORI,R0	H'80'
	BSTA,UN	BDC3
	BRNR,R0	B117E
	BCTA,UN	B11D1
*
B1172	LODA,R0	S54A
	LODA,R0	S1F00,R0
	BCTA,EQ	B1134
	BSTA,UN	BCCD
B117E	LODA,R0	S551
	EORI,R0	H'80'
	STRA,R0	S551
	BCTR,LT	B1190
	LODA,R0	S556
	ADDI,R0	1
	STRA,R0	S556
B1190	LODA,R1	S54C
	LODA,R0	S50E,R1
	ADDI,R1	1
	STRA,R1	S54C
	STRA,R0	S50E,R1+
	LODI,R0	H'FF'
I11A0	STRA,R0	S569
	BCTA,UN	B1114
*
B11A6	LODA,R0	S55A
	BCFR,EQ	B11BC
	LODI,R0	H'80'
	LODA,R1	S559
	BCTR,EQ	B11DE
	LODA,R0	S556
	STRA,R0	S555
	LODI,R0	H'FF'
	BCTR,UN	B11DE
*
B11BC	LODA,R0	S558
	COMI,R0	1
	RETC,EQ
	BSTA,UN	B1350
	LODA,R1	S54C
	ADDI,R1	2
	LODA,R0	S50E,R1
	SUBI,R1	2
	BCTR,UN	B11E9
*
B11D1	LODI,R1	H'FF'
	STRR,R1	*I11A0+1
	BSTA,UN	B13DA
	BSTA,UN	BDD9
	LODA,R0	S55B
B11DE	LODA,R1	S55A
	IORI,R1	1
	STRA,R1	S55A
	LODA,R1	S54C
B11E9	COMA,R0	S50E,R1
	BCFR,GT	B1225
	STRZ,R2
	EORZ,R0
	SUBZ,R2
	COMA,R0	S50E,R1+
	BCFA,GT	B1134
	STRA,R0	S50E,R1
	LODA,R0	S558
	COMI,R0	1
	BCFA,EQ	B1134
	LODA,R0	S54A
	STRA,R0	S54D
	LODA,R0	S50F
	COMI,R0	H'FF'
	BCFA,EQ	B1134
	LODA,R0	S557
	SUBI,R0	2
	STRA,R0	S557
	LODA,R0	S550
	RETC,EQ
	LODA,R0	S555
	SUBI,R0	1
	STRA,R0	S555
	RETC,UN
*
B1225	BSTA,UN	B1350
	BCTA,UN	B1134
*
B122B	LODI,R0	H'FF'
	STRA,R0	S569
	EORZ,R0
	STRZ,R3
	STRA,R0	S50F
	STRA,R0	S54D
	LODA,R0	S550
	BCTR,LT	B1246
	LODA,R0	S568
	BCTR,LT	B1262
	LODI,R3	3
	BCTR,UN	B1262
*
B1246	LODI,R3	6
	LODA,R0	S54A
	LODA,R0	S1C00,R0
	COMI,R0	H'5C'	\
	BCTR,EQ	B1260
	COMI,R0	H'61'	a
	BCTR,EQ	B1260
	COMI,R0	H'54'	T
	BCTR,EQ	B1260
	BCTR,LT	B1262
	COMI,R0	H'55'	U
	BCTR,EQ	B1262
B1260	LODI,R3	9
B1262	LODA,R0	M56A,R3
	STRA,R0	S1C00
	LODA,R0	M56A,R3+
	STRA,R0	S1D00
	LODA,R0	M56A,R3+
	STRA,R0	S1E00
	RETC,UN
*
B1275	LODA,R0	S549
	LODA,R0	S519,R0
	STRA,R0	S1B00
	LODI,R1	0
	LODI,R2	0
B1282	LODZ,R1
	STRZ,R3
	LODA,R0	S1B00,R3
	STRZ,R1
	LODZ,R2
	STRA,R0	S1B00,R3
	BRNR,R1	B1298
	LODA,R0	S1B00
	LODA,R1	S549
	STRA,R0	S519,R1
	RETC,UN
*
B1298	STRA,R1	S54A
	BSTR,UN	B12BA
	LODI,R3	0
	LODA,R1	S54A
B12A2	LODA,R0	S1B00,R3
	STRZ,R2
	BCTR,EQ	B12B0
	LODA,R0	S55B
	COMA,R0	S1F00,R2
	BCFR,LT	B12B6
B12B0	LODZ,R1
	STRA,R0	S1B00,R3
	BCTR,UN	B1282
*
B12B6	LODZ,R2
	STRZ,R3
	BCTR,UN	B12A2
*
B12BA	BSTA,UN	BCCD
	BSTA,UN	BDC0
	ADDZ,R0
	BCTR,EQ	B12CC
	EORZ,R0
	STRA,R0	S55B
	BCTR,UN	B12CF
*
W12C9	DATA	H'0,0,17'	___
*
B12CC	BSTA,UN	B13DA
B12CF	BSTA,UN	BDD9
	RETC,UN

*
B12D3	PPSL	H'10'
	LODI,R2	1
	LODI,R3	1
	CPSL	H'10'
	LODA,R2	S156C
	ANDI,R2	H'80'
	RRR,R2
	LODA,R0	S548
	LODA,R0	M465,R0
	ADDZ,R0
	STRA,R0	S565
	STRZ,R1
	BSTR,UN	B1322
	RETC,EQ
B12EF	STRZ,R3
	BSTR,UN	B1322
	BCTR,EQ	B1308
	STRA,R0	S564
	LODZ,R1
	COMZ,R3
	BCFR,LT	B130B
	LODA,R0	S564
B12FE	COMZ,R3
	RETC,LT
	BSTR,UN	B1322
	RETC,EQ
	STRZ,R3
	BSTR,UN	B1322
	BRNR,R0	B12FE
B1308	STRA,R0	S564
B130B	LODZ,R2
	BCFR,LT	B1318
	SUBZ,R1
	STRZ,R2
	LODZ,R3
	STRZ,R1
	LODA,R0	S564
	RETC,EQ
	BCTR,UN	B12EF
*
B1318	ADDZ,R1
	STRZ,R2
	LODZ,R3
	STRZ,R1
	LODA,R0	S564
	RETC,EQ
	BCTR,UN	B12EF
*
B1322	EORI,R2	H'C0'
	TMI,R2	H'40'	@
	BCTR,EQ	B133C
	LODA,R0	S4EC
	RETC,EQ
	PPSL	H'10'
	SUBI,R0	1
	STRA,R0	S4EC
B1333	LODA,R0	S4EC,R2+
	BCTR,EQ	B1333
	ADDZ,R0
	CPSL	H'10'
	RETC,UN
*
B133C	LODA,R0	S4FA
	RETC,EQ
	PPSL	H'10'
	SUBI,R0	1
	STRA,R0	S4FA
B1347	LODA,R0	S4FA,R3+
	BCTR,EQ	B1347
	ADDZ,R0
	CPSL	H'10'
	RETC,UN
*
B1350	LODA,R0	S551
	EORI,R0	H'80'
	STRA,R0	S551
	BCFR,LT	B1362
	LODA,R0	S556
	SUBI,R0	1
	STRA,R0	S556
B1362	LODA,R0	S54C
	SUBI,R0	1
	STRA,R0	S54C
	LODA,R0	S558
	SUBI,R0	1
	STRA,R0	S558
	LODA,R1	S549
	LODA,R0	S519,R1-
	STRA,R0	S54F
	LODA,R0	S519,R1-
	STRA,R1	S549
	STRA,R0	S54A
	BSTA,UN	BDD9
	RETC,UN
*
B1388	LODA,R0	S555
	SUBA,R0	S556
	BCFR,EQ	B13C1
	BRNR,R1	B13A3
I1392	LODA,R0	A57E+1
	SUBI,R0	1
	STRR,R0	*I1392+1
	LODI,R1	H'2D'	-
	BSTR,UN	*I13CE+1
	BSTR,UN	*I13C9+1
	LODI,R1	H'44'	D
	BCTR,UN	B13AD
*
B13A3	BSTR,UN	*I13C9+1
	LODI,R1	H'28'	(
	BSTR,UN	*I13CE+1
	BSTR,UN	*I13C9+1
	LODI,R1	H'3C'	<
B13AD	BSTR,UN	*I13CE+1
B13AF	SPSU
	SUBI,R0	1
	LPSU
	BSTA,UN	*A74C
B13B6	BSTA,UN	B7DC
B13B9	LODI,R1	H'8B'
	BSTA,UN	B75C
	BCTA,UN	B808
*
B13C1	COMI,R1	1
	RETC,EQ
	ADDI,R0	H'30'	0
	STRA,R0	S6FC
I13C9	BSTA,UN	B774
	LODI,R1	H'32'	2
I13CE	BSTA,UN	B765
	BSTA,UN	B774
	BSTA,UN	BDB2
	BCTA,UN	B103D
*
B13DA	EORZ,R0
	PPSL	H'10'
	LODI,R2	1
	LODI,R1	1
	CPSL	H'10'
	STRA,R0	S14A2
	STRA,R0	S1501
	STRA,R0	S55D
	STRA,R0	S55E
	STRA,R0	S55F
	STRA,R0	S560
	STRA,R0	S563
	STRA,R0	S1821
	LODI,R1	H'14'
B13FD	LODA,R0	S474,R1+
	BCTR,EQ	B13FD
	COMI,R0	H'FF'
	BCFR,EQ	B140D
	COMI,R1	H'63'	c
	BCTA,EQ	B1559
	BCTR,UN	B13FD
*
B140D	STRA,R1	S149F
	STRZ,R1
	ANDI,R0	7
	STRZ,R2
	COMI,R0	2
	BCTR,LT	B144F
	COMI,R0	4
	BCTR,LT	B143D
	COMI,R0	6
	BCTR,EQ	B1429
	LODA,R0	S556
	COMI,R0	7
	BCTR,LT	B1437
	BCTR,UN	B144F
*
B1429	TMI,R1	H'10'
	BCFR,EQ	B1437
	LODI,R0	6
	TMI,R1	H'80'
	BCFR,EQ	B1449
	LODI,R0	H'FA'
	BCTR,UN	B1449
*
B1437	TMI,R1	8
	BCFR,EQ	B144F
	BCTR,UN	B1441
*
B143D	TMI,R1	8
	BCTR,EQ	B144F
B1441	LODI,R0	H'FE'
	TMI,R1	H'80'
	BCFR,EQ	B1449
	LODI,R0	2
B1449	ADDA,R0	S1501
	STRA,R0	S1501
B144F	LODI,R3	1
	LODZ,R1
	BCFR,LT	B145C
	LODI,R3	H'FF'
	EORZ,R0
	SUBA,R0	M465,R2
	BCTR,UN	B145F
*
B145C	LODA,R0	M465,R2
B145F	ADDA,R0	S560
	STRA,R0	S560
	COMI,R2	2
	BCFA,GT	B150D
	COMI,R2	6
	BCTA,EQ	B1515
	ANDI,R1	H'80'
	STRR,R1	S14A1
	STRR,R3	S149E
	LODA,R0	M45F,R2
	STRZ,R3
	LODA,R0	M458,R2
	STRZ,R2
B147D	LODR,R1	S149F
	LODA,R0	M440,R2+
	STRR,R0	S14A0
	BCTR,UN	B148C
*
B1486	LODR,R0	S14A2
	ADDR,R0	S149E
	STRR,R0	S14A2
B148C	ADDR,R1	S14A0
	LODA,R0	S474,R1
	BCTR,EQ	B1486
	COMI,R0	H'FF'
	BCFR,EQ	B14A3
	BDRR,R3	B147D
B1499	LODR,R1	S149F
	BCTA,UN	B13FD
*
S149E	RES	1
S149F	RES	1
S14A0	RES	1
S14A1	RES	1
S14A2	RES	1
*
B14A3	EORR,R0	S14A1
	BCFR,LT	B14C4
	LODZ,R1
	PPSL	H'10'
B14AA	COMA,R0	S1820,R2
	BCTR,EQ	B14B4
	BDRR,R2	B14AA
	STRA,R0	S1820,R1+
B14B4	LODZ,R1
	STRZ,R2
	CPSL	H'10'
B14B8	LODR,R0	S14A2
B14BA	ADDR,R0	S149E
	STRR,R0	S14A2
	BDRA,R3	B147D
	BCTA,UN	B1499
*
B14C4	COMI,R2	3
	BCFR,GT	B14D6
	ANDI,R0	7
	COMI,R0	5
	BCTA,EQ	B1486
	COMI,R0	4
	BCTA,EQ	B1486
	BCTR,UN	B14B8
*
B14D6	RRR,R0
	BCFR,LT	B14B8
	ANDI,R0	3
	BCFA,EQ	B1486
	LODA,R0	S474,R1
	BCTR,LT	B14F9
	COMI,R2	2
	BCFR,LT	B14B8
B14E7	ADDA,R1	S14A0
	LODA,R0	S474,R1
	COMI,R0	H'FF'
	BCTR,EQ	B14B8
	LODA,R0	S14A2
	ADDA,R0	S149E
	BCTR,UN	B14BA

*
B14F9	COMI,R2	1
	BCFA,GT	B14B8
	BCTR,UN	B14E7
*
S1500	RES	1
S1501	RES	1
*
B1502	LODR,R0	S1501
	ADDR,R0	S1500
	STRR,R0	S1501
B1508	BDRR,R3	B1522
	BCTA,UN	B13FD
*
B150D	BCTR,EQ	B1515
	ANDI,R1	H'80'
	BCFR,LT	B1515
	LODI,R2	0
B1515	STRR,R3	S1500
	LODA,R0	M1552,R2
	STRZ,R3
	LODA,R0	M154B,R2
	STRZ,R2
	LODA,R1	S149F
B1522	LODZ,R1
	ADDA,R0	M440,R2+
	LODA,R0	S474,R0
	BCTR,EQ	B1502
	COMI,R0	H'FF'
	BCTR,EQ	B1508
	EORA,R0	S474,R1
	BCFR,LT	B1502
	LODA,R0	M440,R2
	ADDZ,R1
	PPSL	H'10'
B153A	COMA,R0	S1820,R2
	BCTR,EQ	B1544
	BDRR,R2	B153A
	STRA,R0	S1820,R1+
B1544	LODZ,R1
	STRZ,R2
	CPSL	H'10'
	BCTA,UN	B1502
*
M154B	DATA	H'15,11,7,0,0,0,FF'	_______
M1552	DATA	H'2,2,8,0,0,0,8'	_______
*
B1559	LODA,R0	S14A2
	ADDA,R0	S1501
	STRA,R0	S55C
	LODA,R0	S560
	ADDZ,R0
	STRA,R0	S560
	BCTA,UN	B15D3
*
S156C	RES	1
*
B156D	LODA,R0	S1821,R1
	CPSL	H'10'
	STRA,R0	SEBA
	LODA,R0	S474,R0
	STRR,R0	S156C
	ANDI,R0	7
	STRA,R0	S548
	EORZ,R0
	LODI,R1	H'1C'
B1582	STRA,R0	S4EC,R1-
	BRNR,R1	B1582
	BSTA,UN	BEBC
	BSTA,UN	B12D3
	ANDI,R2	H'3F'	?
	BCTA,EQ	B15D3
	LODI,R0	1
	LODR,R1	S156C
	BCTR,LT	B159A
	LODI,R0	H'FF'
B159A	ADDA,R0	S560
	STRA,R0	S560
	LODR,R0	S156C
	EORA,R0	S551
	BCTR,LT	B15BF
	COMA,R2	S55D
	BCTR,LT	B15D3
	STRA,R2	S55D
	LODA,R3	S54A
	LODA,R0	SEBA
	COMA,R0	S1D00,R3
	BCFR,EQ	B15D3
	STRA,R0	S563
	BCTR,UN	B15D3
*
B15BF	LODZ,R2
	COMA,R2	S55E
	BCTR,LT	B15CB
	LODA,R0	S55E
	STRA,R2	S55E
B15CB	COMA,R0	S55F
	BCTR,LT	B15D3
	STRA,R0	S55F
B15D3	PPSL	H'10'
	BDRA,R1	B156D
	CPSL	H'10'
	LODA,R0	S563
	BCTR,EQ	B15E9
	LODA,R0	S55F
	STRA,R0	S55E
	EORZ,R0
	STRA,R0	S55F
B15E9	LODA,R1	S55D
	BCTR,EQ	B15F0
	SUBI,R1	1
B15F0	LODA,R0	S55E
	BCTR,EQ	B15FF
	LODA,R0	S55F
	BCTR,EQ	B15FF
	SUBI,R0	1
	ANDI,R0	H'FE'
	RRR,R0
B15FF	SUBZ,R1
	LODA,R1	S551
	BCFR,LT	B1608
	STRZ,R1
	EORZ,R0
	SUBZ,R1
B1608	ADDA,R0	S560
	SUBA,R0	S562
	STRZ,R1
	BCTR,LT	B1619
	LODI,R0	H'1E'
	COMZ,R1
	BCTR,LT	B161F
	LODZ,R1
	BCTR,UN	B161F
*
B1619	LODI,R0	H'E2'
	COMZ,R1
	BCTR,GT	B161F
	LODZ,R1
B161F	ADDZ,R0
	ADDZ,R0
	STRZ,R2
	LODA,R1	S55C
	SUBA,R1	S561
	LODA,R0	S563
	BCTR,EQ	B162F
	LODI,R1	0
B162F	LODZ,R1
	BCTR,LT	B163A
	LODI,R0	6
	COMZ,R1
	BCTR,LT	B1640
	LODZ,R1
	BCTR,UN	B1640
*
B163A	LODI,R0	H'FA'
	COMZ,R1
	BCTR,GT	B1640
	LODZ,R1
B1640	ADDZ,R2
	LODA,R1	S551
	BCTR,LT	B1649
	STRZ,R1
	EORZ,R0
	SUBZ,R1
B1649	ADDI,R0	H'80'
	STRA,R0	S55B
	LODA,R3	S54A
	STRA,R0	S1F00,R3
	RETC,UN
*
B1655	LODR,R0	*I1693+1
	LODA,R1	S552
	BCFR,LT	B165E
	SUBI,R0	H'A'
B165E	COMI,R0	H'33'	3
	BCTR,LT	*I1688+1
	COMI,R0	H'3A'	:
	BCTR,GT	*I1688+1
	LODA,R2	S54A
	LODA,R0	S1E00,R2
	ANDI,R0	H'10'
	BCTR,EQ	*I1688+1
	LODA,R0	S1D00,R2
	STRZ,R2
	LODA,R0	S474,R0
	STRR,R0	*I169B+1
	ANDI,R0	7
	COMI,R0	1
	BCFR,EQ	*I1688+1
	LODZ,R2
	SUBR,R0	*I1698+1
	COMI,R0	H'F6'
	BCTR,EQ	B168B
	COMI,R0	H'A'
I1688	BCFA,EQ	BC09
B168B	LODR,R0	*I169E+1
	IORI,R0	H'40'	@
	STRR,R0	*I169E+1
	BSTR,UN	*I16A1+1
I1693	LODA,R1	S542
	STRR,R2	*I1693+1
I1698	STRA,R2	S543
I169B	LODA,R0	M554
I169E	STRA,R0	S553
I16A1	BSTA,UN	BC7C
	STRR,R1	*I1693+1
	BSTA,UN	B1030
	BCTR,UN	*I1688+1
*
B16AB	LODA,R0	S569
	BCFA,EQ	B1061
	BSTA,UN	B774
	LODI,R1	H'FF'
B16B6	LODA,R0	M16C8,R1+
	BCTA,EQ	B13AF
	STRA,R0	*A57E
	LODI,R0	1
I16C1	ADDA,R0	A57E+1
	STRR,R0	*I16C1+1
	BCTR,UN	B16B6
*
M16C8	DATA	H'53,74,61,6C,65,6D,61,74'	Stalemat
	DATA	H'65,0'	e_
*
B16D2	SPSU
	SUBI,R0	3
	LPSU
B16D6	BSTA,UN	B1350
	LODA,R0	S558
	COMI,R0	1
	BCFR,EQ	B16D6
	BSTA,UN	B7DC
	LODI,R1	0
I16E5	BSTA,UN	B172C
	BSTA,UN	*I7CA+1
	LODI,R1	H'18'
	BSTR,UN	*I16E5+1
	BSTA,UN	B7C3
	COMI,R1	H'59'	Y
	BCFA,EQ	B13B9
	LODI,R1	H'45'	E
	BSTR,UN	*I16E5+1
	BSTA,UN	*A74C
	SUBI,R0	H'30'	0
	LODI,R1	2
	COMI,R0	1
	BCTR,LT	B170B
	COMI,R0	9
	BCTR,GT	B170B
	STRZ,R1
B170B	STRA,R1	S557
	LODA,R0	M576
	STRA,R0	A57E
	EORZ,R0
	STRA,R0	A57E+1
	BSTA,UN	B8D3
	LODI,R1	H'5D'	]
	BSTA,UN	B765
	BSTA,UN	B774
	LODA,R0	S551
	BCTA,EQ	B834
	BCTA,UN	BA7E
*
B172C	LODA,R0	I1733+1,R1+
	RETC,EQ
	BSTA,UN	*A74E
I1733	BCTR,UN	B172C
*
W1735	DATA	H'49,6E,74,65,72,6E,61,6C'	Internal
	DATA	H'20,73,74,61,63,6B,20,6F'	 stack o
	DATA	H'76,65,72,66,6C,6F,77,0'	verflow_
	DATA	H'44,6F,20,79,6F,75,20,77'	Do you w
	DATA	H'61,6E,74,20,6D,65,20,74'	ant me t
	DATA	H'6F,20,74,72,79,20,61,67'	o try ag
	DATA	H'61,69,6E,20,61,74,20,61'	ain at a
	DATA	H'20,6C,6F,77,65,72,20,70'	 lower p
	DATA	H'6C,79,3F,20,0,4E,65,77'	ly? _New
	DATA	H'20,70,6C,79,20,0'	 ply _
*
B1783	BSTA,UN	*A74C
	COMI,R0	H'50'	P
	RETC,GT
	RETC,LT
	BSTA,UN	B7D1
	BSTA,UN	B7CE
	COMI,R0	H'30'	0
	BCTR,EQ	B1798
	STRZ,R1
	BSTA,UN	B889
B1798	BSTA,UN	B774
	BSTR,UN	B17AD
	LODA,R0	S557
	ADDI,R0	H'30'	0
	BSTA,UN	B7D1
	BSTA,UN	B774
	BSTA,UN	BDB2
	BCTR,UN	B1783
*
B17AD	LODI,R1	H'FF'
B17AF	LODA,R0	M17C0,R1+
	RETC,EQ
	STRA,R0	*A57E
	LODI,R0	1
	ADDA,R0	A57E+1
	STRA,R0	A57E+1
	BCTR,UN	B17AF
*
M17C0	DATA	H'50,6C,79,20,4E,6F,20,0'	Ply No _
	DATA	H'0,0,0,0,0,0,0,0'	________
	END	B800
