melonjs 20.7.0 → 20.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (332) hide show
  1. package/README.md +7 -3
  2. package/build/application/application.d.ts +66 -8
  3. package/build/application/application.d.ts.map +1 -1
  4. package/build/application/defaultApplicationSettings.d.ts +6 -0
  5. package/build/application/defaultApplicationSettings.d.ts.map +1 -1
  6. package/build/application/header.d.ts.map +1 -1
  7. package/build/application/resize.d.ts +25 -0
  8. package/build/application/resize.d.ts.map +1 -1
  9. package/build/application/scaleMethods.d.ts +13 -3
  10. package/build/application/scaleMethods.d.ts.map +1 -1
  11. package/build/application/settings.d.ts +144 -5
  12. package/build/application/settings.d.ts.map +1 -1
  13. package/build/audio/audio.d.ts +29 -5
  14. package/build/audio/audio.d.ts.map +1 -1
  15. package/build/audio/autopause.d.ts +36 -0
  16. package/build/audio/autopause.d.ts.map +1 -0
  17. package/build/audio/backend/engine.d.ts +10 -1
  18. package/build/audio/backend/engine.d.ts.map +1 -1
  19. package/build/audio/backend/sound.d.ts +0 -1
  20. package/build/audio/backend/sound.d.ts.map +1 -1
  21. package/build/audio/backend/spatial.d.ts.map +1 -1
  22. package/build/audio/context.d.ts +35 -0
  23. package/build/audio/context.d.ts.map +1 -0
  24. package/build/audio/playback.d.ts.map +1 -1
  25. package/build/audio/procedural.d.ts.map +1 -1
  26. package/build/audio/spatial.d.ts +87 -0
  27. package/build/audio/spatial.d.ts.map +1 -0
  28. package/build/audio/state.d.ts +1 -0
  29. package/build/audio/state.d.ts.map +1 -1
  30. package/build/audio/types.d.ts +46 -6
  31. package/build/audio/types.d.ts.map +1 -1
  32. package/build/camera/camera2d.d.ts.map +1 -1
  33. package/build/camera/camera3d.d.ts +95 -8
  34. package/build/camera/camera3d.d.ts.map +1 -1
  35. package/build/camera/effects/fade_effect.d.ts.map +1 -1
  36. package/build/camera/effects/mask_effect.d.ts.map +1 -1
  37. package/build/camera/effects/shake_effect.d.ts.map +1 -1
  38. package/build/geometries/box3d.d.ts +25 -7
  39. package/build/geometries/box3d.d.ts.map +1 -1
  40. package/build/geometries/ellipse.d.ts +15 -1
  41. package/build/geometries/ellipse.d.ts.map +1 -1
  42. package/build/geometries/line.d.ts +1 -1
  43. package/build/geometries/line.d.ts.map +1 -1
  44. package/build/geometries/point.d.ts +1 -1
  45. package/build/geometries/point.d.ts.map +1 -1
  46. package/build/geometries/polygon.d.ts +15 -1
  47. package/build/geometries/polygon.d.ts.map +1 -1
  48. package/build/geometries/rectangle.d.ts +1 -1
  49. package/build/geometries/rectangle.d.ts.map +1 -1
  50. package/build/geometries/roundrect.d.ts +1 -1
  51. package/build/geometries/roundrect.d.ts.map +1 -1
  52. package/build/geometries/sphere.d.ts +36 -7
  53. package/build/geometries/sphere.d.ts.map +1 -1
  54. package/build/index.d.ts +16 -3
  55. package/build/index.d.ts.map +1 -1
  56. package/build/index.js +38172 -33633
  57. package/build/index.js.map +4 -4
  58. package/build/input/gamepad.d.ts +129 -3
  59. package/build/input/gamepad.d.ts.map +1 -1
  60. package/build/input/pointerevent.d.ts +8 -0
  61. package/build/input/pointerevent.d.ts.map +1 -1
  62. package/build/level/gltf/GLTFModel.d.ts +20 -33
  63. package/build/level/gltf/GLTFModel.d.ts.map +1 -1
  64. package/build/level/gltf/GLTFScene.d.ts +40 -1
  65. package/build/level/gltf/GLTFScene.d.ts.map +1 -1
  66. package/build/level/level.d.ts +35 -0
  67. package/build/level/level.d.ts.map +1 -1
  68. package/build/level/tiled/TMXLayer.d.ts +5 -2
  69. package/build/level/tiled/TMXLayer.d.ts.map +1 -1
  70. package/build/level/tiled/TMXObject.d.ts +0 -1
  71. package/build/level/tiled/TMXObjectFactory.d.ts +3 -2
  72. package/build/level/tiled/TMXObjectFactory.d.ts.map +1 -1
  73. package/build/level/tiled/TMXTile.d.ts +2 -1
  74. package/build/level/tiled/TMXTile.d.ts.map +1 -1
  75. package/build/level/tiled/TMXTileMap.d.ts +7 -4
  76. package/build/level/tiled/TMXTileMap.d.ts.map +1 -1
  77. package/build/level/tiled/TMXTileset.d.ts +1 -1
  78. package/build/level/tiled/TMXTileset.d.ts.map +1 -1
  79. package/build/level/tiled/TMXTilesetGroup.d.ts +5 -0
  80. package/build/level/tiled/TMXTilesetGroup.d.ts.map +1 -1
  81. package/build/level/tiled/factories/shape.d.ts +0 -1
  82. package/build/level/tiled/renderer/TMXHexagonalRenderer.d.ts +6 -5
  83. package/build/level/tiled/renderer/TMXHexagonalRenderer.d.ts.map +1 -1
  84. package/build/level/tiled/renderer/TMXIsometricRenderer.d.ts +5 -0
  85. package/build/level/tiled/renderer/TMXIsometricRenderer.d.ts.map +1 -1
  86. package/build/level/tiled/renderer/TMXObliqueRenderer.d.ts +5 -7
  87. package/build/level/tiled/renderer/TMXObliqueRenderer.d.ts.map +1 -1
  88. package/build/level/tiled/renderer/TMXOrthogonalRenderer.d.ts +5 -0
  89. package/build/level/tiled/renderer/TMXOrthogonalRenderer.d.ts.map +1 -1
  90. package/build/level/tiled/renderer/TMXRenderer.d.ts +19 -4
  91. package/build/level/tiled/renderer/TMXRenderer.d.ts.map +1 -1
  92. package/build/level/tiled/renderer/autodetect.d.ts +0 -4
  93. package/build/level/tiled/renderer/autodetect.d.ts.map +1 -1
  94. package/build/loader/cache.d.ts +220 -0
  95. package/build/loader/cache.d.ts.map +1 -1
  96. package/build/loader/loader.d.ts +20 -340
  97. package/build/loader/loader.d.ts.map +1 -1
  98. package/build/loader/loadingscreen.d.ts +1 -2
  99. package/build/loader/loadingscreen.d.ts.map +1 -1
  100. package/build/loader/parsers/gltf.d.ts +115 -0
  101. package/build/loader/parsers/gltf.d.ts.map +1 -1
  102. package/build/loader/parsers/shader.d.ts +0 -2
  103. package/build/math/color.d.ts +28 -5
  104. package/build/math/color.d.ts.map +1 -1
  105. package/build/math/matrix2d.d.ts +1 -1
  106. package/build/math/matrix2d.d.ts.map +1 -1
  107. package/build/math/matrix3d.d.ts +1 -1
  108. package/build/math/matrix3d.d.ts.map +1 -1
  109. package/build/math/observableVector2d.d.ts +14 -2
  110. package/build/math/observableVector2d.d.ts.map +1 -1
  111. package/build/math/observableVector3d.d.ts +15 -1
  112. package/build/math/observableVector3d.d.ts.map +1 -1
  113. package/build/math/vector2d.d.ts +31 -1
  114. package/build/math/vector2d.d.ts.map +1 -1
  115. package/build/math/vector3d.d.ts +38 -1
  116. package/build/math/vector3d.d.ts.map +1 -1
  117. package/build/math/vertex.d.ts.map +1 -1
  118. package/build/particles/emitter.d.ts.map +1 -1
  119. package/build/particles/particle.d.ts +29 -2
  120. package/build/particles/particle.d.ts.map +1 -1
  121. package/build/particles/settings.d.ts +104 -0
  122. package/build/particles/settings.d.ts.map +1 -1
  123. package/build/physics/adapter.d.ts +9 -1
  124. package/build/physics/adapter.d.ts.map +1 -1
  125. package/build/physics/bounds.d.ts +1 -1
  126. package/build/physics/bounds.d.ts.map +1 -1
  127. package/build/physics/broadphase/octree.d.ts +24 -0
  128. package/build/physics/broadphase/octree.d.ts.map +1 -1
  129. package/build/physics/broadphase/quadtree.d.ts +31 -0
  130. package/build/physics/broadphase/quadtree.d.ts.map +1 -1
  131. package/build/physics/builtin/body.d.ts +17 -2
  132. package/build/physics/builtin/body.d.ts.map +1 -1
  133. package/build/physics/builtin/builtin-adapter.d.ts.map +1 -1
  134. package/build/physics/builtin/detector.d.ts +0 -1
  135. package/build/physics/builtin/detector.d.ts.map +1 -1
  136. package/build/physics/builtin/sat.d.ts +0 -7
  137. package/build/physics/builtin/sat3d.d.ts +46 -0
  138. package/build/physics/builtin/sat3d.d.ts.map +1 -1
  139. package/build/physics/response.d.ts +45 -62
  140. package/build/physics/response.d.ts.map +1 -1
  141. package/build/pool.d.ts +4 -0
  142. package/build/pool.d.ts.map +1 -1
  143. package/build/renderable/collectable.d.ts +6 -1
  144. package/build/renderable/collectable.d.ts.map +1 -1
  145. package/build/renderable/colorlayer.d.ts +17 -4
  146. package/build/renderable/colorlayer.d.ts.map +1 -1
  147. package/build/renderable/container.d.ts +23 -17
  148. package/build/renderable/container.d.ts.map +1 -1
  149. package/build/renderable/entity/entity.d.ts +12 -16
  150. package/build/renderable/entity/entity.d.ts.map +1 -1
  151. package/build/renderable/frameAnimation.d.ts +1 -1
  152. package/build/renderable/groundshadow.d.ts +1 -0
  153. package/build/renderable/groundshadow.d.ts.map +1 -1
  154. package/build/renderable/imagelayer.d.ts +12 -5
  155. package/build/renderable/imagelayer.d.ts.map +1 -1
  156. package/build/renderable/instanced_mesh.d.ts +56 -7
  157. package/build/renderable/instanced_mesh.d.ts.map +1 -1
  158. package/build/renderable/mesh.d.ts +369 -4
  159. package/build/renderable/mesh.d.ts.map +1 -1
  160. package/build/renderable/nineslicesprite.d.ts +3 -13
  161. package/build/renderable/nineslicesprite.d.ts.map +1 -1
  162. package/build/renderable/renderable.d.ts +129 -28
  163. package/build/renderable/renderable.d.ts.map +1 -1
  164. package/build/renderable/sprite.d.ts +7 -20
  165. package/build/renderable/sprite.d.ts.map +1 -1
  166. package/build/renderable/sprite3d.d.ts +31 -16
  167. package/build/renderable/sprite3d.d.ts.map +1 -1
  168. package/build/renderable/text/bitmaptext.d.ts +76 -5
  169. package/build/renderable/text/bitmaptext.d.ts.map +1 -1
  170. package/build/renderable/text/bitmaptextdata.d.ts +1 -5
  171. package/build/renderable/text/bitmaptextdata.d.ts.map +1 -1
  172. package/build/renderable/text/glypheffect.d.ts +44 -0
  173. package/build/renderable/text/glypheffect.d.ts.map +1 -0
  174. package/build/renderable/text/text.d.ts +22 -3
  175. package/build/renderable/text/text.d.ts.map +1 -1
  176. package/build/renderable/text/textmetrics.d.ts +2 -0
  177. package/build/renderable/text/textmetrics.d.ts.map +1 -1
  178. package/build/renderable/trail.d.ts +0 -1
  179. package/build/renderable/trail.d.ts.map +1 -1
  180. package/build/renderable/trail3d.d.ts +174 -0
  181. package/build/renderable/trail3d.d.ts.map +1 -0
  182. package/build/renderable/trigger.d.ts +28 -5
  183. package/build/renderable/trigger.d.ts.map +1 -1
  184. package/build/renderable/ui/panelpaint.d.ts +5 -0
  185. package/build/renderable/ui/panelpaint.d.ts.map +1 -0
  186. package/build/renderable/ui/progressbar.d.ts +192 -0
  187. package/build/renderable/ui/progressbar.d.ts.map +1 -0
  188. package/build/renderable/ui/uibaseelement.d.ts +48 -3
  189. package/build/renderable/ui/uibaseelement.d.ts.map +1 -1
  190. package/build/renderable/ui/uipanel.d.ts +245 -0
  191. package/build/renderable/ui/uipanel.d.ts.map +1 -0
  192. package/build/renderable/ui/uispriteelement.d.ts +19 -3
  193. package/build/renderable/ui/uispriteelement.d.ts.map +1 -1
  194. package/build/renderable/ui/uitextbutton.d.ts +30 -1
  195. package/build/renderable/ui/uitextbutton.d.ts.map +1 -1
  196. package/build/state/state.d.ts.map +1 -1
  197. package/build/system/bootstrap.d.ts.map +1 -1
  198. package/build/system/legacy_pool.d.ts +24 -4
  199. package/build/system/legacy_pool.d.ts.map +1 -1
  200. package/build/system/pool.d.ts +15 -8
  201. package/build/system/pool.d.ts.map +1 -1
  202. package/build/tweens/tween.d.ts +50 -3
  203. package/build/tweens/tween.d.ts.map +1 -1
  204. package/build/video/canvas/canvas_renderer.d.ts +34 -23
  205. package/build/video/canvas/canvas_renderer.d.ts.map +1 -1
  206. package/build/video/effects/blendEffect.d.ts +0 -1
  207. package/build/video/effects/bloom.d.ts +72 -0
  208. package/build/video/effects/bloom.d.ts.map +1 -0
  209. package/build/video/effects/blur.d.ts +3 -2
  210. package/build/video/effects/blur.d.ts.map +1 -1
  211. package/build/video/effects/chromaticAberration.d.ts +3 -2
  212. package/build/video/effects/chromaticAberration.d.ts.map +1 -1
  213. package/build/video/effects/colorMatrix.d.ts +3 -2
  214. package/build/video/effects/colorMatrix.d.ts.map +1 -1
  215. package/build/video/effects/desaturate.d.ts +10 -2
  216. package/build/video/effects/desaturate.d.ts.map +1 -1
  217. package/build/video/effects/dissolve.d.ts +3 -2
  218. package/build/video/effects/dissolve.d.ts.map +1 -1
  219. package/build/video/effects/dropShadow.d.ts +3 -2
  220. package/build/video/effects/dropShadow.d.ts.map +1 -1
  221. package/build/video/effects/flash.d.ts +3 -2
  222. package/build/video/effects/flash.d.ts.map +1 -1
  223. package/build/video/effects/glow.d.ts +3 -2
  224. package/build/video/effects/glow.d.ts.map +1 -1
  225. package/build/video/effects/hologram.d.ts +3 -2
  226. package/build/video/effects/hologram.d.ts.map +1 -1
  227. package/build/video/effects/invert.d.ts +10 -2
  228. package/build/video/effects/invert.d.ts.map +1 -1
  229. package/build/video/effects/outline.d.ts +3 -2
  230. package/build/video/effects/outline.d.ts.map +1 -1
  231. package/build/video/effects/pixelate.d.ts +3 -2
  232. package/build/video/effects/pixelate.d.ts.map +1 -1
  233. package/build/video/effects/radialGradient.d.ts +8 -3
  234. package/build/video/effects/radialGradient.d.ts.map +1 -1
  235. package/build/video/effects/scanline.d.ts +3 -2
  236. package/build/video/effects/scanline.d.ts.map +1 -1
  237. package/build/video/effects/sepia.d.ts +10 -2
  238. package/build/video/effects/sepia.d.ts.map +1 -1
  239. package/build/video/effects/shadereffect.d.ts +10 -4
  240. package/build/video/effects/shadereffect.d.ts.map +1 -1
  241. package/build/video/effects/shine.d.ts +3 -2
  242. package/build/video/effects/shine.d.ts.map +1 -1
  243. package/build/video/effects/tintPulse.d.ts +3 -7
  244. package/build/video/effects/tintPulse.d.ts.map +1 -1
  245. package/build/video/effects/tonemap.d.ts +121 -0
  246. package/build/video/effects/tonemap.d.ts.map +1 -0
  247. package/build/video/effects/vignette.d.ts +3 -2
  248. package/build/video/effects/vignette.d.ts.map +1 -1
  249. package/build/video/effects/wave.d.ts +3 -7
  250. package/build/video/effects/wave.d.ts.map +1 -1
  251. package/build/video/gpu/batcher.d.ts +8 -2
  252. package/build/video/gpu/batcher.d.ts.map +1 -1
  253. package/build/video/gpu/vertexformat.d.ts +26 -0
  254. package/build/video/gpu/vertexformat.d.ts.map +1 -1
  255. package/build/video/gradient.d.ts +1 -1
  256. package/build/video/gradient.d.ts.map +1 -1
  257. package/build/video/renderer.d.ts +111 -7
  258. package/build/video/renderer.d.ts.map +1 -1
  259. package/build/video/renderstate.d.ts +2 -0
  260. package/build/video/renderstate.d.ts.map +1 -1
  261. package/build/video/rendertarget/canvasrendertarget.d.ts +3 -4
  262. package/build/video/rendertarget/canvasrendertarget.d.ts.map +1 -1
  263. package/build/video/rendertarget/render_target_pool.d.ts +0 -1
  264. package/build/video/rendertarget/rendertarget.d.ts +12 -5
  265. package/build/video/rendertarget/rendertarget.d.ts.map +1 -1
  266. package/build/video/rendertarget/webglrendertarget.d.ts +0 -1
  267. package/build/video/rendertarget/webglrendertarget.d.ts.map +1 -1
  268. package/build/video/rendertarget/webgpurendertarget.d.ts +24 -14
  269. package/build/video/rendertarget/webgpurendertarget.d.ts.map +1 -1
  270. package/build/video/texture/atlas.d.ts +2 -1
  271. package/build/video/texture/atlas.d.ts.map +1 -1
  272. package/build/video/texture/cache.d.ts +1 -3
  273. package/build/video/texture/frametexture.d.ts +0 -1
  274. package/build/video/texture/frametexture.d.ts.map +1 -1
  275. package/build/video/texture/noise_texture2d.d.ts +1 -0
  276. package/build/video/texture/noise_texture2d.d.ts.map +1 -1
  277. package/build/video/texture/texture2d.d.ts +6 -0
  278. package/build/video/texture/texture2d.d.ts.map +1 -1
  279. package/build/video/utils/autodetect.d.ts +0 -2
  280. package/build/video/webgl/batchers/batcher.d.ts +0 -9
  281. package/build/video/webgl/batchers/batcher.d.ts.map +1 -1
  282. package/build/video/webgl/batchers/lit_quad_batcher.d.ts +2 -0
  283. package/build/video/webgl/batchers/lit_quad_batcher.d.ts.map +1 -1
  284. package/build/video/webgl/batchers/material_batcher.d.ts +4 -2
  285. package/build/video/webgl/batchers/material_batcher.d.ts.map +1 -1
  286. package/build/video/webgl/batchers/mesh_batcher.d.ts +0 -3
  287. package/build/video/webgl/batchers/mesh_batcher.d.ts.map +1 -1
  288. package/build/video/webgl/batchers/quad_batcher.d.ts +4 -0
  289. package/build/video/webgl/batchers/quad_batcher.d.ts.map +1 -1
  290. package/build/video/webgl/buffer/index.d.ts +0 -1
  291. package/build/video/webgl/buffer/retained_geometry.d.ts +0 -1
  292. package/build/video/webgl/glshader.d.ts +5 -3
  293. package/build/video/webgl/glshader.d.ts.map +1 -1
  294. package/build/video/webgl/renderers/tmxlayer/orthogonal.d.ts +0 -4
  295. package/build/video/webgl/texture/store.d.ts +0 -1
  296. package/build/video/webgl/webgl_renderer.d.ts +63 -24
  297. package/build/video/webgl/webgl_renderer.d.ts.map +1 -1
  298. package/build/video/webgpu/batchers/mesh_batcher.d.ts +0 -3
  299. package/build/video/webgpu/batchers/mesh_batcher.d.ts.map +1 -1
  300. package/build/video/webgpu/batchers/quad_batcher.d.ts +0 -2
  301. package/build/video/webgpu/batchers/quad_batcher.d.ts.map +1 -1
  302. package/build/video/webgpu/batchers/webgpu_batcher.d.ts +0 -2
  303. package/build/video/webgpu/batchers/webgpu_batcher.d.ts.map +1 -1
  304. package/build/video/webgpu/pipeline/cache.d.ts.map +1 -1
  305. package/build/video/webgpu/renderers/tmxlayer/orthogonal.d.ts +0 -2
  306. package/build/video/webgpu/texture/frametexture.d.ts +0 -2
  307. package/build/video/webgpu/texture/frametexture.d.ts.map +1 -1
  308. package/build/video/webgpu/texture/store.d.ts +0 -1
  309. package/build/video/webgpu/webgpu_renderer.d.ts +7 -75
  310. package/build/video/webgpu/webgpu_renderer.d.ts.map +1 -1
  311. package/package.json +2 -2
  312. package/skills/AGENTS.md +1 -1
  313. package/skills/melonjs/SKILL.md +2 -0
  314. package/skills/melonjs-3d/SKILL.md +454 -22
  315. package/skills/melonjs-3d-assets/SKILL.md +111 -10
  316. package/skills/melonjs-audio/SKILL.md +229 -8
  317. package/skills/melonjs-camera-and-drawing/SKILL.md +127 -1
  318. package/skills/melonjs-display-and-scaling/SKILL.md +273 -0
  319. package/skills/melonjs-effects-and-shaders/SKILL.md +341 -29
  320. package/skills/melonjs-events/SKILL.md +8 -6
  321. package/skills/melonjs-input/SKILL.md +147 -7
  322. package/skills/melonjs-math/SKILL.md +313 -0
  323. package/skills/melonjs-particles-and-trails/SKILL.md +189 -13
  324. package/skills/melonjs-performance/SKILL.md +131 -23
  325. package/skills/melonjs-physics/SKILL.md +103 -28
  326. package/skills/melonjs-renderables/SKILL.md +8 -2
  327. package/skills/melonjs-scenes-and-state/SKILL.md +134 -3
  328. package/skills/melonjs-sprites-and-animation/SKILL.md +9 -4
  329. package/skills/melonjs-tilemaps/SKILL.md +40 -12
  330. package/skills/melonjs-ui-and-text/SKILL.md +546 -7
  331. package/build/level/gltf/srgb.d.ts +0 -20
  332. package/build/level/gltf/srgb.d.ts.map +0 -1
@@ -0,0 +1,44 @@
1
+ import type { Color } from "../../math/color.ts";
2
+ /** Mutable per-glyph output, reset before each call. Do not retain it. */
3
+ export interface GlyphEffectOutput {
4
+ /**
5
+ * Horizontal offset in drawing pixels, after font scaling.
6
+ *
7
+ * Added to the glyph's destination as given, with no rounding. On an
8
+ * upscaled low-resolution frame, round it: a fractional destination under
9
+ * nearest sampling makes the glyph's own pixels come out uneven, and
10
+ * differently so each frame, which reads as a shimmer rather than motion.
11
+ */
12
+ offsetX: number;
13
+ /**
14
+ * Vertical offset in drawing pixels, after font scaling. Rounds like
15
+ * {@link GlyphEffectOutput.offsetX}.
16
+ */
17
+ offsetY: number;
18
+ /** Multiplicative tint; reset to opaque white before each call. */
19
+ readonly tint: Color;
20
+ }
21
+ /** Reused per-glyph context. Read its values during the callback only. */
22
+ export interface GlyphEffectContext {
23
+ /** UTF-16 character index across drawn lines, excluding line breaks. */
24
+ index: number;
25
+ /** The UTF-16 character represented by this glyph. */
26
+ char: string;
27
+ /** The BMFont character code. */
28
+ code: number;
29
+ /** Elapsed update time in milliseconds while the effect is enabled. */
30
+ time: number;
31
+ /**
32
+ * Unmodified glyph destination coordinates, after alignment and scaling.
33
+ *
34
+ * The natural phase source for a travelling effect: deriving it from
35
+ * {@link GlyphEffectContext.index} instead advances the wave as far across
36
+ * a narrow glyph as a wide one, so its wavelength changes with whatever
37
+ * the line spells.
38
+ */
39
+ x: number;
40
+ y: number;
41
+ }
42
+ /** Modify the reused output to offset or tint a BitmapText glyph. */
43
+ export type GlyphEffect = (out: GlyphEffectOutput, context: GlyphEffectContext) => void;
44
+ //# sourceMappingURL=glypheffect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"glypheffect.d.ts","sourceRoot":"","sources":["../../../src/renderable/text/glypheffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAEjD,0EAA0E;AAC1E,MAAM,WAAW,iBAAiB;IACjC;;;;;;;OAOG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB,mEAAmE;IACnE,QAAQ,CAAC,IAAI,EAAE,KAAK,CAAC;CACrB;AAED,0EAA0E;AAC1E,MAAM,WAAW,kBAAkB;IAClC,wEAAwE;IACxE,KAAK,EAAE,MAAM,CAAC;IACd,sDAAsD;IACtD,IAAI,EAAE,MAAM,CAAC;IACb,iCAAiC;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,uEAAuE;IACvE,IAAI,EAAE,MAAM,CAAC;IACb;;;;;;;OAOG;IACH,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;CACV;AAED,qEAAqE;AACrE,MAAM,MAAM,WAAW,GAAG,CACzB,GAAG,EAAE,iBAAiB,EACtB,OAAO,EAAE,kBAAkB,KACvB,IAAI,CAAC"}
@@ -89,7 +89,7 @@ export default class Text extends Renderable {
89
89
  anchorPoint?: string | Vector2d | {
90
90
  x: number;
91
91
  y: number;
92
- };
92
+ } | undefined;
93
93
  wordWrapWidth?: number | undefined;
94
94
  bold?: boolean | undefined;
95
95
  italic?: boolean | undefined;
@@ -257,13 +257,32 @@ export default class Text extends Renderable {
257
257
  measureText(text?: string): TextMetrics;
258
258
  /**
259
259
  * draw a text at the specified coord
260
- * @param {CanvasRenderer|WebGLRenderer} renderer - Reference to the destination renderer instance
260
+ * @param {Renderer} renderer - Reference to the destination renderer instance
261
261
  */
262
- draw(renderer: CanvasRenderer | WebGLRenderer): void;
262
+ draw(renderer: Renderer): void;
263
263
  }
264
+ /**
265
+ * A pool of reusable {@link Text} instances.
266
+ *
267
+ * Text is worth recycling: each one owns a canvas-backed measurement cache and
268
+ * a colour, so a scene that spawns damage numbers or score popups churns
269
+ * meaningfully without one. Reachable as `getPool("text")`.
270
+ *
271
+ * `release` it yourself when the text is finished, as the particle and tween
272
+ * pools require. A label this pool built is the exception: it carries the pool
273
+ * it came from, so removing it from a container releases it back rather than
274
+ * destroying it. Pass `keepalive` to `removeChild()` to keep holding one.
275
+ * @example
276
+ * const label = getPool("text").get(x, y, { font: "Arial", size: 12, text: "+10" });
277
+ * // ... later
278
+ * getPool("text").release(label);
279
+ */
280
+ export const textPool: import("../../index.ts").Pool<Text, [x: unknown, y: unknown, settings: unknown]>;
264
281
  import Renderable from "../renderable.js";
265
282
  import { Color } from "../../math/color.ts";
266
283
  import { Gradient } from "../../video/gradient.js";
267
284
  import CanvasRenderTarget from "../../video/rendertarget/canvasrendertarget.js";
268
285
  import TextMetrics from "./textmetrics.js";
286
+ import type Renderer from "../../video/renderer.js";
287
+ import type { Vector2d } from "../../math/vector2d.ts";
269
288
  //# sourceMappingURL=text.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../../src/renderable/text/text.js"],"names":[],"mappings":"AAwCA;;;;;;;;;;;;;;GAcG;AACH;IACC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6DG;IACH,eA7DW,MAAM,KACN,MAAM,YAEd;QAAyB,IAAI,EAArB,MAAM;QACkB,IAAI,EAA5B,MAAM,GAAC,MAAM;QACoB,SAAS;QACvB,eAAe;QACV,WAAW;QACjB,SAAS;QACT,SAAS;QACT,YAAY;QACZ,UAAU;QACmB,WAAW,GAA1D,MAAM,GAAC,QAAQ,GAAC;YAAC,CAAC,EAAC,MAAM,CAAC;YAAA,CAAC,EAAC,MAAM,CAAA;SAAC;QACjB,aAAa;QACZ,IAAI;QACJ,MAAM;QACI,IAAI;KACzC,EAsHF;IAtEA;;;;OAIG;IACH,WAHU,KAAK,CAGwB;IAEvC;;;;OAIG;IACH,aAHU,KAAK,CAG0B;IAEzC;;;;OAIG;IACH,WAHU,MAAM,CAGE;IAElB;;;;;OAKG;IACH,WAHU,MAAM,CAGO;IAEvB;;;;;OAKG;IACH,cAHU,MAAM,CAGS;IAEzB;;;;;OAKG;IACH,YAHU,MAAM,CAGK;IAErB;;;;;OAKG;IACH,eAHU,MAAM,CAGO;IAEvB;;;;OAIG;IACH,UAHU,MAAM,CAGE;IAElB;;;;;OAKG;IACH,cAAe;IAMhB;;;OAGG;IACH,kDAgIC;IA3HA;;;;;;;;;;;;;;;;OAgBG;IACH,cARU,QAAQ,GAAC,SAAS,CAQC;IAE7B;;;;;;;;;;;;;;OAcG;IACH,qCAA2B;IA0E3B,8CAEE;IAEF;;;OAGG;IACH,wBAA4B;IAG5B,iCAAoC;IAMrC;;;OAGG;IACH,QAFa,IAAI,CAWhB;IAJC,UAA+B;IAMjC;;;OAGG;IACH,UAFa,IAAI,CAWhB;IAED;;;;;;;;OAQG;IACH,cAPW,MAAM,SACN,MAAM,GAAC,MAAM,GACX,IAAI,CAwChB;IAED;;;;OAIG;IACH,gBAHW,MAAM,GAAC,MAAM,GAAC,MAAM,EAAE,GACpB,IAAI,CAkFhB;IAkBD,oCAZU,MAAM,EAiBf;IArBD;;;;;;;;;;;OAWG;IACH,gCARU,MAAM,CAUf;IAkCD,+BAlBU,MAAM,EA4Bf;IAnCD;;;;;;;;;;;;;;OAcG;IACH,2BARU,MAAM,CAgBf;IAiED;;;;;;;;;;;;OAYG;IACH,mBAXW,MAAM,GACJ,WAAW,CAYvB;IAED;;;OAGG;IACH,eAFW,cAAc,GAAC,aAAa,QA0CtC;IAED;;;OAGG;IACH,4EA+GC;IAED;;;;OAIG;IACH,gBAWC;CACD;uBAzxBsB,kBAAkB;sBALR,qBAAqB;yBAC7B,yBAAyB;+BAEnB,gDAAgD;wBAGvD,kBAAkB"}
1
+ {"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../../src/renderable/text/text.js"],"names":[],"mappings":"AAiDA;;;;;;;;;;;;;;GAcG;AACH;IACC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6DG;IACH,eA7DW,MAAM,KACN,MAAM,YAEd;QAAyB,IAAI,EAArB,MAAM;QACkB,IAAI,EAA5B,MAAM,GAAC,MAAM;QACoB,SAAS;QACvB,eAAe;QACV,WAAW;QACjB,SAAS;QACT,SAAS;QACT,YAAY;QACZ,UAAU;QACmB,WAAW;eAAvC,MAAM;eAAG,MAAM;;QAChB,aAAa;QACZ,IAAI;QACJ,MAAM;QACI,IAAI;KACzC,EAsHF;IAtEA;;;;OAIG;IACH,WAHU,KAAK,CAGwB;IAEvC;;;;OAIG;IACH,aAHU,KAAK,CAG0B;IAEzC;;;;OAIG;IACH,WAHU,MAAM,CAGE;IAElB;;;;;OAKG;IACH,WAHU,MAAM,CAGO;IAEvB;;;;;OAKG;IACH,cAHU,MAAM,CAGS;IAEzB;;;;;OAKG;IACH,YAHU,MAAM,CAGK;IAErB;;;;;OAKG;IACH,eAHU,MAAM,CAGO;IAEvB;;;;OAIG;IACH,UAHU,MAAM,CAGE;IAElB;;;;;OAKG;IACH,cAAe;IAMhB;;;OAGG;IACH,kDA8KC;IAjJA;;;;;;;;;;;;;;;;OAgBG;IACH,cARU,QAAQ,GAAC,SAAS,CAQC;IAE7B;;;;;;;;;;;;;;OAcG;IACH,qCAA2B;IA4F1B,8CAEE;IAGH;;;OAGG;IACH,wBAA4B;IAK3B,iCAAoC;IAOtC;;;OAGG;IACH,QAFa,IAAI,CAWhB;IAJC,UAA+B;IAMjC;;;OAGG;IACH,UAFa,IAAI,CAWhB;IAED;;;;;;;;OAQG;IACH,cAPW,MAAM,SACN,MAAM,GAAC,MAAM,GACX,IAAI,CAwChB;IAED;;;;OAIG;IACH,gBAHW,MAAM,GAAC,MAAM,GAAC,MAAM,EAAE,GACpB,IAAI,CAkFhB;IAkBD,oCAZU,MAAM,EAiBf;IArBD;;;;;;;;;;;OAWG;IACH,gCARU,MAAM,CAUf;IAkCD,+BAlBU,MAAM,EA4Bf;IAnCD;;;;;;;;;;;;;;OAcG;IACH,2BARU,MAAM,CAgBf;IAiED;;;;;;;;;;;;OAYG;IACH,mBAXW,MAAM,GACJ,WAAW,CAYvB;IAED;;;OAGG;IACH,eAFW,QAAQ,QA0ClB;IAED;;;OAGG;IACH,4EA+GC;IAED;;;;OAIG;IACH,gBAWC;CACD;AAED;;;;;;;;;;;;;;;GAeG;AACH,wGAQG;uBAz2B8C,kBAAkB;sBANlC,qBAAqB;yBAE7B,yBAAyB;+BAEnB,gDAAgD;wBAGvD,kBAAkB;0BASjB,yBAAyB;8BAHvB,wBAAwB"}
@@ -46,5 +46,7 @@ declare class TextMetrics extends Bounds {
46
46
  wordWrap(text: string | string[], width: number, context?: CanvasRenderingContext2D): string[];
47
47
  }
48
48
  import { Bounds } from "../../physics/bounds.ts";
49
+ import type Renderable from "../renderable.js";
49
50
  import Text from "./text.js";
51
+ import type BitmapText from "./bitmaptext.js";
50
52
  //# sourceMappingURL=textmetrics.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"textmetrics.d.ts","sourceRoot":"","sources":["../../../src/renderable/text/textmetrics.js"],"names":[],"mappings":";AA0BA;;GAEG;AACH;IACC;;OAEG;IACH,sBAFW,IAAI,GAAC,UAAU,EAczB;IARA;;;;OAIG;IACH,UAHU,UAAU,CAGI;IAKzB;;;OAGG;IACH,cAFa,MAAM,CAalB;IAED;;;;;OAKG;IACH,gBAJW,MAAM,YACN,wBAAwB,GACtB,MAAM,CA4BlB;IAED;;;;;OAKG;IACH,kBAJW,MAAM,YACN,wBAAwB,GACtB,WAAW,CAiHvB;IA/EA,iCAAqB;IACrB,mCAAuB;IAmCvB,8BAAkB;IAClB,iCAAqB;IA4CtB;;;;;;;;;;;;;;;OAeG;IACH,gBAJa,WAAW,CAoBvB;IAED;;;;;;OAMG;IACH,eALW,MAAM,GAAC,MAAM,EAAE,SACf,MAAM,YACN,wBAAwB,GACtB,MAAM,EAAE,CAyCpB;CACD;uBA1SsB,yBAAyB;iBAC/B,WAAW"}
1
+ {"version":3,"file":"textmetrics.d.ts","sourceRoot":"","sources":["../../../src/renderable/text/textmetrics.js"],"names":[],"mappings":";AA+BA;;GAEG;AACH;IACC;;OAEG;IACH,sBAFW,IAAI,GAAC,UAAU,EAczB;IARA;;;;OAIG;IACH,UAHU,UAAU,CAGI;IAKzB;;;OAGG;IACH,cAFa,MAAM,CAalB;IAED;;;;;OAKG;IACH,gBAJW,MAAM,YACN,wBAAwB,GACtB,MAAM,CA4BlB;IAED;;;;;OAKG;IACH,kBAJW,MAAM,YACN,wBAAwB,GACtB,WAAW,CAiHvB;IA/EA,iCAAqB;IACrB,mCAAuB;IAmCvB,8BAAkB;IAClB,iCAAqB;IA4CtB;;;;;;;;;;;;;;;OAeG;IACH,gBAJa,WAAW,CAoBvB;IAED;;;;;;OAMG;IACH,eALW,MAAM,GAAC,MAAM,EAAE,SACf,MAAM,YACN,wBAAwB,GACtB,MAAM,EAAE,CAyCpB;CACD;uBA/SsB,yBAAyB;4BAOrB,kBAAkB;iBAN5B,WAAW;4BAKD,iBAAiB"}
@@ -86,6 +86,5 @@ export default class Trail extends Renderable {
86
86
  }
87
87
  import Renderable from "./renderable.js";
88
88
  import type { Vector2d } from "../math/vector2d.ts";
89
- import { Gradient } from "../video/gradient.js";
90
89
  import type { Color } from "../math/color.ts";
91
90
  //# sourceMappingURL=trail.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"trail.d.ts","sourceRoot":"","sources":["../../src/renderable/trail.js"],"names":[],"mappings":"AAMA;;;GAGG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH;IACC;;;;;;;;;;;;OAYG;IACH,sBAXG;QAAsC,MAAM;QACnB,MAAM;QACN,QAAQ;QACR,WAAW;QACX,KAAK;QACH,UAAU;QACN,KAAK;QACkC,QAAQ;iBAAlD,MAAM;mBAAS,KAAK,GAAC,MAAM;;QAC9B,OAAO;QACP,SAAS;KACpC,EAuDA;IAnDA,uCAAuC;IACvC,QADW,UAAU,GAAC,QAAQ,GAAC,IAAI,CACC;IACpC,qBAAqB;IACrB,WADW,MAAM,CACoB;IACrC,qBAAqB;IACrB,UADW,MAAM,CACsB;IACvC,qBAAqB;IACrB,aADW,MAAM,CAC0B;IAG3C,uBAAuB;IACvB,YADW,MAAM,EAAE,CAIT;IAEV;;;OAGG;IACH,oBAA6C;IAC7C;;;OAGG;IACH,eAAiB;IACjB;;;OAGG;IACH,qBAAoC;IACpC;;;OAGG;IACH;;;MAAyB;IACzB;;;OAGG;IACH;;;MAAyB;IAa1B;;;;OAIG;IACH,YAHW,MAAM,KACN,MAAM,QAehB;IAED;;;OAGG;IACH,yBAsBC;IAED;;;OAGG;IACH,0BAiDC;IAED,6BAA6B;IAC7B,cAEC;IAED;;;;;;OAMG;IACH,wBALW,MAAM,GACJ,QAAQ,CAiCpB;IAED;;;OAGG;IACH,gBAMC;CACD;uBA5QsB,iBAAiB;8BAIb,qBAAqB;yBALvB,sBAAsB;2BAIvB,kBAAkB"}
1
+ {"version":3,"file":"trail.d.ts","sourceRoot":"","sources":["../../src/renderable/trail.js"],"names":[],"mappings":"AAMA;;;GAGG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH;IACC;;;;;;;;;;;;OAYG;IACH,sBAXG;QAAsC,MAAM;QACnB,MAAM;QACN,QAAQ;QACR,WAAW;QACX,KAAK;QACH,UAAU;QACN,KAAK;QACkC,QAAQ;iBAAlD,MAAM;mBAAS,KAAK,GAAC,MAAM;;QAC9B,OAAO;QACP,SAAS;KACpC,EA6DA;IAzDA,uCAAuC;IACvC,QADW,UAAU,GAAC,QAAQ,GAAC,IAAI,CACC;IACpC,qBAAqB;IACrB,WADW,MAAM,CACoB;IACrC,qBAAqB;IACrB,UADW,MAAM,CACsB;IACvC,qBAAqB;IACrB,aADW,MAAM,CAC0B;IAG3C,uBAAuB;IACvB,YADW,MAAM,EAAE,CAIT;IAYV,kBAA6C;IAC7C;;;OAGG;IACH,eAAiB;IACjB;;;OAGG;IACH,qBAAoC;IACpC;;;OAGG;IACH;;;MAAyB;IACzB;;;OAGG;IACH;;;MAAyB;IAa1B;;;;OAIG;IACH,YAHW,MAAM,KACN,MAAM,QAehB;IAED;;;OAGG;IACH,yBAsBC;IAED;;;OAGG;IACH,0BAiDC;IAED,6BAA6B;IAC7B,cAEC;IAED;;;;;;OAMG;IACH,wBALW,MAAM,GACJ,MAAM,CAOlB;IAED;;;OAGG;IACH,gBAMC;CACD;uBAxPsB,iBAAiB;8BAIb,qBAAqB;2BADxB,kBAAkB"}
@@ -0,0 +1,174 @@
1
+ /**
2
+ * A fading, tapering ribbon that recedes properly into a 3D scene.
3
+ *
4
+ * The 3D sibling of {@link Trail}, and a separate class for the same reason
5
+ * {@link Sprite3d} is separate from {@link Sprite}: the two draw through
6
+ * different tiers. A `Trail` emits its ribbon as 2D paths, which carry one
7
+ * depth for the whole renderable and a width measured in the screen plane, so
8
+ * it cannot narrow along its own length or lie on a surface. This one builds
9
+ * a real camera-facing strip and hands it to the mesh pipeline.
10
+ *
11
+ * It is a {@link Mesh}, so everything a mesh can do it can do: a post effect
12
+ * reaches it, `tint` multiplies it, it sorts into the transparent pass, and
13
+ * fog applies. It is also **cheaper to draw than a 2D trail** — one indexed
14
+ * draw call rather than one filled path per segment.
15
+ *
16
+ * Needs a {@link Camera3d}. Under a 2D camera it draws nothing and says so
17
+ * once, because the alternative is geometry projected twice.
18
+ * @augments Mesh
19
+ * @category Game Objects
20
+ * @example
21
+ * // an exhaust streak behind a craft
22
+ * const exhaust = new Trail3d(0, 0, {
23
+ * target: ship,
24
+ * width: 6,
25
+ * lifetime: 260,
26
+ * gradient: ["#eaffff", "#2ea8ff", "#2ea8ff00"],
27
+ * });
28
+ * exhaust.blendMode = "additive";
29
+ * app.world.addChild(exhaust);
30
+ * @example
31
+ * // a tyre mark lying in the ground plane: not camera-facing, so it keeps
32
+ * // the orientation it is given
33
+ * const skid = new Trail3d(0, 0, {
34
+ * target: car,
35
+ * width: 12,
36
+ * billboard: false,
37
+ * ribbonNormal: [0, -1, 0], // world up
38
+ * color: "#1a1a1a",
39
+ * });
40
+ * @example
41
+ * // manual mode, for a path the game computes itself
42
+ * const arc = new Trail3d(0, 0, { width: 4, lifetime: 400 });
43
+ * app.world.addChild(arc);
44
+ * // each frame while the spell travels
45
+ * arc.addPoint(bolt.pos.x, bolt.pos.y, bolt.pos.z);
46
+ * @see {@link Trail} for the 2D one
47
+ */
48
+ export default class Trail3d extends Mesh {
49
+ /**
50
+ * @param {number} x - the ribbon's initial anchor, world units. Only seeds
51
+ * the cull bounds: once there are points, the anchor follows them.
52
+ * @param {number} y - as `x`
53
+ * @param {object} [settings] - trail options
54
+ * @param {Renderable|Vector3d} [settings.target] - auto-follow target
55
+ * @param {number} [settings.length=20] - max number of points. **Fixed at
56
+ * construction**: the geometry is sized once, so this cannot grow later,
57
+ * and assigning {@link Trail3d#maxPoints} throws. A fractional value is
58
+ * truncated.
59
+ * @param {number} [settings.lifetime=500] - point lifetime in ms
60
+ * @param {number} [settings.minDistance=4] - min world distance between samples
61
+ * @param {number} [settings.width=10] - max ribbon width in world units
62
+ * @param {number[]} [settings.widthCurve=[1, 0]] - width multiplier curve (0=head, 1=tail)
63
+ * @param {Color|string} [settings.color="#ffffff"] - single colour, faded out along the ribbon. Ignored if `gradient` is set.
64
+ * @param {(Color|string|{pos: number, color: Color|string})[]} [settings.gradient] - colour gradient. Overrides `color`.
65
+ * @param {boolean|string} [settings.billboard="spherical"] - `false` (use `ribbonNormal`), `true` / `"cylindrical"` (faces the camera but stays upright), or `"spherical"` (faces the camera on all axes)
66
+ * @param {Vector3d|number[]} [settings.ribbonNormal] - the facing used when `billboard` is `false`; defaults to world up
67
+ * @param {number} [settings.opacity=1.0] - opacity (0.0–1.0)
68
+ * @param {string} [settings.blendMode="normal"] - blend mode
69
+ * @param {boolean} [settings.depthTest=true] - whether the ribbon is depth tested
70
+ * @throws {Error} when `length` is not a finite number. Silence there is
71
+ * worse than it sounds: `NaN` sizes every buffer to zero and makes the
72
+ * capacity test always false, so the ribbon never renders and the point
73
+ * list grows without bound.
74
+ */
75
+ constructor(x: number, y: number, settings?: {
76
+ target?: Vector3d | Renderable | undefined;
77
+ length?: number | undefined;
78
+ lifetime?: number | undefined;
79
+ minDistance?: number | undefined;
80
+ width?: number | undefined;
81
+ widthCurve?: number[] | undefined;
82
+ color?: string | Color | undefined;
83
+ gradient?: (string | Color | {
84
+ pos: number;
85
+ color: Color | string;
86
+ })[] | undefined;
87
+ billboard?: string | boolean | undefined;
88
+ ribbonNormal?: number[] | Vector3d | undefined;
89
+ opacity?: number | undefined;
90
+ blendMode?: string | undefined;
91
+ depthTest?: boolean | undefined;
92
+ });
93
+ /**
94
+ * what the ribbon follows, sampled once per update
95
+ * @type {Renderable|Vector3d|null}
96
+ */
97
+ target: Renderable | Vector3d | null;
98
+ /** @type {number} */
99
+ lifetime: number;
100
+ /** @type {number} */
101
+ minDistance: number;
102
+ /** @type {number[]} */
103
+ widthCurve: number[];
104
+ billboard: string | boolean;
105
+ set ribbonNormal(value: Vector3d);
106
+ /**
107
+ * The facing used when {@link Trail3d#billboard} is `false`.
108
+ *
109
+ * Accepts a {@link Vector3d} or a `[x, y, z]` array and holds a normalized
110
+ * copy, so a caller that keeps mutating the array it passed is not
111
+ * steering this ribbon by accident. A zero-length value falls back to
112
+ * world up rather than dividing by it.
113
+ * @type {Vector3d}
114
+ * @default (0, -1, 0)
115
+ */
116
+ get ribbonNormal(): Vector3d;
117
+ castGroundShadow: boolean;
118
+ set maxPoints(_value: number);
119
+ /**
120
+ * How many points the ribbon can hold.
121
+ *
122
+ * Read-only: see the note on `settings.length`. Assigning throws rather
123
+ * than silently doing nothing, because the alternative is a ribbon that
124
+ * quietly keeps its old capacity.
125
+ * @type {number}
126
+ */
127
+ get maxPoints(): number;
128
+ /**
129
+ * Recolour the ribbon with a single colour, faded out along its length.
130
+ *
131
+ * A method rather than a setter, matching {@link Renderable#setTint} and
132
+ * {@link Renderable#setOpacity}: it allocates a gradient, so it is for a
133
+ * change of state rather than for every frame. {@link Renderable#tint} is
134
+ * the per-frame lever, and unlike on {@link Trail} it works here, because
135
+ * the mesh batcher multiplies it in.
136
+ * @param {Color|string} value - the colour
137
+ * @returns {Trail3d} this, for chaining
138
+ */
139
+ setColor(value: Color | string): Trail3d;
140
+ /**
141
+ * Recolour the ribbon with a gradient, in the format the constructor takes.
142
+ * @param {(Color|string|{pos: number, color: Color|string})[]} value - the stops
143
+ * @returns {Trail3d} this, for chaining
144
+ */
145
+ setGradient(value: (Color | string | {
146
+ pos: number;
147
+ color: Color | string;
148
+ })[]): Trail3d;
149
+ /**
150
+ * The gradient the ribbon is currently coloured by.
151
+ * @type {Gradient}
152
+ * @see {@link Trail3d#setGradient}
153
+ */
154
+ get gradient(): Gradient;
155
+ /**
156
+ * Add a point to the ribbon.
157
+ *
158
+ * Ignored when it is closer than {@link Trail3d#minDistance} to the last
159
+ * one, measured in three dimensions — which is what stops a ribbon flying
160
+ * straight at the camera from never sampling a second point.
161
+ * @param {number} x - x position, world units
162
+ * @param {number} y - y position, world units
163
+ * @param {number} [z=0] - z position, world units
164
+ */
165
+ addPoint(x: number, y: number, z?: number): void;
166
+ /** drop every point, leaving the ribbon empty */
167
+ clear(): void;
168
+ }
169
+ import Mesh from "./mesh.js";
170
+ import type Renderable from "./renderable.js";
171
+ import { Vector3d } from "../math/vector3d.ts";
172
+ import type { Gradient } from "../video/gradient.js";
173
+ import type { Color } from "../math/color.ts";
174
+ //# sourceMappingURL=trail3d.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"trail3d.d.ts","sourceRoot":"","sources":["../../src/renderable/trail3d.js"],"names":[],"mappings":"AAoCA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH;IACC;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACH,eAzBW,MAAM,KAEN,MAAM,aAEd;QAAuC,MAAM;QACnB,MAAM;QAIN,QAAQ;QACR,WAAW;QACX,KAAK;QACH,UAAU;QACN,KAAK;QACkC,QAAQ;iBAAnD,MAAM;mBAAS,KAAK,GAAC,MAAM;;QACrB,SAAS;QACN,YAAY;QACvB,OAAO;QACP,SAAS;QACR,SAAS;KACpC,EA+HF;IA1EA;;;OAGG;IACH,QAFU,UAAU,GAAC,QAAQ,GAAC,IAAI,CAEG;IACrC,qBAAqB;IACrB,UADW,MAAM,CACuB;IACxC,qBAAqB;IACrB,aADW,MAAM,CAC2B;IAG5C,uBAAuB;IACvB,YADW,MAAM,EAAE,CAIT;IAEV;;;OAGG;IACH,mBAAwB;IACxB;;;;;;;OAOG;IACH,eAAiB;IACjB,wBAAwB;IACxB,oBAA8C;IAC9C,wBAAwB;IACxB,qBAAoC;IACpC,6DAA6D;IAC7D,kCAA0C;IAC1C,wBAAwB;IACxB,wBAAqE;IACrE;;;;;;;;;;;OAWG;IACH,iBAAiB;IACjB,wBAAwB;IACxB,iBAAiB;IAEjB,4BAAkD;IAqDnD,wBAPU,QAAQ,EAiBjB;IAxBD;;;;;;;;;OASG;IACH,oBAHU,QAAQ,CAKjB;IAzCA,0BAA6B;IAuB9B,sBANU,MAAM,EAUf;IAhBD;;;;;;;OAOG;IACH,iBAFU,MAAM,CAIf;IAkCD;;;;;;;;;;OAUG;IACH,gBAHW,KAAK,GAAC,MAAM,GACV,OAAO,CAQnB;IAED;;;;OAIG;IACH,mBAHW,CAAC,KAAK,GAAC,MAAM,GAAC;QAAC,GAAG,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,KAAK,GAAC,MAAM,CAAA;KAAC,CAAC,EAAE,GACjD,OAAO,CAMnB;IAED;;;;OAIG;IACH,gBAHU,QAAQ,CAKjB;IAED;;;;;;;;;OASG;IACH,YAJW,MAAM,KACN,MAAM,MACN,MAAM,QAiBhB;IAED,iDAAiD;IACjD,cAEC;IAuCD;;;;;;;;;;;;;;;OAeG;IACH,sBA2DC;IAED;;;;;;;;;;;;;;OAcG;IACH,wBALW,OAAO,GACL,MAAM,CAuBlB;IAED;;;;;;OAMG;IACH,eALW,QAAQ,aACR,QAAQ,QA6BlB;IAED;;;;;OAKG;IACH,sBAJW,QAAQ,QA2FlB;IAED;;;;;;;OAOG;IACH,kBAJa,MAAM,GAAC,IAAI,CAsCvB;IAwBD;;;;;;;OAOG;IACH,uBAJa,MAAM,CAwBlB;CAmBD;iBA/tBgB,WAAW;4BAMD,iBAAiB;yBATnB,qBAAqB;8BAQnB,sBAAsB;2BADzB,kBAAkB;0BAGjB,sBAAsB;qBAb1B,uBAAuB"}
@@ -22,6 +22,14 @@ export default class Trigger extends Renderable {
22
22
  * @param {number} [settings.lightIntensityScale] - Scale the glTF lights' authored intensity. See {@link level.load}
23
23
  * @param {boolean} [settings.castGroundShadow] - Enable ground shadows for glTF meshes. See {@link level.load}
24
24
  * @param {number} [settings.shadowGroundY] - World Y for glTF ground shadows. See {@link level.load}
25
+ * @param {number} [settings.shadowOpacity] - How dark those blobs are. See {@link level.load}
26
+ * @param {number} [settings.shadowScale] - Blob footprint multiplier. See {@link level.load}
27
+ * @param {number} [settings.shadowOffset] - Slide them along the light, in blob radii. See {@link level.load}
28
+ * @param {number} [settings.shadowStretch] - Lengthen them along it. See {@link level.load}
29
+ * @param {number} [settings.shadowDirectionX] - X of the ground direction they are cast along. See {@link level.load}
30
+ * @param {number} [settings.shadowDirectionZ] - Z of that direction. See {@link level.load}
31
+ * @param {number[]|Vector3d} [settings.shadowGroundNormal] - Up normal of the floor, for a scene that is not level. See {@link level.load}
32
+ * @param {Light3d} [settings.shadowLight] - A light to take the shadow direction from. See {@link level.load}
25
33
  * @example
26
34
  * // fade transition (default)
27
35
  * world.addChild(new Trigger(x, y, {
@@ -59,12 +67,12 @@ export default class Trigger extends Renderable {
59
67
  height?: number | undefined;
60
68
  shapes?: Rect[] | Polygon[] | Line[] | Ellipse[] | undefined;
61
69
  duration?: number | undefined;
62
- color?: string | Color;
70
+ color?: string | Color | undefined;
63
71
  transition?: string | undefined;
64
- shape?: Ellipse | Polygon;
72
+ shape?: Polygon | Ellipse | undefined;
65
73
  event?: string | undefined;
66
74
  to?: string | undefined;
67
- container?: string | Container;
75
+ container?: string | Container | undefined;
68
76
  onLoaded?: Function | undefined;
69
77
  flatten?: boolean | undefined;
70
78
  setViewportBounds?: boolean | undefined;
@@ -74,11 +82,19 @@ export default class Trigger extends Renderable {
74
82
  lightIntensityScale?: number | undefined;
75
83
  castGroundShadow?: boolean | undefined;
76
84
  shadowGroundY?: number | undefined;
85
+ shadowOpacity?: number | undefined;
86
+ shadowScale?: number | undefined;
87
+ shadowOffset?: number | undefined;
88
+ shadowStretch?: number | undefined;
89
+ shadowDirectionX?: number | undefined;
90
+ shadowDirectionZ?: number | undefined;
91
+ shadowGroundNormal?: number[] | Vector3d | undefined;
92
+ shadowLight?: any;
77
93
  });
78
94
  color: any;
79
95
  duration: number | undefined;
80
96
  transition: string;
81
- transitionShape: any;
97
+ transitionShape: Polygon | Ellipse | undefined;
82
98
  fading: boolean;
83
99
  type: any;
84
100
  id: any;
@@ -88,7 +104,7 @@ export default class Trigger extends Renderable {
88
104
  };
89
105
  bodyDef: {
90
106
  type: string;
91
- shapes: Rect[];
107
+ shapes: undefined[] | Polygon[] | Ellipse[];
92
108
  collisionType: number;
93
109
  collisionMask: number;
94
110
  isSensor: boolean;
@@ -107,4 +123,11 @@ export default class Trigger extends Renderable {
107
123
  onCollisionStart(): void;
108
124
  }
109
125
  import Renderable from "./renderable.js";
126
+ import type { Polygon } from "../geometries/polygon.ts";
127
+ import type { Ellipse } from "../geometries/ellipse.ts";
128
+ import type { Rect } from "../geometries/rectangle.ts";
129
+ import type { Line } from "../geometries/line.ts";
130
+ import type { Color } from "../math/color.ts";
131
+ import type Container from "./container.js";
132
+ import type { Vector3d } from "../math/vector3d.ts";
110
133
  //# sourceMappingURL=trigger.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"trigger.d.ts","sourceRoot":"","sources":["../../src/renderable/trigger.js"],"names":[],"mappings":"AA2DA;IACC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAsDG;IACH,eAtDW,MAAM,KACN,MAAM,YAEd;QAA0B,KAAK;QACL,MAAM;QACqB,MAAM;QACjC,QAAQ;QACF,KAAK,GAA7B,MAAM,GAAC,KAAK;QACM,UAAU;QACD,KAAK,GAAhC,OAAO,GAAC,OAAO;QACG,KAAK;QACL,EAAE;QACQ,SAAS,GAArC,MAAM,GAAC,SAAS;QACI,QAAQ;QACT,OAAO;QACP,iBAAiB;QAClB,KAAK;QACJ,WAAW;QACX,MAAM;QACP,mBAAmB;QAClB,gBAAgB;QACjB,aAAa;KACvC,EAyFF;IApDA,WAA4C;IAC5C,6BAAiC;IACjC,mBAA+C;IAC/C,qBAAqC;IACrC,gBAAmB;IAInB,UAAyB;IACzB,QAAqB;IACrB,8BAA4B;IAG5B;;MAEC;IAwBD;;;;;;MAMC;IASF;;;OAGG;IACH;;MAQC;IAED;;;OAGG;IACH,+BAwFC;IAED;;;;;OAKG;IACH,yBAIC;CACD;uBA7RsB,iBAAiB"}
1
+ {"version":3,"file":"trigger.d.ts","sourceRoot":"","sources":["../../src/renderable/trigger.js"],"names":[],"mappings":"AAkEA;IACC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA8DG;IACH,eA9DW,MAAM,KACN,MAAM,YAEd;QAA0B,KAAK;QACL,MAAM;QACqB,MAAM;QACjC,QAAQ;QACF,KAAK;QACX,UAAU;QACD,KAAK;QACd,KAAK;QACL,EAAE;QACQ,SAAS;QACjB,QAAQ;QACT,OAAO;QACP,iBAAiB;QAClB,KAAK;QACJ,WAAW;QACX,MAAM;QACP,mBAAmB;QAClB,gBAAgB;QACjB,aAAa;QACb,aAAa;QACb,WAAW;QACX,YAAY;QACZ,aAAa;QACb,gBAAgB;QAChB,gBAAgB;QACL,kBAAkB;QAC5B,WAAW;KACtC,EAyFF;IApDA,WAA4C;IAC5C,6BAAiC;IACjC,mBAA+C;IAC/C,+CAAqC;IACrC,gBAAmB;IAInB,UAAyB;IACzB,QAAqB;IACrB,8BAA4B;IAG5B;;MAEC;IAwBD;;;;;;MAMC;IASF;;;OAGG;IACH;;MAQC;IAED;;;OAGG;IACH,+BAwFC;IAED;;;;;OAKG;IACH,yBAIC;CACD;uBA5SsB,iBAAiB;6BAUd,0BAA0B;6BAH1B,0BAA0B;0BAI7B,4BAA4B;0BAH5B,uBAAuB;2BAHtB,kBAAkB;2BAChB,gBAAgB;8BAGf,qBAAqB"}
@@ -0,0 +1,5 @@
1
+ import { Color } from "../../math/color.ts";
2
+ import type { Gradient } from "../../video/gradient.js";
3
+ /** anything {@link Renderer#setColor} will take */
4
+ export type Paint = Color | string | Gradient;
5
+ //# sourceMappingURL=panelpaint.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"panelpaint.d.ts","sourceRoot":"","sources":["../../../src/renderable/ui/panelpaint.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAa,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAGxD,mDAAmD;AACnD,MAAM,MAAM,KAAK,GAAG,KAAK,GAAG,MAAM,GAAG,QAAQ,CAAC"}
@@ -0,0 +1,192 @@
1
+ import { on } from "../../system/event.ts";
2
+ import type Renderer from "../../video/renderer.js";
3
+ import Renderable from "../renderable.js";
4
+ import Text from "../text/text.js";
5
+ import type { Paint } from "./panelpaint.ts";
6
+ /**
7
+ * The name of any event the engine knows about.
8
+ *
9
+ * Derived from `on` rather than naming the `Events` map, which is internal to
10
+ * the event module; this gets the same set without widening that surface.
11
+ */
12
+ type EventName = Parameters<typeof on>[0];
13
+ /** which way the fill grows */
14
+ export type ProgressBarDirection = "left-to-right" | "right-to-left" | "top-to-bottom" | "bottom-to-top";
15
+ /**
16
+ * Everything {@link ProgressBar} takes.
17
+ */
18
+ export interface ProgressBarSettings {
19
+ /** the bar's full width, in pixels */
20
+ width: number;
21
+ /** the bar's full height, in pixels */
22
+ height: number;
23
+ /** the value that reads as empty */
24
+ min?: number;
25
+ /** the value that reads as full */
26
+ max?: number;
27
+ /** where to start */
28
+ value?: number;
29
+ /** which edge the fill grows from */
30
+ direction?: ProgressBarDirection;
31
+ /** behind the fill; `null` leaves it hollow, showing whatever is behind */
32
+ trackColor?: Paint | null;
33
+ /**
34
+ * the fill itself. A {@link Color} is re-read every frame, so mutating the
35
+ * one you passed animates the bar
36
+ */
37
+ fillColor?: Paint;
38
+ /** drawn around the track; `null` for none */
39
+ borderColor?: Paint | null;
40
+ /** how thick that border is */
41
+ borderWidth?: number;
42
+ /** how far the fill sits inside the track, per side */
43
+ padding?: number;
44
+ /** corner radius; `0` is square */
45
+ radius?: number;
46
+ /** called whenever the value actually moves */
47
+ onChange?: (value: number, ratio: number) => void;
48
+ /** draw a label over the bar */
49
+ showLabel?: boolean;
50
+ /** the label's font family */
51
+ font?: string;
52
+ /** the label's font size, in pixels */
53
+ fontSize?: number;
54
+ /** the label's colour */
55
+ labelFillStyle?: Paint;
56
+ /** what the label says; the default is a rounded percentage */
57
+ labelFormat?: (value: number, ratio: number) => string;
58
+ /**
59
+ * an event to take the value from, instead of setting it by hand.
60
+ *
61
+ * The bar subscribes for as long as it exists and unsubscribes when it is
62
+ * destroyed, which is the point: a subscription that outlives what it
63
+ * drives is a listener writing into a freed object.
64
+ */
65
+ bindEvent?: EventName;
66
+ }
67
+ /**
68
+ * A bar that shows one value between two bounds.
69
+ *
70
+ * A health bar, a shield gauge, a cooldown, a loading bar: all the same
71
+ * object, and the engine's own loading screen is built on this one. Set
72
+ * {@link ProgressBar#value} and it redraws.
73
+ *
74
+ * It draws the track, the fill, the border and the label itself, in that
75
+ * order, which is the point of it being ONE renderable rather than a track
76
+ * sprite with a fill sprite on top. Two renderables at the same place have to
77
+ * be told which is in front, and that question has to be answered again every
78
+ * time either one moves.
79
+ *
80
+ * ## The colour can follow the value
81
+ *
82
+ * `fillColor` is read at draw time rather than copied, so passing a
83
+ * {@link Color} you keep hold of and mutating it is all a value-driven colour
84
+ * takes. That is deliberately not built in, because every game wants a
85
+ * different rule and most want the colour somewhere else too, next to a shader
86
+ * uniform or a glow:
87
+ *
88
+ * ```js
89
+ * const full = new Color().parseCSS("#7fe0ff");
90
+ * const empty = new Color().parseCSS("#ff2a1e");
91
+ * const mixed = new Color();
92
+ *
93
+ * const shield = new ProgressBar(x, y, {
94
+ * width: 190, height: 13,
95
+ * trackColor: null, // a hollow frame
96
+ * borderColor: "rgba(122, 190, 235, 0.8)",
97
+ * padding: 2,
98
+ * fillColor: mixed, // kept, not copied
99
+ * });
100
+ *
101
+ * // each frame
102
+ * mixed.copy(empty).lerp(full, hp);
103
+ * shield.value = hp;
104
+ * ```
105
+ *
106
+ * Blinking is the same story: {@link Renderable#setOpacity} already does it,
107
+ * on whatever clock the game is already keeping.
108
+ * @category UI
109
+ * @example
110
+ * // a loading bar
111
+ * const bar = new ProgressBar(0, 100, {
112
+ * width: renderer.width, height: 4,
113
+ * trackColor: "black", fillColor: "#55aa00",
114
+ * });
115
+ * event.on(event.LOADER_PROGRESS, (progress) => { bar.value = progress; });
116
+ * @example
117
+ * // a label, and a value that is not a fraction
118
+ * const hp = new ProgressBar(20, 20, {
119
+ * width: 200, height: 24,
120
+ * min: 0, max: 100, value: 100,
121
+ * fillColor: "#c0392b", radius: 6,
122
+ * showLabel: true,
123
+ * labelFormat: (v) => `${Math.round(v)} HP`,
124
+ * });
125
+ */
126
+ export default class ProgressBar extends Renderable {
127
+ /** the value that reads as empty */
128
+ min: number;
129
+ /** the value that reads as full */
130
+ max: number;
131
+ /** which edge the fill grows from */
132
+ direction: ProgressBarDirection;
133
+ /** behind the fill; `null` leaves it hollow */
134
+ trackColor: Paint | null;
135
+ /** the fill. A {@link Color} here is re-read every frame */
136
+ fillColor: Paint;
137
+ /** drawn around the track; `null` for none */
138
+ borderColor: Paint | null;
139
+ /** how thick that border is */
140
+ borderWidth: number;
141
+ /** how far the fill sits inside the track, per side */
142
+ padding: number;
143
+ /** corner radius; `0` is square */
144
+ radius: number;
145
+ /** called whenever the value actually moves */
146
+ onChange?: ((value: number, ratio: number) => void) | undefined;
147
+ /** what the label says */
148
+ labelFormat: (value: number, ratio: number) => string;
149
+ /** the label, when `showLabel` was asked for */
150
+ label?: Text | undefined;
151
+ /** the event the value is taken from, if any */
152
+ readonly bindEvent?: EventName | undefined;
153
+ private _value;
154
+ /**
155
+ * @param x - position of the bar's left edge
156
+ * @param y - position of its top edge
157
+ * @param settings - see {@link ProgressBarSettings}
158
+ */
159
+ constructor(x: number, y: number, settings: ProgressBarSettings);
160
+ /**
161
+ * Where the bar is now, between {@link ProgressBar#min} and
162
+ * {@link ProgressBar#max}.
163
+ *
164
+ * Writing a value outside that range clamps rather than throwing, since
165
+ * the usual source is a health or a timer that has just gone past its own
166
+ * limit. Writing the value it already has does nothing at all, so
167
+ * `onChange` means the value MOVED.
168
+ */
169
+ get value(): number;
170
+ set value(v: number);
171
+ /**
172
+ * The value as a fraction, `0` at `min` and `1` at `max`.
173
+ *
174
+ * This is what the fill is drawn from, and what a caller usually wants for
175
+ * anything else keyed to the same number. Read only; set
176
+ * {@link ProgressBar#value}.
177
+ */
178
+ get ratio(): number;
179
+ /**
180
+ * Set the value, for chaining.
181
+ * @param v - the new value, clamped to the bar's bounds
182
+ * @returns this bar
183
+ */
184
+ setValue(v: number): this;
185
+ /**
186
+ * Draw the track, the fill, the border and the label, in that order.
187
+ * @param renderer - the renderer to draw with
188
+ */
189
+ draw(renderer: Renderer): void;
190
+ }
191
+ export {};
192
+ //# sourceMappingURL=progressbar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"progressbar.d.ts","sourceRoot":"","sources":["../../../src/renderable/ui/progressbar.ts"],"names":[],"mappings":"AACA,OAAO,EAAO,EAAE,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,KAAK,QAAQ,MAAM,yBAAyB,CAAC;AACpD,OAAO,UAAU,MAAM,kBAAkB,CAAC;AAC1C,OAAO,IAAI,MAAM,iBAAiB,CAAC;AACnC,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAG7C;;;;;GAKG;AACH,KAAK,SAAS,GAAG,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;AAE1C,+BAA+B;AAC/B,MAAM,MAAM,oBAAoB,GAC7B,eAAe,GACf,eAAe,GACf,eAAe,GACf,eAAe,CAAC;AAEnB;;GAEG;AACH,MAAM,WAAW,mBAAmB;IACnC,sCAAsC;IACtC,KAAK,EAAE,MAAM,CAAC;IACd,uCAAuC;IACvC,MAAM,EAAE,MAAM,CAAC;IACf,oCAAoC;IACpC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,mCAAmC;IACnC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,qBAAqB;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,qCAAqC;IACrC,SAAS,CAAC,EAAE,oBAAoB,CAAC;IACjC,2EAA2E;IAC3E,UAAU,CAAC,EAAE,KAAK,GAAG,IAAI,CAAC;IAC1B;;;OAGG;IACH,SAAS,CAAC,EAAE,KAAK,CAAC;IAClB,8CAA8C;IAC9C,WAAW,CAAC,EAAE,KAAK,GAAG,IAAI,CAAC;IAC3B,+BAA+B;IAC/B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,uDAAuD;IACvD,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,mCAAmC;IACnC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClD,gCAAgC;IAChC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,8BAA8B;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,uCAAuC;IACvC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,yBAAyB;IACzB,cAAc,CAAC,EAAE,KAAK,CAAC;IACvB,+DAA+D;IAC/D,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC;IACvD;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;CACtB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DG;AACH,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,UAAU;IAClD,oCAAoC;IACpC,GAAG,EAAE,MAAM,CAAC;IACZ,mCAAmC;IACnC,GAAG,EAAE,MAAM,CAAC;IACZ,qCAAqC;IACrC,SAAS,EAAE,oBAAoB,CAAC;IAChC,+CAA+C;IAC/C,UAAU,EAAE,KAAK,GAAG,IAAI,CAAC;IACzB,4DAA4D;IAC5D,SAAS,EAAE,KAAK,CAAC;IACjB,8CAA8C;IAC9C,WAAW,EAAE,KAAK,GAAG,IAAI,CAAC;IAC1B,+BAA+B;IAC/B,WAAW,EAAE,MAAM,CAAC;IACpB,uDAAuD;IACvD,OAAO,EAAE,MAAM,CAAC;IAChB,mCAAmC;IACnC,MAAM,EAAE,MAAM,CAAC;IACf,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC,GAAG,SAAS,CAAC;IAChE,0BAA0B;IAC1B,WAAW,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC;IACtD,gDAAgD;IAChD,KAAK,CAAC,EAAE,IAAI,GAAG,SAAS,CAAC;IACzB,gDAAgD;IAChD,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,GAAG,SAAS,CAAC;IAE3C,OAAO,CAAC,MAAM,CAAS;IAYvB;;;;OAIG;gBACS,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,mBAAmB;IAyD/D;;;;;;;;OAQG;IACH,IAAI,KAAK,IAII,MAAM,CAFlB;IAED,IAAI,KAAK,CAAC,CAAC,EAAE,MAAM,EAWlB;IAED;;;;;;OAMG;IACH,IAAI,KAAK,WAGR;IAYD;;;;OAIG;IACH,QAAQ,CAAC,CAAC,EAAE,MAAM;IAKlB;;;OAGG;IACM,IAAI,CAAC,QAAQ,EAAE,QAAQ;CAgGhC"}