Warning:I came across troubles to compile the game using latest stos version (comp v3.00 I think)
the controls didn't respond, I don't know why.
Code: Select all
10 rem Foundation Waste STOS STe beta 003 mOa 211029
20 rem check www.atari-forum.com -> coding -> stos
30 rem thanks to all the helping peole
40 rem 5: landscape blocks
50 rem 6: tilemap
60 rem 7: data screen for sprite
70 rem 8: buffer for merge blit
80 rem 10: music
90 rem 13: sample
100 dim XE(20),YE(20),SE(20) : rem ** xpos ypos & speed of enemy
110 mode 1 : hide : key off : click off : auto back off : update off : synchro off : curs off
120 centre "FOUNDATION WASTE OF TIME" : print
130 centre "STEem STe STOS version" : print
140 centre "BETA 003 / Nov 2021 by mOa" : print
150 centre "Check www.atari-forum.com -> coding -> stos" : print
160 print : print
170 centre "WARNING: This game is a Work in Progress"
180 print : print
190 centre " WARNING: This game is not meant to work on real hardware" : print
200 centre " For optimal experience, please use STEem emulator" : print
210 centre " (sourceforge.net/projects/steemsse)" : print : print
220 centre "Select a ATARI STE model with FAST BLITT option ON" : print
230 centre "You can alter the numbers of enemies with 0 and . on the numpad" : print : print
240 centre "Thank you to all helping people"
250 print : print : print : print : print : print
260 centre "Press space to play"
270 repeat : until inkey$=" "
280 mode 0 : key off : mouseoff : click off : auto back off : update off : synchro off : curs off
290 if ste=0 then print "STe only. Please upgrade your Machine" : goto 290
300 open in #1,"hiscores" : input #1,HI : close #1 : rem ** load hiscores
310 T$="FW STe"+chr$(0) : text back,0,varptr(T$),32,0
320 T$="beta 003"+chr$(0) : text logic,0,varptr(T$),32,1
330 T$="press 0."+chr$(0) : text back,0,varptr(T$),32,6
340 T$="numpad"+chr$(0) : text logic,0,varptr(T$),32,7
350 T$="Enemies"+chr$(0) : text logic,0,varptr(T$),33,12
360 T$="Score"+chr$(0) : text logic,0,varptr(T$),33,15
370 T$="Life"+chr$(0) : text logic,0,varptr(T$),33,18
380 T$="Hiscore"+chr$(0) : text logic,0,varptr(T$),33,21
390 T=string(HI) : text logic,0,T,33,22 : text physic,0,T,33,22
400 get palette (7)
410 reserve as work 8,8400 : rem ** buffer for merge blit
420 ST5=start(5) : ST6=start(6) : ST7=start(7) : ST8=start(8) : ST10=start(10) : ST13=start(13)
430 M=musauto(ST10,1,20000) : p on : rem ** music/sample start
440 logic=back : XP=128 : YP=157 : XPT=300 : LIF=5 : SC=0 : rem ** player x & y pos
450 NB=8 : rem ** number of enemies
460 YT=2112 : rem y scroll pos
470 for ZZ=1 to 20 : XE(ZZ)=32*(ZZ-1) : SE(ZZ)=rnd(3)+1 : next ZZ
480 landscape 0,0,256,192,0,1
490 repeat
500 landscape logic,ST5,ST6,0,YT,0
510 blitter merge ST7,256,31,288,63,logic,XP,YP,ST8
520 rem doke $FF8240,$70
530 if joy=0 then 580
540 if jup and YP>-2 then dec YP : dec YP : dec YP
550 if jdown and YP<162 then inc YP : inc YP : inc YP
560 if jleft and XP>0 then dec XP : dec XP : dec XP
570 if jright and XP<224 then inc XP : inc XP : inc XP
580 if p fire(1) and T1=0 then dac play ST13,1519,1,1 : XPT=XP+11 : YPT=YP : T1=1
590 if T1=1 and YPT<=0 then T1=0 : goto 610
600 if T1=1 and YPT>0 then dec YPT : dec YPT : dec YPT : dec YPT : dec YPT : dec YPT : blitter merge ST7,0,32,16,41,logic,XPT,YPT,ST8
610 rem doke $FF8240,$0
620 rem doke $FF8240,7
630 for ZZ=1 to NB
640 blitter merge ST7,224,1,256,22,logic,XE(ZZ),YE(ZZ),ST8
650 YE(ZZ)=YE(ZZ)+SE(ZZ)
660 if YE(ZZ)>193 then YE(ZZ)=-22
670 XP4=XP+4 : XP16=XP+16 : XP32=XP+32 : YP32=YP+32 : YP4=YP+4 : YP28=YP+28 : XE32=XE(ZZ)+32 : YE22=YE(ZZ)+22 : XE16=XE(ZZ)+16 : YE20=YE(ZZ)+20
680 A=inside(XPT,YPT,XE(ZZ),YE(ZZ),XE32,YE22)
690 if A=true then dac play ST13,1519,0,1 : T1=0 : SE(ZZ)=rnd(3)+1 : YE(ZZ)=-22 : XPT=300 : SC=SC+100 : SCO=string(SC) : text physic,0,SCO,33,16 : text logic,0,SCO,33,16
700 if SC>HI then HI=SC : T=string(HI) : text logic,0,T,33,22 : text physic,0,T,33,22
710 B=inside(XP16,YP4,XE(ZZ),YE(ZZ),XE32,YE22)
720 if B=true then dac play ST13,1519,2,1 : T1=0 : SE(ZZ)=rnd(3)+1 : YE(ZZ)=-22 : XPT=300 : dec LIF : L=string(LIF) : text physic,0,L,33,19 : text logic,0,L,33,19
725 if LIF=-1 then 840
730 C=inside(XE16,YE20,XP,YP,XP32,YP32)
740 if C=true then dac play ST13,1519,2,1 : T1=0 : SE(ZZ)=rnd(3)+1 : YE(ZZ)=-22 : XPT=300 : dec LIF : L=string(LIF) : text physic,0,L,33,19 : text logic,0,L,33,19
750 if LIF=-1 then 840
760 next ZZ
770 dec YT : if YT=0 then YT=2112
780 if hardkey=113 and NB<>8 then inc NB : TA=string(NB) : text physic,0,TA,33,13 : text logic,0,TA,33,13
790 if hardkey=112 and NB>1 then dec NB : TA=string(NB) : text physic,0,TA,33,13 : text logic,0,TA,33,13
800 blitter copy ST7,0,192,256,200,logic,0,192 : rem ** mask the last scrolline
810 screen swap : wait vbl
820 until hardkey=57
830 mouseon : default : clear key : M=musauto(0,0,0) : end : rem ** stop music
840 rem ** end game
850 M=musauto(0,0,0) : boom : wait 100 : p stop
860 open out #1,"hiscores" : print #1,HI : close #1 : rem save hiscore
870 erase 8 : goto 280