home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Commodore Disc 49
/
Commodore_Disc_49_19xx_-_de.d64
/
tabelle.64
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-10-26
|
11KB
|
440 lines
10 rem ========================64
20 rem (p) commodore disc ==
30 rem ==========================
40 rem (c) by ==
50 rem holger traczinski ==
60 rem ==
70 rem version 2.0 40z./ascii==
80 rem c-64 floppy ==
90 rem ==========================
95 gosub 60000
100 poke646,0:poke53280,13:poke53281,13
110 rem *** datas ***
120 rem 1.liga mannschaften
130 data werder bremen
140 data bayern muenchen
150 data 1.fc koeln
160 data vfb stuttgart
170 data 1.fc nuernberg
180 data hamburger sv
190 data bor. m'gladbach
200 data bayer leverkusen
210 data eintr. frankfurt
220 data hannover 96
230 data bayer uerdingen
240 data vfl bochum
250 data bor. dortmund
260 data 1.fc k'lautern
270 data karlsruher sc
280 data waldhof mannheim
290 data s'garter kickers
300 data fc st. pauli
310 rem 2.liga mannschaften
320 data fc homburg/saar
330 data fc schalke 04
340 data darmstadt 98
350 data wattenscheid 09
360 data for. duesseldorf
370 data alemannia aachen
380 data bw 90 berlin
390 data kickers off'bach
400 data vfl osnabrueck
410 data sc freiburg
420 data rot-weiss essen
430 data fortuna koeln
440 data 1.fc s'bruecken
450 data sv meppen
460 data union solingen
470 data rw oberhausen
480 data viktoria a'burg
490 data fsv mainz 05
500 data eintr. b'schweig
510 data hertha bsc b'lin
520 rem *** variable + sprung zum hauptmenu ***
530 dimm$(20,2):rem m$=mannschaften
540 dimppkt(20,2):rem ppkt=pluspunkte
550 dimmpkt(20,2):rem mpkt=minuspunkte
560 dimpt(20,2):rem pt=plustore
570 dimmt(20,2):remmt=minustore
580 dimdf(20,2):rem tordifferenz
590 dimhm$(19),am$(19),ht(19),at(19):rem heim-,auswaertsmanschaft,-tore
600 dims(20,2):dimg(20,2):dimu(20,2):dimv(20,2):remspiel,gewonn.,unent.,verlo.
610 printcl$
620 sch=18:lg=1:fori=1to18:readm$(i,1):nexti:fori=1to20:readm$(i,2):nexti
630 goto4040
640 rem *** ergebniseingabe ***
650 printcl$:w=0
660 ifsch=18thent=1
670 ifsch=20thent=10
680 print" w-andere mannschaften ; e-ende"
690 ifsch=18thenforz=1to9
700 ifsch=20thenforz=10to19
710 hm$(z)="":am$(z)="":ht(z)=0:at(z)=0
720 nextz
730 ifsch=18thenfori=1+wto9+w:goto760
740 ifsch=20thenfori=1+wto10+w
750 ifi=10ori=20thenprint" 0 - "m$(i,lg)" ":goto770
760 printi-w"- "m$(i,lg)" "
770 nexti
780 geta$:ifa$=""then780
790 ifa$="w"then820
800 ifa$="e"then1200
810 goto870
820 ifsch=18andw=0thenw=9:goto860
830 ifsch=18andw=9thenw=0
840 ifsch=20andw=0thenw=10:goto860
850 ifsch=20andw=10thenw=0
860 printhe$c4$:goto730
870 ifa$<>"1"anda$<>"2"anda$<>"3"anda$<>"4"anda$<>"5"anda$<>"6"thenq=1
880 ifq=1anda$<>"7"anda$<>"8"anda$<>"9"anda$<>"0"thenq=0:goto780
890 q=0
900 ifsch=18anda$="0"then780
910 ifsch=18thens1=9
920 ifsch=20thensp2=10
930 ifa$="0"thena=10
940 ifa$="1"thena=1
950 ifa$="2"thena=2
960 ifa$="3"thena=3
970 ifa$="4"thena=4
980 ifa$="5"thena=5
990 ifa$="6"thena=6
1000 ifa$="7"thena=7
1010 ifa$="8"thena=8
1020 ifa$="9"thena=9
1030 ift=1andm=0ort=10andm=0thenprint:goto1120
1040 ift=1andhm$(t)<>m$(a+w,lg)ort=10andhm$(t)<>m$(a+w,lg)thenprint:goto1120
1050 ift=1ort=10then780
1060 ifsch=18thenfori=1tot:ifhm$(i)=m$(a+w,lg)oram$(i)=m$(a+w,lg)then780
1070 ifsch=18thennexti
1080 ifsch=20thenfori=10tot:ifhm$(i)=m$(a+w,lg)oram$(i)=m$(a+w,lg)then780
1090 ifsch=20thennexti
1100 ifsch=18andt>1thenfork=1tot:print:nextk
1110 ifsch=20andt>10thenfork=1tot-9:print:nextk
1120 ifm=0thenhm$(t)=m$(a+w,lg):printhm$(t)"-":m=1:printhe$c4$:goto730
1130 ifm=1thenam$(t)=m$(a+w,lg):printtab(17)am$(t)
1140 printc2$tab(33):inputht(t)
1150 printc2$tab(33);ht(t)c1$":";:inputat(t)
1160 printc2$tab(33);ht(t)c1$":";at(t)c1$" ":m=0:t=t+1
1170 ifsch=18andt=10thengoto1250
1180 ifsch=20andt=20thengoto1250
1190 printhe$c4$:goto730
1200 ifm=1thenhm$(t)=""
1210 ifsch=18thens1=t-1
1220 ifsch=20thensp2=t-10
1230 ifsch=18andt>1thenfork=1tot:print:nextk
1240 ifsch=20andt>10thenfork=1tot-9:print:nextk
1250 print"umwandeln ?"
1260 geta$:ifa$=""then1260
1270 ifa$="n"thenreturn
1280 ifa$="j"thengoto1300
1290 goto1260
1300 rem *** ergebnisse umwandeln ***
1310 print"ich wandle um"
1320 ifsch=18thenforz=1tos1
1330 ifsch=20thenforz=10tosp2+9
1340 fori=1tosch
1350 ifm$(i,lg)=hm$(z)thenpt(i,lg)=pt(i,lg)+ht(z):mt(i,lg)=mt(i,lg)+at(z)
1360 ifm$(i,lg)=hm$(z)thendf(i,lg)=df(i,lg)+ht(z)-at(z):s(i,lg)=s(i,lg)+1:goto1380
1370 nexti:goto1420
1380 ifht(z)>at(z)thenppkt(i,lg)=ppkt(i,lg)+2:g(i,lg)=g(i,lg)+1
1390 ifht(z)=at(z)thenppkt(i,lg)=ppkt(i,lg)+1:mpkt(i,lg)=mpkt(i,lg)+1
1400 ifht(z)=at(z)thenu(i,lg)=u(i,lg)+1
1410 ifht(z)<at(z)thenmpkt(i,lg)=mpkt(i,lg)+2:v(i,lg)=v(i,lg)+1
1420 nextz
1430 ifsch=18thenforz=1tos1
1440 ifsch=20thenforz=10tosp2+9
1450 fori=1tosch
1460 ifm$(i,lg)=am$(z)thenpt(i,lg)=pt(i,lg)+at(z):mt(i,lg)=mt(i,lg)+ht(z)
1470 ifm$(i,lg)=am$(z)thendf(i,lg)=df(i,lg)+at(z)-ht(z):s(i,lg)=s(i,lg)+1:goto1490
1480 nexti:goto1530
1490 ifat(z)>ht(z)thenppkt(i,lg)=ppkt(i,lg)+2:g(i,lg)=g(i,lg)+1
1500 ifht(z)=at(z)thenppkt(i,lg)=ppkt(i,lg)+1:mpkt(i,lg)=mpkt(i,lg)+1
1510 ifht(z)=at(z)thenu(i,lg)=u(i,lg)+1
1520 ifat(z)<ht(z)thenmpkt(i,lg)=mpkt(i,lg)+2:v(i,lg)=v(i,lg)+1
1530 nextz
1540 rem *** tabelle sortieren ***
1550 print"ich sortiere..."
1560 vert=0
1570 fori=1tosch-1
1580 ifppkt(i,lg)>ppkt(i+1,lg)then1770
1590 ifppkt(i,lg)=ppkt(i+1,lg)andmpkt(i,lg)<mpkt(i+1,lg)then1770
1600 ifppkt(i,lg)=ppkt(i+1,lg)andmpkt(i,lg)=mpkt(i+1,lg)thenq=1
1610 ifq=1anddf(i,lg)>df(i+1,lg)thenq=0:goto1770
1620 q=0
1630 ifppkt(i,lg)=ppkt(i+1,lg)andmpkt(i,lg)=mpkt(i+1,lg)anddf(i,lg)=df(i+1,lg)thenq=1
1640 ifq=1anddf(i,lg)=df(i+1,lg)andpt(i,lg)>=pt(i+1,lg)thenq=0:goto1770
1650 q=0
1660 z$=m$(i,lg):z1=ppkt(i,lg):z2=mpkt(i,lg):z3=pt(i,lg)
1670 z4=mt(i,lg):z5=df(i,lg)
1680 z6=s(i,lg):z7=g(i,lg):z8=u(i,lg):z9=v(i,lg)
1690 m$(i,lg)=m$(i+1,lg):ppkt(i,lg)=ppkt(i+1,lg)
1700 mpkt(i,lg)=mpkt(i+1,lg)
1710 pt(i,lg)=pt(i+1,lg):mt(i,lg)=mt(i+1,lg):df(i,lg)=df(i+1,lg)
1720 s(i,lg)=s(i+1,lg):g(i,lg)=g(i+1,lg):u(i,lg)=u(i+1,lg):v(i,lg)=v(i+1,lg)
1730 m$(i+1,lg)=z$:ppkt(i+1,lg)=z1:mpkt(i+1,lg)=z2:pt(i+1,lg)=z3
1740 mt(i+1,lg)=z4
1750 df(i+1,lg)=z5:s(i+1,lg)=z6:g(i+1,lg)=z7:u(i+1,lg)=z8:v(i+1,lg)=z9
1760 vert=1
1770 nexti
1780 ifvert=1then1560
1790 return
1800 rem *** tabelle zeigen ***
1810 printcl$:poke53265,11
1820 ifsch=18thenprint" 1.liga:"
1830 ifsch=20thenprint" 2.liga:"
1840 print" tabelle: sp dif tore pkt "
1850 fori=1tosch
1860 ifi<10thenprint" "i;c1$"."m$(i,lg):goto1880
1870 printi;c1$"."m$(i,lg)
1880 x=s(i,lg):gosub2070
1890 printc2$tab(22-se);s(i,lg)
1900 x=df(i,lg):gosub2070
1910 ifx>0thenprintc2$tab(26-se);df(i,lg):printc2$tab(26-se)"+":goto1930
1920 printc2$tab(26-se);df(i,lg)
1930 x=pt(i,lg):gosub2070
1940 printc2$tab(29-se);pt(i,lg)
1950 x=mt(i,lg):gosub2070
1960 printc2$tab(32-se);mt(i,lg)
1970 x=ppkt(i,lg):gosub2070
1980 printc2$tab(35-se);ppkt(i,lg)
1990 x=mpkt(i,lg):gosub2070
2000 printc2$tab(38-se);mpkt(i,lg)
2010 printc2$c2$tab(30);":"
2020 printc2$tab(36);":"
2030 nexti
2040 poke53265,27
2050 geta$:ifa$=""then2050
2060 return
2070 rem *** stellenzahl ***
2080 se=0
2090 v=1:v1=-1
2100 ifx=0thense=1:return
2110 ifx>0andx<vthen2160
2120 ifx<0andx>v1then2160
2130 se=se+1
2140 v=v*10:v1=v1*10
2150 goto2110
2160 return
2170 rem *** tabelle abspeichern ***
2180 print"tabelle abspeichern"
2190 print"wirklich ?"
2200 geta$:ifa$=""then2200
2210 ifa$<>"j"thengoto4040
2220 nam$="tab"
2230 open15,8,15,"s:tab"
2240 close15
2250 open1,8,1,nam$
2260 fori=1to18
2270 print#1,m$(i,1):print#1,ppkt(i,1):print#1,mpkt(i,1)
2280 print#1,pt(i,1)
2290 print#1,mt(i,1):print#1,df(i,1):print#1,s(i,1):print#1,g(i,1)
2300 print#1,u(i,1):print#1,v(i,1)
2310 nexti
2320 fori=1to20
2330 print#1,m$(i,2):print#1,ppkt(i,2):print#1,mpkt(i,2)
2340 print#1,pt(i,2):print#1,mt(i,2):print#1,df(i,2):print#1,df(i,2)
2350 print#1,s(i,2):print#1,g(i,2):print#1,u(i,2):print#1,v(i,2):nexti
2360 close1
2370 return
2380 rem *** tabelle einlesen ***
2390 print"tabelle einlesen"
2400 nam$="tab"
2410 open1,8,0,nam$
2420 fori=1to18
2430 input#1,m$(i,1):input#1,ppkt(i,1):input#1,mpkt(i,1)
2440 input#1,pt(i,1)
2450 input#1,mt(i,1):input#1,df(i,1):input#1,s(i,1):input#1,g(i,1)
2460 input#1,u(i,1):input#1,v(i,1)
2470 nexti
2480 fori=1to20
2490 input#1,m$(i,2):input#1,ppkt(i,2):input#1,mpkt(i,2)
2500 input#1,pt(i,2):input#1,mt(i,2):input#1,df(i,2):input#1,df(i,2)
2510 input#1,s(i,2):input#1,g(i,2):input#1,u(i,2):input#1,v(i,2):nexti
2520 close1
2530 iflg=1thensch=18:return
2540 sch=20:return
2550 rem *** tabelle drucken ***
2560 print"schoenschrift?"
2570 geta$:ifa$=""then2570
2580 ifa$="j"thenss=31
2590 ifa$<>"j"thenss=159
2600 fori=1tosch
2610 print"ich drucke"
2620 open1,4
2630 ifsch=18thenk$=" (1.liga)"
2640 ifsch=20thenk$=" (2.liga)"
2650 print#1,chr$(ss)" tabelle";k$;" sp ge un ve tore ";
2660 print#1,chr$(ss)" dif punkte"
2670 fori=1tosch
2680 ifi<10thenprint#1," "i;". ";m$(i,lg);:goto2700
2690 print#1,i;". ";m$(i,lg);
2700 x=s(i,lg):gosub2070
2710 print#1,tab(24-len(m$(i,lg))-se);s(i,lg);
2720 x=g(i,lg):gosub2070
2730 print#1,tab(3-se);g(i,lg);
2740 x=u(i,lg):gosub2070
2750 print#1,tab(3-se);u(i,lg);
2760 x=v(i,lg):gosub2070
2770 print#1,tab(3-se);v(i,lg);
2780 x=pt(i,lg):gosub2070
2790 print#1,tab(3-se);pt(i,lg);":";
2800 x=mt(i,lg):gosub2070
2810 print#1,tab(2-se);mt(i,lg);
2820 x=df(i,lg):gosub2070
2830 print#1,tab(4-se);df(i,lg);
2840 x=ppkt(i,lg):gosub2070
2850 print#1,tab(4-se);ppkt(i,lg);":";
2860 x=mpkt(i,lg):gosub2070
2870 print#1,tab(2-se);mpkt(i,lg)
2880 nexti
2890 close1
2900 return
2910 rem *** ligen wechseln ***
2920 print"ich wechsel.";
2930 ifsch=18thenlg=2:sch=20:return
2940 sch=18:lg=1:return
2950 rem *** ende ***
2960 print"wirklich ?"
2970 geta$:ifa$=""then2970
2980 ifa$<>"j"thenreturn
2990 end
3000 rem *** ergebnisse zeigen ***
3010 printcl$:poke53265,11
3020 ifsch=18ands1<1thenreturn
3030 ifsch=20andsp2<1thenreturn
3040 ifsch=18thenforz=1tos1
3050 ifsch=20thenforz=10tosp2+9
3060 fori=1tosch
3070 ifhm$(z)=m$(i,lg)then3090
3080 nexti
3090 printm$(i,lg)"-";
3100 fori=1tosch
3110 ifam$(z)=m$(i,lg)then3130
3120 nexti
3130 printm$(i,lg)
3140 x=ht(z):gosub2070
3150 printc2$tab(34-se);ht(z)
3160 printc2$tab(35);at(z)
3170 printc2$tab(35)":"
3180 print:nextz:poke53265,27
3190 geta$:ifa$=""then3190
3200 return
3210 rem *** ergebnisse drucken ***
3220 ifsch=18ands1<1thenreturn
3230 ifsch=20andsp2<1thenreturn
3240 open1,4
3250 print"schoenschrift?"
3260 geta$:ifa$=""then3260
3270 ifa$="j"thenss=31
3280 ifa$<>"j"thenss=159
3290 ifsch=18thenforz=1tos1
3300 ifsch=20thenforz=10tosp2+9
3310 fori=1tosch
3320 ifhm$(z)=m$(i,lg)thenl=len(m$(i,lg)):goto3340
3330 nexti
3340 print#1,chr$(ss)" ";m$(i,lg);"-";
3350 fori=1tosch
3360 ifam$(z)=m$(i,lg)then3380
3370 nexti
3380 print#1,m$(i,lg);tab(42-l-len(m$(i,lg)));ht(z);":";at(z)
3390 nextz
3400 close1
3410 return
3420 rem *** ergebnisse aendern ***
3430 ifsch=18ands1<1thenreturn
3440 ifsch=20andsp2<1thenreturn
3450 printcl$
3460 print"a-endern oder e-nde"
3470 geta$:ifa$=""then3470
3480 ifa$="e"thengosub1540:return
3490 ifa$<>"a"then3470
3500 printcl$
3510 ifsch=18thenforz=1tos1
3520 ifsch=20thenforz=10tosp2+9
3530 printz;hm$(z)"-";am$(z)
3540 printc2$tab(33);ht(z)
3550 printc2$tab(35);at(z)
3560 printc2$tab(35)":"
3570 nextz
3580 print"welches spiel soll geaendert werden,"
3590 print"nummer ";:inputz
3600 ifsch=18andz>9orsch=18andz<1then3590
3610 ifsch=20andz<10orsch=20andz>19then3590
3620 ifsch=18andz>s1then3590
3630 ifsch=20andz>sp2then3590
3640 fori=1tosch
3650 ifm$(i,lg)=hm$(z)then3670
3660 nexti
3670 ifht(z)>at(z)thenppkt(i,lg)=ppkt(i,lg)-2:g(i,lg)=g(i,lg)-1
3680 ifht(z)=at(z)thenppkt(i,lg)=ppkt(i,lg)-1:mpkt(i,lg)=mpkt(i,lg)-1
3690 ifht(z)=at(z)thenu(i,lg)=u(i,lg)-1
3700 ifht(z)<at(z)thenmpkt(i,lg)=mpkt(i,lg)-2:v(i,lg)=v(i,lg)-1
3710 pt(i,lg)=pt(i,lg)-ht(z)
3720 mt(i,lg)=mt(i,lg)-at(z):df(i,lg)=df(i,lg)+at(z)-ht(z)
3730 fori=1tosch
3740 ifm$(i,lg)=am$(z)then3760
3750 nexti
3760 ifat(z)>ht(z)thenppkt(i,lg)=ppkt(i,lg)-2:g(i,lg)=g(i,lg)-1
3770 ifht(z)=at(z)thenppkt(i,lg)=ppkt(i,lg)-1:mpkt(i,lg)=mpkt(i,lg)-1
3780 ifht(z)=at(z)thenu(i,lg)=u(i,lg)-1
3790 ifat(z)<ht(z)thenmpkt(i,lg)=mpkt(i,lg)-2:v(i,lg)=v(i,lg)-1
3800 pt(i,lg)=pt(i,lg)-at(z)
3810 mt(i,lg)=mt(i,lg)-ht(z):df(i,lg)=df(i,lg)+ht(z)-at(z)
3820 printhm$(z)"-"am$(z)
3830 printc2$tab(33);:inputht(z)
3840 printc2$tab(33);ht(z)c1$":";:inputat(z)
3850 fori=1tosch
3860 ifm$(i,lg)=hm$(z)then3880
3870 nexti
3880 ifht(z)>at(z)thenppkt(i,lg)=ppkt(i,lg)+2:g(i,lg)=g(i,lg)+1
3890 ifht(z)=at(z)thenppkt(i,lg)=ppkt(i,lg)+1:mpkt(i,lg)=mpkt(i,lg)+1
3900 ifht(z)=at(z)thenu(i,lg)=u(i,lg)+1
3910 ifht(z)<at(z)thenmpkt(i,lg)=mpkt(i,lg)+2:v(i,lg)=v(i,lg)+1
3920 pt(i,lg)=pt(i,lg)+ht(z):mt(i,lg)=mt(i,lg)+at(z)
3930 df(i,lg)=df(i,lg)+ht(z)-at(z)
3940 fori=1tosch
3950 ifm$(i,lg)=am$(z)then3970
3960 nexti
3970 ifht(z)<at(z)thenppkt(i,lg)=ppkt(i,lg)+2:g(i,lg)=g(i,lg)+1
3980 ifht(z)=at(z)thenppkt(i,lg)=ppkt(i,lg)+1:mpkt(i,lg)=mpkt(i,lg)+1
3990 ifht(z)=at(z)thenu(i,lg)=u(i,lg)+1
4000 ifht(z)>at(z)thenmpkt(i,lg)=mpkt(i,lg)+2:v(i,lg)=v(i,lg)+1
4010 pt(i,lg)=pt(i,lg)+at(z):mt(i,lg)=mt(i,lg)+ht(z)
4020 df(i,lg)=df(i,lg)+at(z)-ht(z)
4030 goto3450
4040 rem *** menu ***
4050 printcl$
4060 poke53265,11
4070 iflg=1thenprint" 1.liga":goto4090
4080 print" 2.liga"
4090 print:print:print
4100 print" ergebnisse eingeben....1"
4110 print" ergebnisse zeigen......2"
4120 print" ergebnisse aendern.....3"
4130 print" ergebnisse drucken.....4"
4140 print" tabelle zeigen.........5"
4150 print" tabelle drucken........6"
4160 print" tabelle abspeichern....7"
4170 print" tabelle einlesen.......8"
4180 print" liga wechseln..........9"
4190 print" ende...................0"
4200 print:print:print:poke53265,27
4210 geta$:ifa$=""then4210
4220 ifa$="1"thengosub640
4230 ifa$="2"thengosub3000
4240 ifa$="3"thengosub3420
4250 ifa$="4"thengosub3210
4260 ifa$="5"thengosub1800
4270 ifa$="6"thengosub2550
4280 ifa$="7"thengosub2170
4290 ifa$="8"thengosub2380
4300 ifa$="9"thengosub2910
4310 ifa$="0"thengosub2950
4320 goto4040
60000 rem nachspann ===============
60010 rem * farbcodes/steuercodes *
60020 c4$=chr$(017):he$=chr$(019)
60030 c2$=chr$(145):cl$=chr$(147)
60040 c1$=chr$(157)
60050 return