home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Domination 18
/
Domination_18_The_Superbike_Project_v1.0_2003_Onslaught_Master_Disk.d64
/
musicdiscmaker
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2023-02-26
|
2KB
|
95 lines
1 bn=8192:bi=49152:rem bn $2000 bi $2900
2 dim q$(60):gosub5000
5 print"[147][205]usiche nel disco:"
6 dimc$(2,4)
10 open1,9,2,"$"
20 forx=1to253:get#1,a$:next
30 forp=1to8:get#1,t$,a$,a$
510 forl=0to15
520 get#1,a$
522 pokebn+16*n+l,42
530 ifa$<>chr$(96)thenifa$<>chr$(160)thenb$=b$+a$:ifathengosub1000
532 ifa$=">"thena=1:n=0
540 nextl
550 forl=1to9:get#1,a$:nextl
552 get#1,l$,h$
554 l=asc(l$+chr$(0))+256*asc(h$+chr$(0)):ifl=0thengoto590
560 ifstthenclose1:goto600
569 rem ifaandn>0thengosub2000
570 b$="":printq$(n): n=n+1
580 ifp<8thenget#1,a$,a$
590 nextp:
591 goto30
600 print"[147]ok ":rem sys20427
620 poke832,n-1: gosub 3000:gosub4070
999 end
1000 ifl=0or l>15 ora$="" thenreturn
1050 pokebn+16*n+l-1,asc(a$):q$(n)=q$(n)+a$
1060 rem poke1104+l-1,peek(bn+16*n+l-1)
1070 return
2000 print"[205]usica: [157][157][157][157][157][157][157][157][157][157][157][157][157][157]";n
2010 input"[201]nit address";a$
2020 input"[208]lay address";b$
2025 print" "
2030 printa$,b$
2031 c$(1,1)=mid$(a$,1,1):c$(1,2)=mid$(a$,2,1)
2040 c$(1,3)=mid$(a$,3,1):c$(1,4)=mid$(a$,4,1)
2050 c$(2,1)=mid$(b$,1,1):c$(2,2)=mid$(b$,2,1)
2060 c$(2,3)=mid$(b$,3,1):c$(2,4)=mid$(b$,4,1)
2070 for x=1to2:fory=1to4
2080 ifasc(c$(x,y))>64thenc$(x,y)=str$(asc(c$(x,y))-55)
2090 nexty:nextx
2100 li=val(c$(1,3))*16+val(c$(1,4))
2110 hi=val(c$(1,1))*16+val(c$(1,2))
2120 lr=val(c$(2,3))*16+val(c$(2,4))
2130 hr=val(c$(2,1))*16+val(c$(2,2))
2140 pokebi+8+xx*4,li:pokebi+9+xx*4,hi:pokebi+10+xx*4,lr:pokebi+11+xx*4,hr
2141 rem printbi+8+xx*4,bi+9+xx*4,bi+10+xx*4,bi+11+xx*4
2142 rem printpeek(bi+8+xx*4),peek(bi+9+xx*4)
2170 return
3000 rem scrivo dir
3005 print"scrivo dir"
3010 open5,9,5,"@:dir,p,w"
3020 print#5,chr$(0);chr$(160);
3030 forx=0ton-1
3032 fory=0to15
3040 print#5,chr$(peek(bn+x*16+y));
3050 nexty,x
3060 close5
3065 return
3070 rem scrivo info
3105 print"scrivo info"
3110 open5,9,5,"@:info,p,w"
3120 print#5,chr$(255);chr$(168);
3130 print#5,chr$(n-1);
3140 print#5,chr$(76);chr$(0);chr$(16);chr$(76);chr$(3);chr$(16);chr$(0);
3150 print#5,chr$(0);
3160 forx=0ton-1
3162 fory=0to3
3170 print#5,chr$(peek(bi+8+y+x*4));
3180 nexty,x
3190 close5
3200 print"[200]o finito":end
4070 rem leggo info
4100 forxx=1ton-1
4105 a$="":b$="": print:print"leggo info di ";q$(xx)
4110 open5,10,5,q$(xx)+"*,p,r"
4120 get#5,z$
4130 ifz$=""thengoto4120
4140 if z$=","andf=0thengosub4300:a$=w$
4144 if z$=","and f=1thengosub4300:b$=w$
4148 iff=2thenf=0:close5:gosub2030:nextxx:goto4200
4150 goto4120
4200 goto3070
4300 w$="":foryy=0to3:get#5,z$
4302 ifasc(z$)>=97 thenz$=chr$(asc(z$)-32)
4308 w$=w$+z$:nextyy:f=f+1:return
4322 foryy=0to3:get#5,z$:b$=b$+z$:nextyy:printb$:f=f+1:return
5000 rem istruzioni
5010 print"[147]"
5020 print"drive 8: master disc"
5030 print"drive 9: music disc"
5040 print"drive 10: info disc"
5050 geta$:ifa$=""thengoto5050
5060 return