Trailing-Edge
-
PDP-10 Archives
-
decus_20tap1_198111
-
decus/20-0020/roulet.gam
There are 2 other files named roulet.gam in the archive. Click here to see a list.
100' NAME--ROULETTE
110'
120' DESCRIPTION--GENERATES GAME OF ROULETTE
130'
140' SOURCE--W. PAUL CULLEN,NEW ENGLAND COLLEGE.
150'
160' INSTRUCTIONS--TYPE "RUN" AND FOLLOW INSTRUCTIONS.
170'
180'
190' * * * * * * * * * MAIN PROGRAM * * * * * * * * *
200'
210 LET K1 = 0
220 PRINT " WELCOME TO MONTE CARLO AND OUR EUROPEAN ROULETTE TABLE."
230 PRINT " I WISH YOU THE BEST OF LUCK."
240 PRINT
250 PRINT
260 PRINT "DO YOU WANT INSTRUCTIONS";
270 INPUT Z$
280 IF Z$ = "NO" THEN 970
290 IF Z$ = "YES" THEN 320
300 GOSUB 1960
310 GO TO 260
320 PRINT " THIS IS A GAME OF ROULETTE. YOU ARE ALLOWED TO BET"
330 PRINT "AN ODD OR EVEN NUMBER AND/OR A BLACK OR RED NUMBER AND/OR"
340 PRINT "A COLUMN OF NUMBERS AND/OR A NUMBER ITSELF. NUMBERS RANGE"
350 PRINT "FROM 0 TO 36. IF 0 APPEARS, THE BANK COLLECTS ALL BETS"
360 PRINT "EXCEPT THOSE BET ON THE NUMBER 0. THE PAYOFFS ARE AS FOLLOWS"
370 PRINT,"ODD OR EVEN = 1 TO 1"
380 PRINT,"RED OR BLACK = 1 TO 1"
390 PRINT, "A COLUMN = 2 TO 1"
400 PRINT, "A NUMBER = 35 TO 1"
410 PRINT " YOU ARE ALLOWED TO BET FROM $1 TO $10000, BUT THE";
420 PRINT " TABLE WILL ONLY ACCEPT BETS OF WHOLE DOLLARS (NO CENTS)."
430 PRINT
440 PRINT " WOULD YOU LIKE TO SEE A PICTURE OF THE GAMBLING TABLE";
450 INPUT Z1$
460 IF Z1$ = "NO" THEN 970
470 IF Z1$ = "YES" THEN 510
480 GOSUB 1960
490 GO TO 440
500 PRINT
510 PRINT
520 PRINT" BELOW IS THE PICTURE OF OUR GAMBLING TABLE."
530 PRINT
540 PRINT
550 PRINT, " ***********"
560 PRINT, " * 0 *"
570 LET U$ = "*******************"
580 PRINT,U$
590 PRINT,"* 1 * 2 * 3 *"
600 PRINT,"* RED *BLACK* RED *"
610 PRINT ,U$
620 PRINT,"* 4 * 5 * 6 *"
630 PRINT,"*BLACK* RED *BLACK*"
640 PRINT,U$
650 PRINT,"* 7 * 8 * 9 *"
660 PRINT,"* RED *BLACK* RED *"
670 PRINT,U$
680 PRINT,"* 10 * 11 * 12 *"
690 PRINT,"*BLACK*BLACK* RED *"
700 PRINT,U$
710 PRINT,"* 13 * 14 * 15 *"
720 PRINT,"*BLACK* RED *BLACK*"
730 PRINT,U$
740 PRINT,"* 16 * 17 * 18 *"
750 PRINT,"* RED *BLACK* RED *"
760 PRINT,U$
770 PRINT,"* 19 * 20 * 21 *"
780 PRINT,"* RED *BLACK* RED *"
790 PRINT,U$
800 PRINT,"* 22 * 23 * 24 *"
810 PRINT,"*BLACK* RED *BLACK*"
820 PRINT,U$
830 PRINT,"* 25 * 26 * 27 *"
840 PRINT,"* RED * RED *BLACK*"
850 PRINT,U$
860 PRINT,"* 28 * 29 * 30 *"
870 PRINT,"*BLACK*BLACK* RED *"
880 PRINT ,U$
890 PRINT,"* 31 * 32 * 33 *"
900 PRINT,"*BLACK* RED *BLACK*"
910 PRINT,U$
920 PRINT,"* 34 * 35 * 36 *"
930 PRINT,"* RED *BLACK* RED *"
940 PRINT,U$
950 PRINT, "*COL.1*COL.2*COL.3*"
960 PRINT,U$
970 PRINT
980 PRINT
990 PRINT
1000 PRINT "DO YOU WANT TO BET AN ODD OR EVEN NUMBER";
1010 INPUT A$
1020 IF A$ = "NO" THEN 1220
1030 IF A$ = "YES" THEN 1060
1040 GOSUB 1960
1050 GO TO 1000
1060 PRINT "ODD OR EVEN";
1070 INPUT B$
1080 IF B$ = "ODD"THEN 1120
1090 IF B$ = "EVEN"THEN 1120
1100 PRINT "PLEASE TYPE ODD OR EVEN"
1110 GO TO 1060
1120 PRINT "HOW MUCH DO YOU WANT TO BET";
1130 INPUT H
1140 IF H <= 10000 THEN 1170
1150 GOSUB 1980
1160 GO TO 1120
1170 FOR H1 = 0 TO 10000
1180 IF H1 = H THEN 1230
1190 NEXT H1
1200 GOSUB 2010
1210 GO TO 1120
1220 LET H = 0
1230 PRINT
1240 PRINT "DO YOU WANT TO BET A RED OR BLACK NUMBER";
1250 INPUT C$
1260 IF C$ = "NO" THEN 1460
1270 IF C$ = "YES" THEN 1300
1280 GOSUB 1960
1290 GO TO 1240
1300 PRINT "RED OR BLACK";
1310 INPUT D$
1320 IF D$ = "RED" THEN 1360
1330 IF D$ = "BLACK" THEN 1360
1340 PRINT "PLEASE TYPE RED OR BLACK."
1350 GO TO 1300
1360 PRINT "HOW MUCH DO YOU WANT TO BET";
1370 INPUT I
1380 IF I <= 10000 THEN 1410
1390 GOSUB 1980
1400 GO TO 1360
1410 FOR I2 = 0 TO 10000
1420 IF I2 = I THEN 1470
1430 NEXT I2
1440 GOSUB 2010
1450 GO TO 1360
1460 LET I = 0
1470 PRINT
1480 PRINT "DO YOU WANT TO BET A COLUMN OF NUMBERS";
1490 INPUT B1$
1500 IF B1$ = "NO" THEN 1700
1510 IF B1$ = "YES" THEN 1540
1520 GOSUB 1960
1530 GO TO 1480
1540 PRINT "COLUMN 1, 2, OR 3";
1550 INPUT B2
1560 IF B2 = 1 THEN 1610
1570 IF B2 = 2 THEN 1610
1580 IF B2 = 3 THEN 1610
1590 PRINT "PLEASE TYPE 1, 2, OR 3."
1600 GO TO 1540
1610 PRINT "HOW MUCH DO YOU WANT TO BET";
1620 INPUT B8
1630 IF B8 <= 10000 THEN 1660
1640 GOSUB 1980
1650 GO TO 1610
1660 FOR B9 = 0 TO 10000
1670 IF B8 = B9 THEN 1710
1680 NEXT B9
1690 GO TO 1610
1700 LET B8 = 0
1710 PRINT
1720 PRINT "DO YOU WANT TO BET A NUMBER";
1730 INPUT E$
1740 IF E$ = "NO" THEN 2040
1750 IF E$ = "YES" THEN 1780
1760 GOSUB 1960
1770 GO TO 1720
1780 PRINT "WHAT IS YOUR NUMBER";
1790 INPUT F
1800 FOR M = 0 TO 36
1810 IF F = M THEN 1860
1820 NEXT M
1830 PRINT "THAT IS AN ILLEGAL NUMBER"
1840 PRINT "YOU ARE ONLY ALLOWED TO BET INTEGERS RANGING FROM 0 TO 36"
1850 GO TO 1780
1860 PRINT "HOW MUCH DO YOU WANT TO BET";
1870 INPUT G
1880 IF G <= 10000 THEN 1910
1890 GOSUB 1980
1900 GO TO 1860
1910 FOR G9 = 0 TO 10000
1920 IF G = G9 THEN 2050
1930 NEXT G9
1940 GOSUB 2010
1950 GO TO 1860
1960 PRINT "PLEASE TYPE YES OR NO."
1970 RETURN
1980 PRINT "SORRY, BUT THE TABLE CANNOT ACCEPT A BET OF THAT MUCH";
1990 PRINT " MONEY."
2000 RETURN
2010 PRINT "SORRY, BUT YOU CAN ONLY BET IN $1 INCREMENTS FROM $1 TO";
2020 PRINT " $10000."
2030 RETURN
2040 LET G = 0
2050 PRINT
2060 RANDOMIZE
2070 LET T = INT(37*RND)
2080 PRINT "THE NUMBER IS ";
2090 LET T1 = INT(T/10)+1
2100 ON T1 GO TO 2110,2120,2130,2140
2110 ON T+1 GO TO 2390,2210,2290,2250,2270,2230,2310,2210,2290,2250
2120 ON T-9 GO TO 2270,2350,2190,2330,2170,2370,2150,2350,2190,2210
2130 ON T-19 GO TO 2290,2250,2270,2230,2310,2210,2170,2370,2270,2350
2140 ON T-29 GO TO 2190,2330,2170,2370,2150,2350,2190
2150 PRINT T;" RED, EVEN, COLUMN 1"
2160 GO TO 2400
2170 PRINT T;" RED, EVEN, COLUMN 2"
2180 GO TO 2400
2190 PRINT T;" RED, EVEN, COLUMN 3"
2200 GO TO 2400
2210 PRINT T;" RED, ODD, COLUMN 1"
2220 GO TO 2400
2230 PRINT T;" RED, ODD, COLUMN 2"
2240 GO TO 2400
2250 PRINT T;" RED, ODD, COLUMN 3"
2260 GO TO 2400
2270 PRINT T;" BLACK, EVEN, COLUMN 1"
2280 GO TO 2400
2290 PRINT T; " BLACK, EVEN, COLUMN 2"
2300 GO TO 2400
2310 PRINT T; " BLACK, EVEN, COLUMN 3"
2320 GO TO 2400
2330 PRINT T; " BLACK, ODD, COLUMN1"
2340 GO TO 2400
2350 PRINT T; " BLACK, ODD, COLUMN 2"
2360 GO TO 2400
2370 PRINT T; " BLACK, ODD, COLUMN 3"
2380 GO TO 2400
2390 PRINT T
2400 IF G = 0 THEN 2470
2410 IF T = F THEN 2450
2420 PRINT " YOU LOSE $"G" FOR YOUR NUMBER BET."
2430 LET G = -G
2440 GO TO 2470
2450 PRINT " YOU WIN $"35*G" FOR YOUR NUMBER BET."
2460 LET G = 35*G
2470 IF H = 0 THEN 2660
2480 IF T = 0 THEN 2570
2490 IF B$ = "EVEN" THEN 2540
2500 FOR X = 1 TO 35 STEP 2
2510 IF T = X THEN 2610
2520 NEXT X
2530 GO TO 2570
2540 FOR X1 = 2 TO 36 STEP 2
2550 IF T = X1 THEN 2610
2560 NEXT X1
2570 PRINT " YOU LOSE $"H;
2580 GOSUB 2640
2590 LET H = -H
2600 GO TO 2660
2610 PRINT " YOU WIN $"H;
2620 GOSUB 2640
2630 GO TO 2660
2640 PRINT "FOR YOUR ODD-EVEN BET."
2650 RETURN
2660 IF I = 0 THEN 2940
2670 IF T = 0 THEN 2840
2680 FOR A1 = 1 TO 9 STEP 2
2690 IF T = A1 THEN 2830
2700 NEXT A1
2710 FOR A2 = 12 TO 18 STEP 2
2720 IF T = A2 THEN 2830
2730 NEXT A2
2740 FOR A3 = 19 TO 25 STEP 2
2750 IF T = A3 THEN 2830
2760 NEXT A3
2770 FOR A4 = 30 TO 36 STEP 2
2780 IF T = A4 THEN 2830
2790 NEXT A4
2800 IF T = 26 THEN 2830
2810 IF D$ = "BLACK" THEN 2880
2820 GO TO 2840
2830 IF D$ = "RED" THEN 2880
2840 PRINT " YOU LOSE $"I;
2850 GOSUB 2920
2860 LET I = -I
2870 GO TO 2940
2880 PRINT " YOU WIN $";
2890 PRINT I;
2900 GOSUB 2920
2910 GO TO 2940
2920 PRINT "FOR YOUR RED-BLACK BET."
2930 RETURN
2940 IF B8 = 0 THEN 3200
2950 IF T = 0 THEN 3160
2960 FOR B3 = 1 TO 34 STEP 3
2970 IF T = B3 THEN 3050
2980 NEXT B3
2990 FOR B4 = 2 TO 35 STEP 3
3000 IF T = B4 THEN 3070
3010 NEXT B4
3020 FOR B5 = 3 TO 36 STEP 3
3030 IF T = B5 THEN 3090
3040 NEXT B5
3050 IF B2 = 1 THEN 3110
3060 IF B2 <> 1 THEN 3160
3070 IF B2 = 2 THEN 3110
3080 IF B2 <> 2 THEN 3160
3090 IF B2 = 3 THEN 3110
3100 IF B2 <> 3 THEN 3160
3110 PRINT " YOU WIN $";
3120 PRINT 2*B8;
3130 PRINT "FOR YOUR COLUMN BET."
3140 LET B8 = 2*B8
3150 GO TO 3200
3160 PRINT " YOU LOSE $";
3170 PRINT B8;
3180 PRINT "FOR YOUR COLUMN BET."
3190 LET B8 = -B8
3200 PRINT
3210 LET K = (G) + (H) + (I) + (B8)
3220 IF K < 0 THEN 3260
3230 IF K = 0 THEN 3280
3240 IF K > 0 THEN 3300
3250 GO TO 3310
3260 PRINT " YOU LOST $" ABS(K)" ON THIS ROUND."
3270 GO TO 3310
3280 PRINT " YOU BROKE EVEN THIS TIME."
3290 GO TO 3310
3300 PRINT " YOU WON $"K" ON THIS ROUND."
3310 PRINT
3320 PRINT
3330 LET K1 = K1 + K
3340 IF K1 < 0 THEN 3370
3350 IF K1 = 0 THEN 3390
3360 IF K1 > 0 THEN 3410
3370 PRINT " YOU HAVE LOST A TOTAL OF $"ABS(K1)" THUS FAR."
3380 GO TO 3430
3390 PRINT " THUS FAR YOU HAVE BROKEN EVEN."
3400 GO TO 3430
3410 PRINT " YOU HAVE WON A TOTAL OF $"K1" THUS FAR."
3420 GO TO 3430
3430 PRINT
3440 PRINT " DO YOU WANT TO PLAY AGAIN";
3450 INPUT M$
3460 IF M$ = "NO" THEN 3500
3470 IF M$ = "YES" THEN 970
3480 PRINT "PLEASE TYPE YES OR NO."
3490 GO TO 3440
3500 PRINT
3510 PRINT " THANKS FOR PLAYING."
3520 IF K1 < 0 THEN 3550
3530 IF K1 = 0 THEN 3570
3540 IF K1 > 0 THEN 3600
3550 PRINT " YOU LOST $" ABS(K1);", BETTER LUCK NEXT TIME."
3560 GO TO 3610
3570 PRINT " YOU BROKE EVEN TODAY, MAYBE NEXT TIME YOU WILL WIN";
3580 PRINT " A FORTUNE."
3590 GO TO 3610
3600 PRINT " CONGRATULATIONS, YOU BEAT THE ODDS. YOU WON $"K1"TODAY."
3610 END