set kernel_options player1colors c=60 : d=64 e=80 : f=64 g=80 : h=48 i=60 : j=81 test b=b+1 if !a{0} then a{0}=1 : goto test_a else a{0}=0 : goto test_b test_a player1color: 0 12 26 26 242 242 14 26 26 26 26 26 26 26 end if a{2} then REFP1=8 else REFP1=0 if !a{3} && !a{4} then player1: %00100100 %00100100 %00100100 %00100100 %01111110 %01111110 %01111110 %11111111 %01111110 %01100110 %01011010 %01111110 %01011010 %01111110 end if !a{3} && a{6} then player1: %11000110 %01000100 %00101000 %00010000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %11111000 %00111000 %00111000 end if a{3} && a{6} then player1: %11000110 %01000100 %00101000 %00010000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %11111000 %00111000 %00111000 end if a{3} && k<3 && !a{6} then player1: %00110000 %00010000 %00010000 %00010000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %11111000 %00111000 %00111000 end if a{3} && k>2 && !a{6} then player1: %11011000 %01001000 %01001000 %00101000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %00111000 %11111000 %00111000 %00111000 end if b<15 then player0: %10101000 %10101000 %01010100 %01010100 %00111000 %01011100 %01110100 %00111000 end if b>14 then player0: %00101010 %00101010 %01010100 %01010100 %00111000 %01011100 %01110100 %00111000 end goto main test_b player1color: 104 104 104 104 104 104 104 104 end if b<15 then player0: %10101000 %10101000 %01010100 %01010100 %00111000 %01011100 %01110100 %00111000 end if b>14 then player0: %00101010 %00101010 %01010100 %01010100 %00111000 %01011100 %01110100 %00111000 end if b<15 then player1: %10101000 %10101000 %01010100 %01010100 %00111000 %01011100 %01110100 %00111000 end if b>14 then player1: %00101010 %00101010 %01010100 %01010100 %00111000 %01011100 %01110100 %00111000 end player1color: 104 104 104 104 104 104 104 104 end main rem a{1} = left rem a{2} = right rem a{3}, k = walking animation rem n, o = temporary variable for score display ballheight=6 pfhline 0 10 31 on b=b+1 : COLUBK=144 : COLUPF=198 : scorecolor=14 : NUSIZ0=$20 if b>30 then b=0 if a{0} then player0x=g : player0y=h : player1x=i : player1y=j if !a{0} then player0x=c : player0y=d : player1x=e : player1y=f drawscreen if joy0fire && !a{4} && !a{5} then a{4}=1 : a{6}=1 if a{4} then l=l+1 : j=j-1 if a{4} && l>30 then l=0 : a{4}=0 : a{5}=1 if a{4} && !joy0fire then l=0 : a{4}=0 : a{5}=1 if a{5} then j=j+1 if a{5} && j=81 then a{5}=0 : a{6}=0 if a{6} then bally=j-7 : missile0y=j-11 if a{2} && !joy0right && !a{3} && !a{6} then ballx=i+9 : bally=j-7 : missile0x=i+6 : missile0y=j-11 if !a{1} && !a{2} && !a{3} && !a{6} then ballx=i : bally=j-7 : missile0x=i : missile0y=j-11 if a{6} && joy0left then ballx=i+3 : missile0x=i if a{6} && !a{1} && !a{2} then ballx=i+4 : missile0x=i+4 if a{6} && a{2} then ballx=i+5 : missile0x=i+2 if a{2} && joy0right && i<136 then ballx=i+6 : missile0x=i+3 if a{1} && i>19 then ballx=i+3 : missile0x=i+3 if !joy0right then a{1}=0 : a{3}=0 missile0height=6 : missile0height=2 : COLUP0=104 if joy0left && i>20 then a{1}=1 : a{2}=0 : i=i-1 : a{3}=1 : k=k+1 if joy0right && i<136 then a{1}=0 : a{2}=1 : i=i+1 : a{3}=1 : k=k+1 if k>4 then k=0 n=n+1 if n>60 then n=0 : score=score+1 : o=o+1 if o>9 then o=0 : score=0 goto test