home *** CD-ROM | disk | FTP | other *** search
/ Dimension 64 5 / Dimension_64_Nr.05_19xx_-_de_Side_A.d64 / molekuel (.txt) < prev    next >
Commodore BASIC  |  2023-02-26  |  2KB  |  73 lines

  1. 5 print"bitte einen moment"
  2. 10 dim x(30),y(30),z(30),b(30,3),a$(30)
  3. 15 dim s(359),c(359)
  4. 20 a=6:x=159:y=99:z=0:wi=10:ve=20
  5. 25 fp=-500
  6. 30 for t=1 to a
  7. 35 read a$(t)
  8. 40 read x(t),y(t),z(t)
  9. 50 for i=0 to 3
  10. 60 read b:if b<0 then 90
  11. 70 b(t,i)=b
  12. 80 next i
  13. 90 next t
  14. 100 b=(NULL)/180:for t=0 to 359
  15. 110 s(t)=sin(t*b)
  16. 120 c(t)=cos(t*b)
  17. 130 next t
  18. 140 (NULL):(NULL)
  19. 150 rem *** gron:cls ***
  20. 190 (NULL) 1:gosub 1000
  21. 195 rem *** mode 1 ***
  22. 200 get a$:if a$="" then 200
  23. 210 (NULL) 0:gosub 1000
  24. 215 rem *** mode 0 ***
  25. 220 if a$="x" then w=wi:gosub 700:goto 400
  26. 230 if a$="[216]" then w=360-wi:gosub 700:goto 400
  27. 240 if a$="y" then w=wi:gosub 800:goto 400
  28. 250 if a$="[217]" then w=360-wi:gosub 800:goto 400
  29. 260 if a$="z" then w=wi:gosub 900:goto 400
  30. 270 if a$="[218]" then w=360-wi:gosub 900:goto 400
  31. 280 if a$="u" then y=y-ve:goto 400
  32. 290 if a$="m" then y=y+ve:goto 400
  33. 300 if a$="k" then x=x+ve:goto 400
  34. 310 if a$="h" then x=x-ve:goto 400
  35. 320 if a$="i" and z-100>fp then z=z-ve:goto 400
  36. 330 if a$="," then z=z+ve
  37. 400 (NULL) 1:gosub 1000:goto 200
  38. 405 rem *** mode 1 ***
  39. 700 for t=1 to a
  40. 710 e=-s(w)*z(t)+c(w)*y(t)
  41. 720 f=c(w)*z(t)+s(w)*y(t)
  42. 730 y(t)=e:z(t)=f
  43. 740 next t:return
  44. 800 for t=1 to a
  45. 810 d=c(w)*x(t)+s(w)*z(t)
  46. 820 f=-s(w)*x(t)+c(w)*z(t)
  47. 830 x(t)=d:z(t)=f
  48. 840 next t:return
  49. 900 for t=1 to a
  50. 910 d=c(w)*x(t)-s(w)*y(t)
  51. 920 e=s(w)*x(t)+c(w)*y(t)
  52. 930 x(t)=d:y(t)=e
  53. 940 next t:return
  54. 1000 for t=1 to a
  55. 1004 x1=x+x(t)*(1-(z+z(t))/fp)
  56. 1007 y1=y-y(t)*(1-(z+z(t))/fp)
  57. 1010 for i=0 to 3
  58. 1020 b=b(t,i)
  59. 1030 if b=0 then 1090
  60. 1080 (NULL) x1,y1,x+x(b)*(1-(z+z(b))/fp),y-y(b)*(1-(z+z(b))/fp)
  61. 1085 rem *** line ***
  62. 1090 next i
  63. 1100 (NULL) x1-3,y1-3,a$(t)
  64. 1105 rem *** text ***
  65. 1110 next t
  66. 1120 return
  67. 5000 data o,0,0,0,-1
  68. 5010 data c,-50,0,0,1,3,4,5
  69. 5020 data h,-71.665,47.15,0,-1
  70. 5030 data h,-71.665,-23.55,40.85,-1
  71. 5040 data h,-71.665,-23.55,-40.85,-1
  72. 5050 data h,14.7,-47.8,0,1,-1
  73.