mirror of
https://github.com/antoinevignau/source.git
synced 2025-01-19 10:31:15 +00:00
385 lines
10 KiB
QBasic
385 lines
10 KiB
QBasic
5 GOSUB 9700
|
||
19 DIM S(25)
|
||
20 DIM C(5)
|
||
30 LET SALLE=1
|
||
40 DIM P$(2,2)
|
||
50 DIM O(O)
|
||
60 FOR X=1 TO O
|
||
70 LET O(X)=Q(X)
|
||
80 NEXT X
|
||
90 RAND
|
||
100 IF NOT S(2) THEN GOTO 200
|
||
110 IF C(2) THEN LET C(2)=C(2)-1
|
||
120 IF S(3) THEN GOTO 200
|
||
130 PRINT "ON N Y VOIT RIEN.MIEUX VAUDRAIT","ALLUMER POUR EVITER LES ENNUIS."
|
||
140 IF C(3) THEN LET C(3)=C(3)-1
|
||
150 GOTO 1000
|
||
210 GOSUB 9600
|
||
220 GOSUB 8000+SALLE*10
|
||
300 LET F=0
|
||
310 FOR X=1 TO O
|
||
320 IF O(X)<>SALLE THEN GOTO 500
|
||
330 IF F THEN GOTO 400
|
||
340 PRINT AT 15,15;"IL Y A AUSSI:"
|
||
350 LET F=1
|
||
400 PRINT TAB 15;"-";O$(X)
|
||
500 NEXT X
|
||
1010 LET T=1
|
||
1020 GOTO 2000
|
||
1100 IF C(1) THEN LET C(1)=C(1)-1
|
||
1110 IF C(4) THEN LET C(4)=C(4)-1
|
||
1120 PRINT AT 21,15;"QUE FAITES-VOUS?>"
|
||
1130 INPUT Y$
|
||
1140 CLS
|
||
1150 LET Y=0
|
||
1160 PRINT ">";Y$;":";
|
||
1170 LET P$(2)="00"
|
||
1200 FOR W=1 TO 2
|
||
1210 GOSUB 6000
|
||
1220 IF Y>=LEN Y$ THEN GOTO 1300
|
||
1230 IF P$(W)="00" THEN GOTO 1210
|
||
1240 NEXT W
|
||
1300 IF P$(1)<>"00" THEN GOTO 1600
|
||
1310 PRINT "PARDON?"
|
||
1320 GOTO 100
|
||
1610 LET Z=1
|
||
1620 LET T$=M$(SALLE)(Z TO Z+1)
|
||
1630 IF T$="00" THEN GOTO 1900
|
||
1640 IF T$<>P$(1) THEN GOTO 1700
|
||
1650 LET SALLE=VAL (M$(SALLE)(Z+2 TO Z+3))
|
||
1660 GOTO 100
|
||
1700 LET Z=Z+4
|
||
1710 GOTO 1620
|
||
1900 LET T=0
|
||
1910 LET CORRESP=0
|
||
2010 LET CP=0
|
||
2100 LET CP=CP+1
|
||
2110 IF NOT T THEN GOTO 2300
|
||
2120 LET E$=C$(CP)
|
||
2130 GOTO 2600
|
||
2300 IF CP<=A THEN GOTO 2400
|
||
2310 IF CORRESP THEN GOTO 1000
|
||
2320 PRINT "IMPOSSIBLE";
|
||
2330 IF VAL (P$(1))<9 THEN PRINT " DE PRENDRE CETTE DIRECTION";
|
||
2340 PRINT "."
|
||
2350 GOTO 100
|
||
2400 IF A$(CP)(1 TO 2)<>P$(1) THEN GOTO 2100
|
||
2410 LET Y$=A$(CP)(3 TO 4)
|
||
2420 IF Y$<>"00" AND Y$<>P$(2) THEN GOTO 2100
|
||
2430 LET E$=A$(CP)(5 TO )
|
||
2610 LET E=1
|
||
2700 IF E$(E)="." THEN GOTO 3000
|
||
2710 LET TYPE=CODE (E$(E))-38
|
||
2720 LET N=VAL (E$(E+1 TO E+2))
|
||
2800 GOSUB 2900+TYPE*10
|
||
2810 IF NOT OK THEN GOTO 2100
|
||
2820 LET E=E+3
|
||
2830 GOTO 2700
|
||
2900 LET OK=(N=SALLE)
|
||
2905 RETURN
|
||
2910 LET OK=(O(N)=SALLE OR O(N)<0)
|
||
2915 RETURN
|
||
2920 LET OK=(O(N)<>SALLE AND O(N)>=0)
|
||
2925 RETURN
|
||
2930 LET OK=(O(N)<0)
|
||
2935 RETURN
|
||
2940 LET OK=S(N)
|
||
2945 RETURN
|
||
2950 LET OK=(NOT S(N))
|
||
2955 RETURN
|
||
2960 LET OK=(C(N)=1)
|
||
2965 RETURN
|
||
2970 LET OK=((INT (RND*100)+1)<=N)
|
||
2975 RETURN
|
||
3010 LET CORRESP=1
|
||
3020 LET E=E+1
|
||
3100 IF E$(E)="." THEN GOTO 2100
|
||
3110 LET TYPE=CODE (E$(E))-38
|
||
3120 IF E$(E+1)<>"." THEN LET N=VAL (E$(E+1 TO E+2))
|
||
3200 LET BREAK=0
|
||
3210 GOSUB 4000+TYPE*100
|
||
3220 IF BREAK THEN GOTO BREAK
|
||
3230 LET E=E+3
|
||
3240 GOTO 3100
|
||
4000 PRINT
|
||
4010 PRINT AT 8,15;"VOUS TENEZ:"
|
||
4020 LET F=1
|
||
4030 FOR X=1 TO O
|
||
4040 IF O(X)>=0 THEN GOTO 4070
|
||
4050 PRINT TAB 15;"-";O$(X)
|
||
4060 LET F=0
|
||
4070 NEXT X
|
||
4080 IF F THEN PRINT TAB 15;"-RIEN"
|
||
4090 LET BREAK=100
|
||
4095 RETURN
|
||
4100 IF S(1)<5 THEN GOTO 4140
|
||
4110 PRINT "VOUS NE POUVEZ PORTER PLUS"
|
||
4120 LET BREAK=100
|
||
4130 RETURN
|
||
4140 IF O(N)=-1 THEN GOTO 4180
|
||
4150 LET O(N)=-1
|
||
4160 LET S(1)=S(1)+1
|
||
4170 RETURN
|
||
4180 PRINT "VOUS L<>AVEZ DEJA"
|
||
4190 GOTO 4120
|
||
4200 IF O(N)=-1 THEN GOTO 4240
|
||
4210 PRINT "VOUS N<>AVEZ PAS ";O$(N)
|
||
4220 LET BREAK=100
|
||
4230 RETURN
|
||
4240 LET O(N)=SALLE
|
||
4250 LET S(1)=S(1)-1
|
||
4260 RETURN
|
||
4300 PRINT
|
||
4310 GOSUB 7000+N*10
|
||
4320 RETURN
|
||
4400 LET S(N)=1
|
||
4410 RETURN
|
||
4500 LET S(N)=0
|
||
4510 RETURN
|
||
4600 LET C(N)=VAL (E$(E+3 TO E+4))
|
||
4610 LET E=E+2
|
||
4620 RETURN
|
||
4700 LET X=O(N)
|
||
4710 LET O(N)=O(N+1)
|
||
4720 LET O(N+1)=X
|
||
4730 RETURN
|
||
4800 LET O(N)=SALLE
|
||
4810 RETURN
|
||
4900 IF O(N)<0 THEN LET S(1)=S(1)-1
|
||
4910 LET O(N)=0
|
||
4920 RETURN
|
||
5000 LET SALLE=N
|
||
5010 RETURN
|
||
5100 PRINT "D<>ACCORD"
|
||
5200 LET BREAK=1000
|
||
5210 RETURN
|
||
5300 LET BREAK=1100
|
||
5310 RETURN
|
||
5400 LET BREAK=100
|
||
5410 RETURN
|
||
5500 PRINT "ETES VOUS SUR? ";
|
||
5510 INPUT W$
|
||
5520 PRINT W$
|
||
5530 IF PLOT CODE W$<>"O" THEN RETURN
|
||
5600 GOTO 9999
|
||
6010 DIM W$(4)
|
||
6015 LET P$(W)="00"
|
||
6020 GOSUB 6600
|
||
6025 IF FIN THEN RETURN
|
||
6030 FOR Q=1 TO 4
|
||
6040 LET W$(Q)=Y$(Y)
|
||
6050 GOSUB 6500
|
||
6060 IF FIN THEN GOTO 6100
|
||
6070 NEXT Q
|
||
6080 GOSUB 6500
|
||
6090 IF NOT FIN THEN GOTO 6080
|
||
6100 IF W$=" " THEN RETURN
|
||
6110 FOR Q=1 TO V
|
||
6120 IF W$=V$(Q)(3 TO ) THEN GOTO 6200
|
||
6130 NEXT Q
|
||
6140 RETURN
|
||
6200 LET P$(W)=V$(Q)( TO 2)
|
||
6210 RETURN
|
||
6500 LET Y=Y+1
|
||
6510 LET FIN=(Y>LEN Y$)
|
||
6520 IF FIN THEN RETURN
|
||
6530 LET FIN=(Y$(Y)=" ")
|
||
6540 RETURN
|
||
6600 LET Y=Y+1
|
||
6610 LET FIN=(Y>LEN Y$)
|
||
6620 IF FIN THEN RETURN
|
||
6630 IF Y$(Y)=" " THEN GOTO 6600
|
||
6640 RETURN
|
||
7010 PRINT AT 1,0;"UNE TRAPPE S<>OUVRE.VOUS VOUS EMPALEZ SUR DES PIQUES"
|
||
7015 RETURN
|
||
7020 PRINT AT 1,0;"UNE FLECHE VOUS TRAVERSE"
|
||
7025 RETURN
|
||
7030 PRINT AT 1,0;"LE RAYON REVIENT SUR VOUS ET VOUS DESINTEGRE"
|
||
7035 RETURN
|
||
7040 PRINT AT 1,0;"CE N<>ETAIT Q<>UNE PROJECTION.IL DISPARAIT"
|
||
7045 RETURN
|
||
7050 PRINT AT 2,0;"un<75>troll<6C>apparait<69>";AT 9,6;"( O )"
|
||
7055 RETURN
|
||
7060 PRINT AT 1,0;"VOUS ETES ETES ELECTROCUTE"
|
||
7065 RETURN
|
||
7070 PRINT AT 1,0;"VOUS EXPLOSEZ"
|
||
7075 RETURN
|
||
7080 PRINT AT 1,0;"LE TRAIN S<>EST MIS EN MARCHE"
|
||
7085 RETURN
|
||
7090 PRINT AT 1,0;"VOUS TOMBEZ DANS LE VIDE.VOUS VOUS ECRASEZ"
|
||
7095 RETURN
|
||
7100 PRINT AT 5,0;"IL Y<>A LE VIDE AUTOUR LA VOIE.VOUS APERCEVEZ ET APPRENEZ UN CODE POUR CLAVIER"
|
||
7105 RETURN
|
||
7110 PRINT AT 1,0;"LE MOTEUR EXPLOSE.VOUS AUSSI."
|
||
7115 RETURN
|
||
7120 PRINT AT 1,0;"UNE DOUCHE VOUS ENVOIF DE L<>ACIDE."
|
||
7125 RETURN
|
||
7130 PRINT AT 1,0;"VOUS ETES DESINTEGRE."
|
||
7135 RETURN
|
||
7140 PRINT AT 1,0;"LA BOITE EXPLOSE.VOUS AUSSI."
|
||
7145 RETURN
|
||
7150 PRINT "UNE TRAPPE S<>OUVRE..."
|
||
7151 PRINT
|
||
7152 PAUSE 100
|
||
7153 PRINT "VOUS VOUS RETROUVEZ DEHORS.VOUS AVEZ GAGNE."
|
||
7155 RETURN
|
||
7160 PRINT AT 1,0;"VOUS ATTRAPEZ LA PESTE.VOUS MOUREZ."
|
||
7165 RETURN
|
||
7170 PRINT AT 1,0;"DEUX LAMES DE RASOIRS GEANTES SE REFERMENT SUR VOUS."
|
||
7175 RETURN
|
||
7180 PRINT AT 1,0;"LA BOUTEILLE FUYAIT.VOS MAINS SONT RONGES.VOUS ATTRAPEZ AUSSITOT LA LEPRE.LA MALADIE VOUS EMPORTE"
|
||
7185 RETURN
|
||
7190 PRINT AT 1,0;"LA PORTE S<>EST OUVERTE."
|
||
7195 RETURN
|
||
7200 PRINT AT 1,0;"VOUS GLISSEZ.VOUS VOUS ECRASEZ."
|
||
7205 RETURN
|
||
7210 PRINT AT 1,0;"L<>EAU ENVAHIT LA SALLE.VOUS VOUS NOYEZ."
|
||
7215 RETURN
|
||
7230 PRINT AT 1,0;"C<>EST BLINDE.."
|
||
7235 RETURN
|
||
7250 PRINT AT 1,0;"CELA CREE UN PARASITE.LA MACHINE EXPLOSE.VOUS AUSSI."
|
||
7255 RETURN
|
||
7260 PRINT AT 1,0;"VOUS AVEZ EFFACEZ LA K7"
|
||
7265 RETURN
|
||
7270 PRINT AT 1,0;"LES PILES DE LA LAMPE SONT MORTES."
|
||
7275 RETURN
|
||
7280 PRINT AT 1,0;"AVEC QUOI???..."
|
||
7285 RETURN
|
||
7290 PRINT AT 1,0;"TRICHEUR...VOUS NE L<>AVEZ JAMAIS LU."
|
||
7295 RETURN
|
||
7300 PRINT AT 1,0;"LA MOMIE SE MET EN MARCHE ET VOUS DEVORE."
|
||
7305 RETURN
|
||
7310 PRINT AT 1,0;"UNE VOIX VOUS DIT:","<22>PRENEZ TOUJOURS LE 2EME<4D>"
|
||
7315 RETURN
|
||
7320 PRINT AT 15,10;"O";AT 14,10;"-";AT 16,10;"-"
|
||
7325 RETURN
|
||
7330 PRINT AT 15,4;"O";AT 14,4;"-";AT 16,4;"-"
|
||
7335 RETURN
|
||
7340 PRINT AT 19,1;"-*";AT 1,0;"IL Y<>A UN HAUT-PARLEUR BRANCHE."
|
||
7345 RETURN
|
||
7350 PRINT AT 19,1;"/*";AT 1,0;"IL Y<>A UN HAUT-PARLEUR DEBRANCHE"
|
||
7355 RETURN
|
||
7360 PRINT AT 14,0;" ";AT 15,0;" ";AT 16,0;" "
|
||
7365 RETURN
|
||
7370 PRINT AT 8,6;" "
|
||
7375 RETURN
|
||
7380 PRINT AT 1,0;"LE TRAIN S<>ARRETE,VOUS ETES","EJECTE SUR LE QUAI."
|
||
8010 PRINT AT 3,0;"VOUS ETES DANS UNE PIECE VIDE.";AT 8,6;"<22><><EFBFBD>";AT 16,6;"(O)"
|
||
8015 RETURN
|
||
8020 PRINT AT 3,0;"A L<>EST IL Y<>A UNE PORTE AVEC UNMAGNETO K7 RIVE AU MUR AVEC DEUX TOUCHES ET AU SUD UN BOUTON ROUGE";AT 14,0;"<22>";AT 15,0;"<22>";AT 16,0;"<22>";AT 14,14;"<22>";AT 15,14;"<22>";AT 16,14;"<22>";AT 8,6;"<22><><EFBFBD>";AT 21,6;"<22><><EFBFBD>";AT 21,10;"<22>";AT 12,0;"<22>:"
|
||
8025 RETURN
|
||
8030 PRINT AT 14,3;"-";AT 15,3;"O";AT 16,3;"-";AT 3,0;"VOUS ETES DANS UNE MINI GARE.IL Y<>A 3 WAGONS.";AT 14,0;"<22>";AT 15,0;"<22>";AT 16,0;"<22>"
|
||
8031 FOR U=9 TO 20
|
||
8032 PRINT AT U,11;"+-+"
|
||
8033 NEXT U
|
||
8034 PRINT AT 9,11;"<22><><EFBFBD>";AT 10,11;"<22><><EFBFBD>";AT 11,11;"<22><><EFBFBD>";AT 13,11;"<22><><EFBFBD>";AT 14,11;"<22><><EFBFBD>";AT 15,11;"<22><><EFBFBD>";AT 17,11;"<22><><EFBFBD>";AT 18,11;"<22><><EFBFBD>";AT 19,11;"<22><><EFBFBD>"
|
||
8035 RETURN
|
||
8040 PRINT AT 3,0;"LE TRAIN S<>EST ARRETE.IL FAIT NOIR"
|
||
8041 FOR U=8 TO 21
|
||
8042 PRINT AT U,0;"<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||
8043 NEXT U
|
||
8044 FOR U=8 TO 21
|
||
8045 PRINT AT U,1;"<22><><EFBFBD>"
|
||
8046 NEXT U
|
||
8047 PRINT AT 12,1;"<22><><EFBFBD>";AT 13,1;"<22><><EFBFBD>";AT 14,1;"<22><><EFBFBD>"
|
||
8048 RETURN
|
||
8050 PRINT AT 3,0;"UN RAYON EST ORIENTE N-S.IL Y<>A UNE PORTE A L<>OUEST AVEC UN OEILELECTRONIQUE."
|
||
8051 FOR U=25 TO 2 STEP -2
|
||
8052 PLOT 18,U
|
||
8053 NEXT U
|
||
8054 FOR U=9 TO 20
|
||
8055 PRINT AT U,11;"+-+"
|
||
8056 NEXT U
|
||
8057 PRINT AT 8,6;"<22><><EFBFBD>";AT 21,6;"<22><><EFBFBD>";AT 14,0;"<22>";AT 15,0;"<22>";AT 16,0;"<22>";AT 12,0;"<22>"
|
||
8058 RETURN
|
||
8060 PRINT AT 3,0;"UN TROU AVEC UNE ECHELLE RIVEE DESCEND.IL Y<>A UNE VITRINE QUI DONNE SUR LA MER AVEC UN LEVIER."?3?TAN PRINT AT 8,4;"<22><><EFBFBD><EFBFBD><EFBFBD>";AT 21,6;"<22><><EFBFBD>";AT 14,0;"<22> <20>";AT 15,0;"<22> <20>";AT 16,0;" ";AT 9,3;"+";AT 18,3;"<22>"
|
||
8062 PRINT AT 19,6;"(O)"
|
||
8065 RETURN
|
||
8070 PRINT AT 3,0;"IL Y<>A UNE MOMIE COUCHEE.AU N. IL Y<>A UN LEVIER,UN BOUTON ET UNECRAN.A L<>O. UNE MANETTE."
|
||
8071 PRINT AT 18,14;"<22>";AT 15,14;"<22>";AT 16,14;"<22>";AT 14,1;"-";AT 8,6;"<22><>";AT 9,3;"+";AT 8,4;"<22>";AT 17,3;"O";AT 18,3;"=";AT 19,3;"="
|
||
8072 PRINT AT 20,10;"(O)"
|
||
8075 RETURN
|
||
8080 PRINT AT 3,0;"AU NORD IL Y<>A UNE PORTE AVEC UN CLAVIER.IL Y<>A UNE MACHINE QUI RONRONNE."
|
||
8081 PRINT AT 8,6;"<22><><EFBFBD>";AT 14,14;"<22>";AT 15,14;"<22>";AT 16,14;"<22>";AT 18,2;"-<2D>-";AT 19,3;"+";AT 8,5;"o";AT 20,5;"(O)"
|
||
8085 RETURN
|
||
9000 STOP
|
||
9010 CLS
|
||
9020 PRINT "NOMBRE D OBJETS?"
|
||
9030 INPUT O
|
||
9040 DIM Q(O)
|
||
9050 DIM O$(O,16)
|
||
9080 FOR X=1 TO O
|
||
9090 SCROLL
|
||
9100 PRINT "NO.";X;"SALLE?",
|
||
9110 INPUT Q(X)
|
||
9120 PRINT Q(X)
|
||
9130 SCROLL
|
||
9140 PRINT "DESCRIPTION?",
|
||
9150 INPUT O$(X)
|
||
9160 PRINT O$(X)
|
||
9170 NEXT X
|
||
9199 STOP
|
||
9200 CLS
|
||
9210 PRINT "NOMBRE DE MOTS?"
|
||
9220 INPUT V
|
||
9230 DIM V$(V,6)
|
||
9240 FOR X=1 TO V
|
||
9250 SCROLL
|
||
9260 INPUT V$(X)
|
||
9270 PRINT V$(X)
|
||
9280 NEXT X
|
||
9299 STOP
|
||
9300 CLS
|
||
9310 PRINT "NOMBRE DE SALLES?"
|
||
9320 INPUT R
|
||
9330 DIM M$(R,32)
|
||
9340 FOR X=1 TO R
|
||
9350 SCROLL
|
||
9360 INPUT M$(X)
|
||
9370 PRINT M$(X)
|
||
9380 NEXT X
|
||
9399 STOP
|
||
9400 CLS
|
||
9410 PRINT "NOMBRE DE CONDITIONSS?"
|
||
9420 INPUT C
|
||
9425 LET C=C+1
|
||
9430 DIM C$(C,21)
|
||
9440 FOR X=1 TO C-1
|
||
9450 SCROLL
|
||
9460 INPUT C$(X)
|
||
9470 PRINT C$(X)
|
||
9480 NEXT X
|
||
9490 LET C$(C)=".N."
|
||
9499 STOP
|
||
9500 CLS
|
||
9510 PRINT "NOMBRE D ACTIONS?"
|
||
9520 INPUT A
|
||
9530 DIM A$(A,31)
|
||
9540 FOR X=1 TO A
|
||
9550 SCROLL
|
||
9560 INPUT A$(X)
|
||
9570 PRINT A$(X)
|
||
9580 NEXT X
|
||
9599 STOP
|
||
9600 PRINT AT 8,0;"<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>";AT 21,0;"<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||
9610 FOR U=9 TO 20
|
||
9620 PRINT AT U,0;"<22> <20>"
|
||
9630 NEXT U
|
||
9640 RETURN
|
||
9700 PRINT "UN MANIAQUE,FOU ET SANS SCRUPU- LES VOUS A ENLEVE POUR VOUS FAI-RE TESTER:"
|
||
9710 PRINT AT 10,0;"<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>cauchemard<72>house<73><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
||
9720 PRINT AT 15,5;"(MAISON TRUFFEE DE PIEGES)"
|
||
9730 PRINT AT 21,0;"PRESSEZ UNE TOUCHE.."
|
||
9740 IF INKEY$="" THEN GOTO 9740
|
||
9745 CLS
|
||
9750 RETURN
|
||
9790 SAVE "p"
|
||
9791 CLS
|
||
9800 GOTO 1
|
||
|
||
# REM
|
||
9999 REM [HEX:\
|
||
00,00,00,00,00,00,00,00,\
|
||
00,00,00,00,00 ]
|
||
|