#11 Article 2953 Posted at 1989/05/04 03:32:17 by Batcha (MAP541) [PRG.NL3]
Subject: FMR50/60 F-BASIC HG(ms-dos) NL3
んと、FMR50/60のためのBASICのNL3です。 時間とヒマがないので、Cにコンバートしてませんし、 誤差拡散ルーチンも省いてあります。 FM-77AVからの移植なんですけどね。あ、そうそう コンパイルするとタコるから注意してくださいね。 FBHGを利用しました。FBHGCPでは動作しません。 タイルパターンが汚いのをゆるしてね。 いまごろMAP541 Batcha 1000 ' 1010 ' Nozomu Loader 3 version 1.3 1988/3/27 1989/5/2 1020 ' 1030 ' arranger By B.Batcha 1040 ' 1050 defint A-S,X-Y:defsng V,Z:gosub *INITIALIZE 1060 width 80,25 : console 0,25,0 : cls 1070 color 4: print "File Name Select" 1080 color 7: line input"file name :";F$ 1090 if right$(F$,1)=":" then files F$ : goto 1080 1100 color 7: input "Graphics matrix(min0-max6):";H 1110 cls 'time$="00:00:00" 1120 open "I",1,F$ 1130 for I=0 to 63 1140 gosub *DATACONV 1150 A=DA 1160 gosub *DATACONV 1170 B=DA 1180 C=B*128+A: R=C\81: G=(C\9)mod 9: B=C mod 9 1190 for J=0 to 7 : K=J+8 1200 G%(I,J)=P%(G,J):R%(I,J)=P%(R,J):B%(I,J)=P%(B,J) 1210 G%(I,K)=Q%(G,J):R%(I,K)=Q%(R,J):B%(I,K)=Q%(B,J) 1220 next 1230 next I 1240 ' 1250 X=0 : Y=0 : C=0 1260 gosub *DATACONV 1270 if DA<64 then C=DA : L=0 : goto 1300 1280 C=DA and 63 1290 gosub *DATACONV : L=DA+1 1300 YA=L+Y : YB=YA-100 : if YA>99 then YA=99 1310 gosub *DRAWLINE 1320 if YB>=0 then Y=0 : X=X+1 : L=YB : if X<160 then 1300 1330 Y=YA+1 : if Y>99 then Y=0 : X=X+1 1340 if X>=160 then 1370 1350 goto 1260 1360 ' 1370 close 1380 A$=input$(1) : locate 0,14 : print "COMPLETE:";time$ 1390 end 1400 *INITIALIZE 1410 dim B%(64,16),R%(64,16),G%(64,16),P%(9,8),Q%(9,8),T%(255) 1420 for I=1 to 8 : read V : for J=0 to 7: Z=V+(V>32767)*65536! : P%(I,J)=Z : V=V*2 : V=V+(V>=65536!)*65535! : next J: next I 1430 for I=1 to 8 : read V : for J=0 to 7: Z=V+(V>32767)*65536! : Q%(I,J)=Z : V=V*2 : V=V+(V>=65536!)*65535! : next J: next I 1440 C=0 : for I=0 to 255 1450 if I<32 or( I>126 and I<160)or( I>223 and I<256) then T%(I)=-1:goto 1470 1460 T%(I)=C : C=C+1 1470 next 1480 return 1490 *DATACONV 1500 DA=T%(asc(input$(1,#1))):if DA>=0 then return else 1500 1510 ' 1520 *DRAWLINE 1530 G=H+1:for I=0 to H:MD=((X*G+I)mod 2)*8+((Y*G)mod 8) 1540 line@(X*G+I,Y*G)-(X*G+I,YA*G+H),or,3,b,B%(C,MD) 1550 line@(X*G+I,Y*G)-(X*G+I,YA*G+H),or,5,b,R%(C,MD) 1560 line@(X*G+I,Y*G)-(X*G+I,YA*G+H),or,9,b,G%(C,MD) 1570 next : return 1580 ' 1590 data &h0101,&h1111,&h1515,&h5555,&h5757,&h7777,&hfdfd,&hffff 1600 data &h1010,&h4444,&ha2a2,&haaaa,&hbaba,&hdddd,&hdfdf,&hffff 1610 ' 1620 ' original copyright NOZOMU in maple town net 1630 '