Update for more games\!

This commit is contained in:
William Moore 2023-08-15 10:20:48 -05:00
parent 839633d18f
commit 1e971436ed
2 changed files with 148 additions and 0 deletions

69
src/1802mc/BEETLE.bas Normal file
View File

@ -0,0 +1,69 @@
1 REM BEETLE.bas
2 REM Copyright (C) 2023 William R. Moore
3 REM
4 REM This program is free software: you can redistribute it and/or modify
5 REM it under the terms of the GNU General Public License as published by
6 REM the Free Software Foundation, either version 3 of the License, or
7 REM (at your option) any later version.
8 REM
9 REM This program is distributed in the hope that it will be useful,
10 REM but WITHOUT ANY WARRANTY; without even the implied warranty of
11 REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 REM GNU General Public License for more details.
13 REM
14 REM You should have received a copy of the GNU General Public License
15 REM along with this program. If not, see <http://www.gnu.org/licenses/>.
20 GOSUB 9000
30 W=0
40 DIM B(6)
50 FOR P=1 TO 6
60 B(P)=0
70 NEXT P
80 PRINT "TOGGLE ANY SWITCH TO END (OR NONE TO KEEP PLAYING) AND ENTER ANY KEY TO CONTINUE..."
90 INPUT X$
100 I=INP(0,4)
110 IF I>1 GOTO 1000
120 IF I=1 PRINT "THANKS FOR PLAYING THIS ROUND!":GOTO 20
130 GOSUB 200
140 IF W=1 GOTO 1000
150 IF W=0 GOTO 80
200 DEFINT D
210 D=RND(6)+1
220 IF D=1 IF B(1)<2 B(1)=B(1)+1
230 IF D=2 IF B(2)<2 B(2)=B(2)+1
240 IF D=3 IF B(3)<6 B(3)=B(3)+1
250 IF D=4 IF B(4)<2 B(4)=B(4)+1
260 IF D=5 IF B(5)<1 B(5)=1
270 IF D=6 IF B(6)<1 B(6)=1
280 PRINT "YOUR BEETLE PARTS SO FAR:"
290 PRINT "EYES (MAX 2):", B(1)
300 PRINT "ANTENNA (MAX 2):", B(2)
310 PRINT "LEG (MAX 6):", B(3)
320 PRINT "WING (MAX 2):", B(4)
330 PRINT "HEAD (MAX 1):", B(5)
340 PRINT "BODY (MAX 1):", B(6)
350 C=B(1)+B(2)+B(3)+B(4)+B(5)+B(6)
360 IF INT(C)=14 W=1:PRINT "YOU'VE MADE A BEETLE!"
370 RETURN
1000 PRINT "THANK YOU FOR YOUR TIME!"
1010 END
9000 N=129
9010 OUT (0,4,N)
9020 WAIT(8)
9030 N=66
9040 OUT (0,4,N)
9050 WAIT(8)
9060 N=36
9070 OUT (0,4,N)
9080 WAIT(8)
9090 N=24
9100 OUT (0,4,N)
9110 WAIT(8)
9120 N=36
9130 OUT (0,4,N)
9140 WAIT(8)
9150 N=66
9160 OUT (0,4,N)
9170 WAIT(8)
9180 OUT (0,4,0)
9190 RETURN

View File

@ -0,0 +1,79 @@
1 REM FORTUNE.bas
2 REM Copyright (C) 2023 William R. Moore
3 REM
4 REM This program is free software: you can redistribute it and/or modify
5 REM it under the terms of the GNU General Public License as published by
6 REM the Free Software Foundation, either version 3 of the License, or
7 REM (at your option) any later version.
8 REM
9 REM This program is distributed in the hope that it will be useful,
10 REM but WITHOUT ANY WARRANTY; without even the implied warranty of
11 REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 REM GNU General Public License for more details.
13 REM
14 REM You should have received a copy of the GNU General Public License
15 REM along with this program. If not, see <http://www.gnu.org/licenses/>.
20 RANDOMIZE(0)
22 DIM F(8), N(8)
31 F$(1)="YOU WILL BITE YOUR TONGUE."
32 F$(2)="YOU WILL FIND YOURSELF STINKING BADLY."
33 F$(3)="YOU WILL BE A DONKEY TO ALL PEOPLES."
34 F$(4)="YOU WILL FIND TRUE LOVE."
35 F$(5)="YOU WILL CONTROL A LUNATIC."
36 F$(6)="YOU WILL BE DEEP FRIED."
37 F$(7)="YOU WILL FIND YOURSELF IN A PIT OF DESPAIR"
38 F$(8)="YOU WILL BE HATLESS."
40 PRINT "1 - ORANGE"
41 PRINT "2 - YELLOW"
42 PRINT "3 - GREEN"
43 PRINT "4 - RED"
44 PRINT "TOGGLE ONE OF FIRST 4 SWITCHES (OR NONE TO END) AND ENTER ANY KEY TO CONTINUE..."
45 X$ = INPUT$(1)
46 I=INP(255)
47 IF I AND 1 THEN GOSUB 100
48 IF I AND 2 THEN GOSUB 100
49 IF I AND 4 THEN GOSUB 100
50 IF I AND 8 THEN GOSUB 100
51 IF I=0 THEN GOTO 1000
52 GOSUB 40
100 FOR P=1 TO 8
110 N(P) = -1
120 NEXT P
130 FOR P=0 TO 4
140 K=INT(8*RND(8)+1)
150 IF N(K)=-1 THEN N(K)=0:PRINT K
160 NEXT P
170 PRINT "TOGGLE ONE OF THE FIRST FOUR SWITCHES AND ENTER ANY KEY TO ENTER TO CONTINUE..."
180 X$ = INPUT$(1)
190 C=INP(255)
200 IF C=0 THEN GOTO 1000
210 IF C AND 1 THEN GOTO 260
220 IF C AND 2 THEN GOTO 260
230 IF C AND 4 THEN GOTO 260
240 IF C AND 8 THEN GOTO 260
250 GOTO 100
260 FOR P=1 TO 8
270 N(P) = -1
280 NEXT P
290 FOR P=0 TO 4
300 K=INT(8*RND(8)+1)
310 IF N(K)=-1 THEN N(K)=0:PRINT K
320 NEXT P
330 PRINT "TOGGLE ONE OF THE FIRST FOUR SWITCHES AND ENTER ANY KEY TO ENTER"
340 PRINT "AND RECEIVE YOUR FORTUNE..."
350 X$ = INPUT$(1)
360 C=INP(255)
370 IF C=0 GOTO 1000
380 IF C AND 1 THEN L=1:GOTO 430
390 IF C AND 2 THEN L=2:GOTO 430
400 IF C AND 4 THEN L=3:GOTO 430
410 IF C AND 8 THEN L=4:GOTO 430
420 GOTO 260
430 M=1
440 FOR P=1 TO 8
450 IF N(P)=0 AND M=L THEN PRINT F$(P):GOTO 480
460 IF N(P)=0 AND M<>L THEN M=M+1
470 NEXT P
480 RETURN
1000 PRINT "THANK YOU FOR YOUR TIME!"
1010 END