User Tools

Site Tools


en:lokal_memory

LOKAL MEMORY

Info

Author Jose Miguel Ezquerro
Computer Amstrad PCW 8256 / 8512 / 9512
Year 1990
Gender Table
Controls Keyboard
Languages Spanish
Status Preserved

Screenshots

Description

This nice game will make us spend very pleasant hours in front of the computer trying to make pairs with the cards. But you have to pay close attention and remember the situation of the cards!

The game is designed to challenge our memory at the same time that we exercise it. The game is based on matching pairs of cards. Once we hit a pair the card will be unusable in a light color.

Listing

  • Listing - LOKAL.BAS
100 DEF FN CUR$(H,V)=CHR$(27)+"Y"+CHR$(32+V)+CHR$(32+H)
110 DEFINT a-Y
120 ce$=CHR$(27)+"e":PANTA=8
130 VI$=CHR$(27)+"p":VN$=CHR$(27)+"q"
140 CL$=CHR$(27)+"H"+CHR$(27)+"E":REM PRINT CHR$(27)"f"
150 plot=&HD500:circle=&HD503:linea=&HD506:box=&HD509:boxfill=&HD50C:fill=&HD50F
160 draw=&HD512:symbol=&HD515:ssave=&HD518:sload=&HD51B:window=&HD51E:symboldef=&HD521:border=&HD524:clg=&HD527:mode=&HD52A
170 ca$=CHR$(27)+"f"
180 PRINT CA$
190 PRINT CL$
200 pin$="":FOR t=1 TO 4:pin$=pin$+CHR$(85)+CHR$(170):NEXT t
210 pi2$="":FOR t=1 TO 8:pi2$=pi2$+CHR$(0):NEXT t
220 pi3$="":FOR t=1 TO 8:pi3$=pi3$+CHR$(255):NEXT t
230 PIT$(1)="":PIT$(0)=CHR$(7)
240 JOR$(1)="JUGADOR 1":JOR$(2)="JUGADOR 2":NIVEL=1:JOR$=JOR$(2)
250 GOSUB 1570
260 GOSUB 1180
270 GOSUB 460
280 X=1:Y=1:JOR=1
290 PRINT FN CUR$(3,21);VI$;" "JOR$(1)" ";VN$;FN CUR$(26,21);" PARES  0":IF JUGADORES=0 THEN PRINT FN CUR$(48,21);" "JOR$(2)" ";FN CUR$(70,21);" PARES  0"
300 IF JUGADORES=1 THEN PRINT FN CUR$(48,21);"N" DE JUGADAS:";FN CUR$(48,23);"% DE ACIERTOS:";FN CUR$(48,25);"N" DE FALLOS:";FNCUR$(48,27);"% DE FALLOS:"
310 X1=X*7+6:Y1=Y*5-1:PRINT FN CUR$(X1,Y1);"^":X5=X1:Y5=Y1
320 IF JOR$(JOR)="ORDENADOR" THEN GOSUB 1020:GOSUB 600:GOTO 320
330 IF JUGADORES=1 AND TIR<>0 AND TIRA=0 THEN ZTAC=PARES(1)*100/TIR:NFA=TIR-PARES(1):ZTAF=NFA*100/TIR
340 IF JUGADORES=1 AND TIRA=0 THEN PRINT FN CUR$(65,21);USING"###";TIR:PRINT FN CUR$(65,23);USING"###.##";ZTAC:PRINT FN CUR$(65,25);USING"###";NFA:PRINT FN CUR$(65,27);USING"###.##";ZTAF
350 WHILE INKEY$<>"":WEND:KKK=0:O$=INPUT$(1):IF CHR$(6)=O$ THEN KKK=1:X=X+1:IF x=11 THEN x=10:GOTO 350
360 IF O$=CHR$(1) THEN x=x-1:KKK=1:IF X=0 THEN X=1:GOTO 350
370 IF O$=CHR$(31) THEN Y=Y-1:KKK=1:IF Y=0 THEN Y=1:GOTO 350
380 IF O$=CHR$(30) THEN Y=Y+1:KKK=1:IF Y=5 THEN Y=4:GOTO 350
390 IF O$=" " THEN GOSUB 600
400 IF O$=CHR$(8) THEN PSOR(1,1)=3:PARES(1)=1:GOTO 930
410 IF O$=CHR$(21) THEN OUT 248,PANTA:IF PANTA=7 THEN PANTA=8 ELSE PANTA=7
420 IF KKK=0 THEN 320
430 X1=X*7+6:Y1=Y*5-1:PRINT FN CUR$(X1,Y1);"^"
440 PRINT FN CUR$(X5,Y5);" ":X5=X1:Y5=Y1
450 GOTO 320
460 REM ----------------------------------------------------
470 PRINT CL$
480 FOR t=1 TO 10:FOR j=1 TO 4
490 x=t*56+28:y=j*80-80:x1=x+46:y1=y+60:CALL boxfill(x,y,x1,y1,pin$)
500 NEXT j,t
510 FOR T=1 TO 10:FOR J=1 TO 4
520 s=INT(RND(1)*10)+1:s1=INT(RND(1)*4)+1
530 IF PS(s,s1)<>0 THEN 520
540 PS(S,S1)=T
550 NEXT J,T
560 X=5:Y=325:X1=355:Y1=478:CALL boxfill(X,Y,X1,Y1,PIN$):X=360:X1=716:CALL boxfill(X,Y,X1,Y1,PIN$)
570 X=15:Y=330:X1=340:Y1=359:CALL boxfill(X,Y,X1,Y1,PI2$):X=370:X1=706:CALL boxfill(X,Y,X1,Y1)
580 IF JUGADORES=1 THEN FOR G=1 TO 3:Y=330+32*G:Y1=Y+29:CALL boxfill(X,Y,X1,Y1,PI2$):NEXT G
590 RETURN
600 REM ----------------------------------------------------
610 IF SON=0 THEN FOR T=1 TO 5:OUT 248,11:OUT 248,12:NEXT T
620 IF PS(X,Y)=11 THEN PRINT PIT$(SON);:GOTO 710
630 IF X=HO AND Y=VE THEN PRINT PIT$(SON);:GOTO 710
640 TIRA=TIRA+1
650 IF JOR$(2)="ORDENADOR" THEN POI=INT(RND(1)*10)+1:IF POI<=NIVEL THEN PSOR(X,Y)=PS(X,Y)
660 xX=X*56+28:yY=Y*80-80:xX1=xX+46:yY1=yY+60:CALL boxfill(xX,yY,xX1,yY1,PI2$)
670 H=X1-1:V=Y1-3:CALL symbol(H,V,DIB$(PS(X,Y))):V2=Y1-2:CALL symbol(H,V2,DIB2$(PS(X,Y)))
680 IF PS(X,Y)=PS(HO,VE) THEN TIRA=0:TIR=TIR+1:GOSUB 760
690 IF TIRA=2 THEN TIRA=0:TIR=TIR+1:O$=INPUT$(1):CALL BOXFILL(XX,YY,XX1,YY1,PIN$):CALL BOXFILL(X0,Y0,X01,Y01,PIN$):HO=0:VE=0:GOTO 720
700 X0=XX:Y0=YY:X01=XX1:Y01=YY1:HO=X:VE=Y
710 RETURN
720 JR=JOR:IF JOR=1 THEN JOR=2 ELSE JOR=1
730 IF JUGADORES=1 THEN JOR=1
740 PRINT FN cur$(JOR^5.52+2,21);VI$;" "JOR$(JOR)" ";VN$:IF JUGADORES=0 THEN PRINT FN CUR$(JR^5.52+2,21);" "JOR$(JR)" "
750 GOTO 710
760 REM -----------------------------------------------------
770 IF SON=0 THEN FOR TJ=10 TO 1 STEP -1:FOR JT=1 TO JT:OUT 248,11:OUT 248,12:NEXT JT:FOR JJJK=1 TO 100:NEXT JJJK,TJ
780 PARES(JOR)=PARES(JOR)+1
790 PRINT FN CUR$(JOR^5.5+25,21);" PARES ";PARES(JOR)
800 IF JOR=1 THEN Q1=0 ELSE Q1=360
810 IF REV(JOR)=0 THEN REV(JOR)=2 ELSE REV(JOR)=0
820 SA=INT(PARES(JOR)/11):Q1=Q1+(PARES(JOR)-SA*10)*32-17:W1=371+SA*48+REV(JOR):Q2=Q1+40:W2=W1+52:CALL boxfill(Q1,W1,Q2,W2,PI2$):Q3=Q1/8+1:W3=24+SA*3:CALL SYMBOL(Q3,W3,DIB$(PS(X,Y))):W3=25+SA*3
830 CALL SYMBOL(Q3,W3,DIB2$(PS(X,Y)))
840 CALL BOXFILL(XX,YY,XX1,YY1,PI3$):CALL BOXFILL(X0,Y0,X01,Y01,PI3$):PS(X,Y)=11:PS(HO,VE)=11:PSOR(X,Y)=11:PSOR(HO,VE)=11
850 IF PARES(1)+PARES(2)=20 THEN 870
860 HO=0:VE=0:RETURN
870 IF PARES(1)>PARES(2) THEN GANADOR=1 ELSE IF PARES(1)=PARES(2) THEN GANADOR=0 ELSE GANADOR=2
880 PI$(1)=PIN$:PI$(2)=PI2$:PI$(3)=PI3$:C=0:FOR T=1 TO 5:C=C+1:IF C=4 THEN C=1
890 X=180+T*10:X1=540-T*10:Y=45+T*10:Y1=195-T*10:CALL boxfill(X,Y,X1,Y1,PI$(C)):NEXT T
900 IF JUGADORES=1 THEN 940
910 IF GANADOR=0 THEN PRINT FN CUR$(40,7);"  EMPATE  ":GOTO 930
920 A$="GANADOR: "+JOR$(GANADOR):B=LEN(A$):PRINT FN CUR$(45-B/2,7);A$
930 O$=INPUT$(1):ERASE PS,PARES,PSOR:TIR=0:NFA=0:ZTAC=0:ZTAF=0:TIRA=0:HO=0:VE=0:GOTO 260
940 ZTAC=PARES(1)*100/TIR:NFA=TIR-PARES(1):ZTAF=NFA*100/TIR
950 PRINT FN CUR$(65,21);USING"###";TIR:PRINT FN CUR$(65,23);USING"###.##";ZTAC:PRINT FN cur$(65,25);USING"###";NFA:PRINT FN CUR$(65,27);USING"###.##";ZTAF
960 IF ZTAC<20 THEN PRINT FN cur$(32,7);"BAJA, QUE ESTAS EN LAS NUBES":GOTO 930
970 IF ZTAC<40 THEN PRINT FN cur$(32,7);"ESTAS UN POCO DESPISTADILLO":GOTO 930
980 IF ZTAC<60 THEN PRINT FN cur$(33,7);"NO ESTA MAL, NO ESTA MAL":GOTO 930
990 IF ZTAC<80 THEN PRINT FN cur$(37,7);"MUY BIEN COLEGA":GOTO 930
1000 IF ZTAC<=100 THEN PRINT FN CUR$(29,7);"TE HAS PASADO, CEREBRO ANDANTE":GOTO 930
1010 END
1020 REM -----------------------------------------------------
1030 PRINT FN cur$(X1,Y1);" "
1040 VEZ=VEZ+1:IF VEZ=2 THEN 1110
1050 FOR M=1 TO 10:FOR N=1 TO 4:IF PSOR(M,N)<>0 AND PSOR(M,N)<>11 THEN DOS(PSOR(M,N))=DOS(PSOR(N,M))+1
1060 NEXT N,M
1070 FOR T=1 TO 10:IF DOS(T)>=2 THEN ULT=T:GOTO 1110 ELSE NEXT T
1080 X=INT(RND(1)*10)+1:Y=INT(RND(1)*4)+1:SORTEO=VEZ:IF PSOR(X,Y)<>0 OR (X=X9 AND Y=Y9) THEN 1080
1090 ULT=PS(X,Y)
1100 GOTO 1140
1110 FOR M=1 TO 10:FOR N=1 TO 4:IF PSOR(M,N)=ULT AND (M<>X9 OR N<>Y9) THEN PSOR=PSOR+1:X=M:Y=N:ULT=PS(X,Y):GOTO 1140
1120 NEXT N,M
1130 GOTO 1080
1140 X9=X:Y9=Y:IF VEZ=2 THEN VEZ=0:X9=0:Y9=0:ERASE DOS:ULT=0
1150 X1=X*7+6:Y1=Y*5-1:X5=X1:Y5=Y1
1160 PRINT FN cur$(X1,Y1);"^"
1170 RETURN
1180 REM ---------------------------------------------------------------------
1190 JUGADORES=0:GG=-4:SO$(0)="ON ":SO$(1)="OFF":K=1:PRINT CL$
1200 NIV$(1)="DESPISTADO  ":NIV$(3)="REGULAR     ":NIV$(5)="BUENO       ":NIV$(7)="EXCELENTE   ":NIV$(9)="SUPER DOTADO"
1210 OP$(1)="DOS JUGADORES":OP$(2)="JUGADOR-ORDENADOR":OP$(3)="UN JUGADOR":OP$(6)="CAMBIAR NOMBRES"
1220 X=250:Y=80:X1=500:Y1=320:CALL boxfill(X,Y,X1,Y1,PIN$)
1230 OP$(5)="NIVEL   "+NIV$(NIVEL):OP$(4)="SONIDO   "+SO$(SON):JK=35:FOR T=1 TO 6:IF K=T THEN PRINT VI$
1240 PRINT FN CUR$(JK,5+T*2);" "OP$(T)""VN$:NEXT T
1250 WHILE INKEY$<>"":WEND
1260 A$="LOCAL MEMORY   PROGRAMADO POR:  Jose Miguel Ezquerro"
1270 J1=1:J3=2:JJ=25:J2=26:K2=0:O$="":WHILE O$="":O$=INKEY$:KK=INT(RND(1)*10)+1
1280 GG=GG+1:IF INT(GG/4)<>GG/4 THEN 1390
1290 CALL symbol(GG,JJ,DIB$(KK)):CALL SYMBOL(GG,J2,DIB2$(KK))
1300 CALL SYMBOL(GG,J1,DIB$(KK)):CALL SYMBOL(GG,J3,DIB2$(KK))
1310 IF GG=84 THEN GG=-4
1320 C2=C2+1:IF C2<28 THEN TEX$=SPACE$(27-C2)+LEFT$(IZENA$,C2):GOTO 1350
1330 IF C2<77 THEN TEX$=MID$(IZENA$,C2-26,27)
1340 IF C2>58 AND C2<90 THEN C1=C1+1:TEX2$=SPACE$(31-C1)+LEFT$(IZENA$,C1):IF C2=89 THEN C2=0
1350 IF C1>30 AND C2<>0 THEN C1=C1+1:TEX2$=MID$(IZENA$,C1-30,31)
1360 IF C1>49 THEN TEX2$=TEX2$+" "
1370 IF C1=80 THEN C1=0
1380 PRINT FN cur$(63,12);TEX$" ":PRINT FN cur$(0,12);TEX2$
1390 WEND
1400 IF O$=CHR$(30) THEN K2=1:K=K+1:IF K=7 THEN K=1
1410 IF O$=CHR$(31) THEN K2=1:K=K-1:IF K=0 THEN K=6
1420 IF O$=CHR$(13) THEN ON K GOTO 1460,1480,1490,1500,1520,1540
1430 IF O$=CHR$(21) THEN OUT 248,PANTA:IF PANTA=7 THEN PANTA=8 ELSE PANTA=7
1440 IF K2=1 THEN 1230
1450 GOTO 1270
1460 IF JOR$(2)="ORDENADOR" THEN JOR$(2)=JOR$
1470 RETURN
1480 JOR$(2)="ORDENADOR":RETURN
1490 JUGADORES=1:RETURN
1500 IF SON=0 THEN SON=1 ELSE SON=0
1510 PRINT FN CUR$(JK,13);VI$;" SONIDO   "SO$(SON);VN$:GOTO 1270
1520 NIVEL=NIVEL+2:IF NIVEL=11 THEN NIVEL=1
1530 PRINT FN cur$(JK,15);VI$;" NIVEL   ";NIV$(NIVEL);VN$:GOTO 1270
1540 PRINT FN cur$(32,21);:INPUT "NOMBRE - JUGADOR 1 ";N$:JOR$(1)=LEFT$(N$,20):PRINT FN CUR$(32,21);SPACE$(50)
1550 PRINT FN CUR$(32,21);:INPUT "NOMBRE - JUGADOR 2 ";N$:JOR$(2)=LEFT$(N$,20):JOR$=JOR$(2)
1560 PRINT FN cur$(32,21);SPACE$(50):GOTO 1270
1570 ' ---------------------------------------------------------
1580 JK=24:TT=10
1590 FOR j=1 TO TT:FOR t=1 TO 24:READ d$:dib$(j)=dib$(j)+CHR$(VAL(d$)):NEXT t
1600 IF J<=TT THEN FOR t=1 TO JK:READ d$:dib2$(j)=dib2$(j)+CHR$(VAL(d$)):NEXT t
1610 NEXT J
1620 FOR TG=1 TO 49:READ A$:IZENA$=IZENA$+CHR$(VAL(A$)):NEXT TG
1630 DATA 0,15,63,127,255,255,255,255,0,129,231,255,255,255,255,255,0,240,28,206,231,199,143,255,127,63,31,7,1,0,0,0,255,255,255,255,255,126,24,0,254,252,248,224,128,0,0,0
1640 DATA 0,0,0,3,15,26,53,58,0,3,127,238,88,240,224,224,0,240,128,0,0,0,0,0,53,58,29,15,3,0,0,0,224,224,240,248,254,127,3,0,0,0,0,0,0,128,240,0
1650 DATA 0,0,0,1,1,28,127,255,0,60,199,159,207,255,255,255,0,0,0,128,128,56,254,255,255,127,28,0,0,0,1,0,255,255,126,126,126,255,255,0,255,254,56,0,0,0,128,0
1660 DATA 0,0,0,0,0,0,3,31,0,24,24,60,126,255,255,231,0,0,0,0,0,0,192,248,255,31,3,0,0,0,0,0,129,231,255,255,126,60,24,24,255,248,192,0,0,0,0,0
1670 DATA 0,0,0,0,0,1,1,3,7,12,24,60,255,255,255,255,0,0,0,0,0,128,128,192,15,28,56,56,56,30,7,0,63,63,255,255,255,127,255,255,240,248,252,252,252,248,224,0
1680 DATA 0,0,1,7,30,120,255,0,24,126,231,129,24,126,255,171,0,0,128,224,120,30,255,0,0,0,0,0,0,0,0,0,213,171,213,171,213,171,213,255,0,0,0,0,0,0,0,0
1690 DATA 0,2,1,96,16,3,239,15,8,8,9,0,126,255,255,255,0,128,24,32,1,198,240,240,15,15,99,128,24,97,2,0,255,255,255,126,0,17,16,16,247,240,198,1,16,12,128,0
1700 DATA 0,127,96,98,97,48,24,6,0,255,0,72,36,128,0,0,0,254,6,6,6,12,24,96,1,0,0,0,0,0,15,63,219,102,102,102,102,195,129,255,128,0,0,0,0,0,240,252
1710 DATA 63,24,12,6,3,1,1,1,255,0,0,0,42,149,203,231,252,24,48,96,192,128,128,128,1,1,1,3,6,12,24,63,231,211,137,16,8,20,170,255,128,128,128,192,96,48,152,252
1720 DATA 0,4,34,151,95,188,124,255,136,73,255,255,255,60,60,255,128,16,34,228,250,61,62,255,255,255,255,124,62,31,7,0,231,231,231,255,60,129,255,255,255,255,255,62,124,248,224,0
1730 DATA 76,79,75,65,76,32,77,69,77,79,82,89,32,32,80,114,111,103,114,97,109,97,100,111,32,112,111,114,58,32,74,111,115,101,32,77,105,103,117,101,108,32,69,122,107,101,114,114,111
1740 RETURN

Controls

       ↑ = UP
       ↓ = DOWN
       → = RIGHT
       ← = LEFT
   SPACE = SELECT

Loading the program

We have included in the disc the Mallard Basic extensions from Indescomp and Mallard Basic, with the disc auto-starting to make it easier for you to use the game.

 1.- Insert the disc that contains the Lokal Memory game and it will start automatically.
 2.- Write "EXTEN" and wait for the Mallard Basic Indescomp extension module to load.
 3.- Then type "Basic /M:&HD490" and press the "ENTER" key.
 4.- Type run "Lokal" and press the "ENTER" key

Extras

  • Listing of the program in a large circulation magazine of the time

lokal_memory_programa_01.jpg lokal_memory_programa_02.jpg lokal_memory_programa_03.jpg

Download

Video

en/lokal_memory.txt · Last modified: 2022/06/30 11:09 by jevicac