less copy protection, more size visualization
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 

185 строки
4.6 KiB

  1. function makeFen() {
  2. const views = {
  3. body: {
  4. attributes: {
  5. height: {
  6. name: "Height",
  7. power: 1,
  8. type: "length",
  9. base: math.unit(2.2428, "meter")
  10. },
  11. weight: {
  12. name: "Weight",
  13. power: 3,
  14. type: "mass",
  15. base: math.unit(124.738, "kg")
  16. }
  17. },
  18. image: {
  19. source: "./media/characters/fen/back.svg",
  20. bottom: 0.01,
  21. top: 0.93
  22. },
  23. name: "Body"
  24. },
  25. paw: {
  26. attributes: {
  27. height: {
  28. name: "Length",
  29. power: 1,
  30. type: "length",
  31. base: math.unit(20, "centimeter")
  32. },
  33. width: {
  34. name: "Length",
  35. power: 1,
  36. type: "length",
  37. base: math.unit(20, "centimeter")
  38. },
  39. area: {
  40. name: "Area",
  41. power: 2,
  42. type: "area",
  43. base: math.unit(0.04, "meter^2")
  44. }
  45. },
  46. image: {
  47. source: "./media/characters/generic/paw.svg"
  48. },
  49. name: "Paw"
  50. }
  51. };
  52. const entity = makeEntity("Fen", "Fen", views);
  53. entity.views.body.height = math.unit(1, "km");
  54. return entity;
  55. }
  56. function makeSofia() {
  57. const views = {
  58. front: {
  59. attributes: {
  60. height: {
  61. name: "Height",
  62. power: 1,
  63. type: "length",
  64. base: math.unit(183, "cm")
  65. },
  66. weight: {
  67. name: "Weight",
  68. power: 3,
  69. type: "mass",
  70. base: math.unit(80, "kg")
  71. }
  72. },
  73. image: {
  74. source: "./media/characters/sofia/front.svg"
  75. },
  76. name: "Front"
  77. },
  78. back: {
  79. attributes: {
  80. height: {
  81. name: "Height",
  82. power: 1,
  83. type: "length",
  84. base: math.unit(183, "cm")
  85. },
  86. weight: {
  87. name: "Weight",
  88. power: 3,
  89. type: "mass",
  90. base: math.unit(80, "kg")
  91. }
  92. },
  93. image: {
  94. source: "./media/characters/sofia/back.svg"
  95. },
  96. name: "Back"
  97. }
  98. };
  99. const entity = makeEntity("Sofia", "ZakuraTech", views);
  100. entity.views.front.height = math.unit(96, "feet");
  101. return entity;
  102. }
  103. function makeMarch() {
  104. const views = {
  105. front: {
  106. attributes: {
  107. height: {
  108. name: "Height",
  109. power: 1,
  110. type: "length",
  111. base: math.unit(7, "feet")
  112. },
  113. weight: {
  114. name: "Weight",
  115. power: 3,
  116. type: "mass",
  117. base: math.unit(100, "kg")
  118. }
  119. },
  120. image: {
  121. source: "./media/characters/march/front.svg"
  122. },
  123. name: "Front"
  124. }
  125. };
  126. const entity = makeEntity("March", "March-Dragon", views);
  127. entity.views.front.height = math.unit(2.98, "km");
  128. return entity;
  129. }
  130. function makeMan() {
  131. const views = {
  132. body: {
  133. attributes: {
  134. height: {
  135. name: "Height",
  136. power: 1,
  137. type: "length",
  138. base: math.unit(2, "meter")
  139. },
  140. weight: {
  141. name: "Weight",
  142. power: 3,
  143. type: "mass",
  144. base: math.unit(80, "kg")
  145. }
  146. },
  147. image: {
  148. source: "./man.svg"
  149. },
  150. name: "Body"
  151. }
  152. };
  153. return makeEntity("Man", "Fen", views);
  154. }
  155. function makeCharacters() {
  156. const results = [];
  157. results.push({
  158. name: "Fen",
  159. constructor: makeFen
  160. });
  161. results.push({
  162. name: "Sofia",
  163. constructor: makeSofia
  164. });
  165. results.push({
  166. name: "March",
  167. constructor: makeMarch
  168. });
  169. results.push({
  170. name: "Normal man",
  171. constructor: makeMan
  172. });
  173. return results;
  174. }