home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 159 / 159.d81 / hams.packer (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  3KB  |  71 lines

  1. 10 poke56,144:clr:dv=peek(2039):dimf$(254),f(255):poke53281,15:poke53280,15
  2. 15 print"[147]"
  3. 20 sys57812"menubox c000",dv,0:poke780,0:poke781,0:poke782,192:sys65493
  4. 30 sys57812"rle 9000",dv,0:poke780,0:poke781,0:poke782,144:sys65493
  5. 35 hx$="0123456789abcdef":ad=4864
  6. 37 restore:fori=1to8:readt:sys49152+3,0,39,0,24,t,0:forz=1to10:next:next
  7. 38 data 100,111,121,98,248,247,227,160
  8. 39 poke53281,0:print"[147]"
  9. 40 print"[147][158][200][193][205][211] [208]acker [205]odule":sys49152+63,0:sys49152+39,53248
  10. 41 print:print" [211]ource drive:"
  11. 42 fori=8to29:a$=str$(i):sys49152+42,a$,i-8,0:next
  12. 43 sys49152+57,15,20,2,10,0,3,1,7,0,21,0:sd=f%+8
  13. 60 open2,sd,2:close2:ifstthen40
  14. 61 sys49152+3,15,20,2,10,32,0
  15. 62 print"[158]"sd
  16. 80 print" [196]estination [196]rive:";:a$=str$(sd):sys49152+42,a$,sd-8,1
  17. 83 sys49152+57,20,25,4,12,0,3,1,7,0,21,0:dd=f%+8
  18. 100 open2,dd,2:close2:ifstthenprint"[145][145]":goto83
  19. 105 sys49152+3,20,25,4,12,32,0
  20. 110 print"[158]"dd
  21. 112 print" [205]ovie name: ";:sys49152+66,7,3,8,"":mv$=w$:ifmv$=""then250
  22. 115 mp$=mv$+left$("        ",8-len(mv$))
  23. 120 print"":sys49158,2,36,8,21,7:rem frame for file requestor
  24. 125 print"    [195][210][211][210]/[210][197][212][213][210][206] select - [211][208][193][195][197] exit"
  25. 130 open1,sd,15,"i0":close1:rem don't remove
  26. 140 sys49206,"$*",sd,53248:nf=f%:sys49212,3,9,20,1,3,1,7,1
  27. 145 fori=0tonf:sys49197,i:a=a+f%:next:ifa<>0then147
  28. 146 print"[147][206]o [198]iles [211]elected":print:goto250
  29. 147 print"[147][208]acking [198]rames"
  30. 150 fori=0tonf:sys49197,i
  31. 160 iff%<>0thenf=f+1:goto180
  32. 170 next:goto200
  33. 180 iff>255theni=nf:goto170
  34. 190 f$(f-1)=w$:hf=f-1:goto170
  35. 200 fori=0tohf:hf$=mid$(hx$,int(((i+1)/16)+1),1)+mid$(hx$,((i+1)and15)+1,1)
  36. 205 print""hf$" "f$(i)ad"to";:
  37. 207 f(i)=ad
  38. 210 sys36867,f$(i),sd,40960,mp$+hf$,dd,8192
  39. 211 ad=ad+(peek(253)+peek(254)*256)-53247:printad-1
  40. 215 ifad>53247thenprint"out of memory : stopped at frame"i+1:hf=i
  41. 220 open15,dd,15:input#15,a,b$,c,d
  42. 230 if a=0thenclose15:next:f(i)=ad:goto20000
  43. 240 print"[196]isk [197]rror:":print"[158]"a","b$","c","d:close15:end
  44. 250 print:print"[158][208]lease insert system disk in drive"dv:poke186,dv
  45. 252 print"[159]-[208]ress any key to continue-":poke198,0
  46. 254 geta$:ifa$=""then254
  47. 260 print"[147]";:poke56,160:clr:d=peek(186):load"b.hams menu",d:end
  48. 9999 stop
  49. 10000 d=peek(186):open1,d,15,"s:hams.packer":close1:save"hams.packer",d:end
  50. 20000 rem get usr.ani.data
  51. 20010 print"[147][198]rame [208]acking [195]ompleted[146]"
  52. 20015 print"[197]nter the animation background ";
  53. 20020 sys49152+66,7,3,2,"0":bgnd=val(w$)
  54. 20025 print"[197]nter the animation foreground ";
  55. 20030 sys49152+66,7,3,2,"1":fgnd=val(w$)
  56. 20035 print"[197]nter the delay (jiffies) ";
  57. 20040 sys49152+66,7,3,3,"16":d=val(w$):ifd>255thend=255
  58. 20045 cmask=bgnd+fgnd*16:cm$=chr$(cmask):nf$=chr$(hf+1):d$=chr$(d)
  59. 20050 rem wrt.data.tbl
  60. 20053 print"[147][215]riting data file[146]":print
  61. 20055 tbladr=4349:rem $10fd
  62. 20057 hb=int(tbladr/256):lb=tbladr-hb*256:hb$=chr$(hb):lb$=chr$(lb)
  63. 20058 open 2,dd,2,"hdat."+mv$+",p,w":print#2,lb$hb$nf$cm$d$;
  64. 20060 fori=0tohf+1:print"[193]dding frame "i+1
  65. 20070 hb=int(f(i)/256):lb=f(i)-hb*256:hb$=chr$(hb):lb$=chr$(lb)
  66. 20075 print#2,lb$hb$;:next:print#2,chr$(0):close2
  67. 20080 open15,dd,15:input#15,a,b$,c,d
  68. 20082 if a=0thenclose15:goto20100
  69. 20083 print:goto240
  70. 20100 close2:print"[198]inished!":print:goto250
  71.