home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Compute! Gazette 1985 October
/
1985-10.d64
/
atomshoot
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-09-20
|
2KB
|
82 lines
10 a=rnd(-ti):poke0,99:poke37154,127
20 poke36879,8:poke36878,15:dima%(9,9):z=128
30 r=4:c=4:r1=4:c1=4:g=87:h=6:e=7725:f=38445
40 fora=1to5
50 b=int(rnd(1)*8)+1:o=int(rnd(1)*8)+1
60 ifa%(b,o)then50
70 a%(b,o)=1:next:print"[147]beams:"v" low:"peek(0)
80 print"[213][192][178][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][178][192][201]
90 [153]"(NULL)(NULL)(NULL)"[163]18)"(NULL)(NULL)(NULL)
100 print"[171][192][219][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][219][192][179]
110 [129]a[178]1[164]8:[153]"(NULL)(NULL)(NULL)close(NULL)close(NULL)close(NULL)close(NULL)close(NULL)close(NULL)close(NULL)(NULL)(NULL)
120 print"[221] [221]"tab(18)"[221][221]":next
130 print"[145][171][192][219][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][219][192][179]
140 [153]"(NULL)(NULL)(NULL)"[163]18)"(NULL)(NULL)(NULL)
150 print"[202][192][177][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][177][192][203]
160 [139]l[167]660
170 [153]"clr wait hit wait miss sys wait refl
180 p=peek(37152)and128:ifp=0thenc=c+1
190 p=peek(37151)
200 if(pand8)=0thenr=r+1
210 if(pand16)=0thenc=c-1
220 if(pand4)=0thenr=r-1
230 ifr<0thenr=0
240 ifr>9thenr=9
250 ifc<0thenc=0
260 ifc>9thenc=9
270 d=e+44*r+c+c
280 pokee+44*r1+c1+c1,g:pokef+44*r1+c1+c1,h
290 r1=r:c1=c:g=peek(d):h=peek(f+44*r+c+c)
300 pokee+44*r+c+c,43:pokef+44*r+c+c,5
310 if(pand32)then180
320 ifg=32then470
330 ifg=81then780
340 ifg<>87then180
350 g=81:h=1:a=240:gosub810
360 i=i+1:ifa%(r,c)thenl=l+1
370 poked,81:poked+30720,1
380 ifi<5then180
390 ifl<5then660
400 print" you got it! [145]"
410 fora=1to10
420 forb=250to240step-1:poke36876,b:next
430 forb=240to250:poke36876,b:next
440 next:poke36876,0
450 ifpeek(0)>vthenpoke0,v
460 goto750
470 a=225:gosub810
480 p=r:q=c:dr=0:dc=0:t=0:ti$="000000":v=v+1:print""v
490 ifr=0thendr=1
500 ifr=9thendr=-1
510 ifc=0thendc=1
520 ifc=9thendc=-1
530 goto560
540 ifp>0andp<9andq>0andq<9then560
550 z=z+1:g=z:h=2:gosub640:u=44*p+q+q:pokee+u,g:pokef+u,h:goto280
560 rr=p+dr:cc=q+dc
570 ifa%(rr,cc)=1theng=160:h=4:gosub640:goto280
580 ifdrthenn=1:m=0:goto600
590 m=1:n=0
600 s=0:ifa%(rr+m,cc+n)=1thendr=-m:dc=-n:s=1
610 ifa%(rr-m,cc-n)=1thendr=m:dc=n:s=s+1
620 ifs=2or(sandt=0)theng=160:h=7:gosub640:goto280
630 p=p+dr:q=q+dc:t=1:goto540
640 ifti<60then640
650 return
660 print" you missed it [145]"
670 fora=1to20
680 forb=220-ato160-astep-8:poke36876,b:next
690 forb=160-ato220-astep8:poke36876,b:next
700 next:poke36876,0
710 forr=1to8:forc=1to8
720 g=87:h=6:ifa%(r,c)theng=81:h=1
730 pokee+44*r+c+c,g:pokef+44*r+c+c,h
740 next:next
750 print" hit fire button[145]"
760 if(peek(37151)and32)then760
770 run20
780 g=87:h=6:a=235:gosub810
790 i=i-1:ifa%(r,c)thenl=l-1
800 goto180
810 poke36876,a:fora=0to99:next:poke36876,0:return