@cimplify/sdk 0.108.0 → 0.110.2

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 (608) hide show
  1. package/LICENSE +21 -0
  2. package/dist/advanced.d.mts +4 -3
  3. package/dist/advanced.d.ts +4 -3
  4. package/dist/advanced.js +24 -24
  5. package/dist/advanced.mjs +5 -5
  6. package/dist/animation-4EXBXRVX.js +27 -0
  7. package/dist/animation-6DICNWUP.mjs +6 -0
  8. package/dist/audio-DhvyjqdA.d.mts +249 -0
  9. package/dist/audio-m0w8cnxq.d.ts +249 -0
  10. package/dist/avatars.d.mts +110 -0
  11. package/dist/avatars.d.ts +110 -0
  12. package/dist/avatars.js +82 -0
  13. package/dist/avatars.mjs +5 -0
  14. package/dist/backend-gUCzs5Kg.d.mts +3866 -0
  15. package/dist/backend-gUCzs5Kg.d.ts +3866 -0
  16. package/dist/{catalogue-B4eLL8Mi.d.ts → catalogue-CPTMyBUz.d.mts} +109 -221
  17. package/dist/catalogue-DzrTXP3v.d.mts +541 -0
  18. package/dist/catalogue-DzrTXP3v.d.ts +541 -0
  19. package/dist/{catalogue-OT89_Ifs.d.mts → catalogue-OTuS5zp-.d.ts} +109 -221
  20. package/dist/chunk-22BD3RHN.mjs +1809 -0
  21. package/dist/chunk-25T4JHEA.mjs +21 -0
  22. package/dist/chunk-2AQ237Y4.js +508 -0
  23. package/dist/chunk-2IC4H6OV.mjs +48 -0
  24. package/dist/chunk-2LHLG4OB.mjs +71 -0
  25. package/dist/chunk-2O2CG465.js +1709 -0
  26. package/dist/chunk-2Q4DTHXK.js +316 -0
  27. package/dist/chunk-2QTQ6BUH.mjs +46 -0
  28. package/dist/chunk-2UN4SFLR.mjs +100 -0
  29. package/dist/chunk-2V75I7K3.js +454 -0
  30. package/dist/chunk-2V7IL4HC.js +10 -0
  31. package/dist/chunk-34XBXUMW.js +296 -0
  32. package/dist/chunk-3C4C654I.js +71 -0
  33. package/dist/chunk-3DAD2LDF.mjs +72 -0
  34. package/dist/chunk-3GXH2NFD.mjs +4 -0
  35. package/dist/chunk-3O47ZFW3.js +961 -0
  36. package/dist/chunk-3OY3VYNF.mjs +11 -0
  37. package/dist/chunk-3S6WPBZL.js +2936 -0
  38. package/dist/chunk-3TUOUP5T.js +399 -0
  39. package/dist/chunk-3VEH23I5.mjs +1380 -0
  40. package/dist/chunk-3ZYSAW2T.mjs +263 -0
  41. package/dist/chunk-4ANVF274.js +103 -0
  42. package/dist/chunk-4C7I3ELN.js +388 -0
  43. package/dist/chunk-4DYKAYFO.mjs +8 -0
  44. package/dist/chunk-4ZDR72SG.js +329 -0
  45. package/dist/chunk-52YS45RR.js +1066 -0
  46. package/dist/chunk-5325XSCH.js +107 -0
  47. package/dist/chunk-5AD5X6AV.js +13 -0
  48. package/dist/chunk-5BYDGGWO.mjs +197 -0
  49. package/dist/chunk-5C3C7VDM.mjs +55 -0
  50. package/dist/chunk-5HFMY3D7.js +660 -0
  51. package/dist/chunk-5LH2QN3T.js +1862 -0
  52. package/dist/chunk-5PJEXSOW.js +44 -0
  53. package/dist/chunk-5SXDH3Y7.js +90 -0
  54. package/dist/chunk-5YFBGGCK.mjs +502 -0
  55. package/dist/chunk-5YWN6H5Q.mjs +133 -0
  56. package/dist/chunk-66QP3SMN.js +402 -0
  57. package/dist/chunk-6DAEZKIG.mjs +385 -0
  58. package/dist/chunk-6DATW7TB.mjs +420 -0
  59. package/dist/{chunk-JRGK3NXR.mjs → chunk-6ETDAU62.mjs} +72 -212
  60. package/dist/chunk-6H254EVP.mjs +178 -0
  61. package/dist/chunk-6PFNJPBJ.mjs +820 -0
  62. package/dist/chunk-6PJWXIFX.mjs +357 -0
  63. package/dist/chunk-6SWKWCMS.js +80 -0
  64. package/dist/chunk-6VVXXX7S.js +808 -0
  65. package/dist/chunk-6WUBSMTX.js +1403 -0
  66. package/dist/chunk-73SGZLAQ.mjs +35 -0
  67. package/dist/chunk-76L2V6KD.mjs +4 -0
  68. package/dist/chunk-7AAIAVAA.js +1531 -0
  69. package/dist/chunk-7ARSJPV3.mjs +93 -0
  70. package/dist/chunk-7BHW5GTC.mjs +1234 -0
  71. package/dist/chunk-7DQSDKDU.js +6 -0
  72. package/dist/chunk-7IQQQENP.mjs +401 -0
  73. package/dist/chunk-7KFTYENS.js +11357 -0
  74. package/dist/chunk-7SM6XSPZ.js +3171 -0
  75. package/dist/chunk-7SXOHAIR.mjs +28 -0
  76. package/dist/chunk-A2MAX6S4.js +90 -0
  77. package/dist/chunk-A33OORT7.mjs +1530 -0
  78. package/dist/{chunk-U6ACF76H.mjs → chunk-A36JRXXH.mjs} +1075 -1845
  79. package/dist/chunk-A7BU3BK4.js +52 -0
  80. package/dist/chunk-A7MQSN2V.mjs +77 -0
  81. package/dist/chunk-A7V4L2IT.mjs +416 -0
  82. package/dist/chunk-AABEK6XU.js +226 -0
  83. package/dist/chunk-AGV33FWC.mjs +5005 -0
  84. package/dist/chunk-AHNR3BXI.js +108 -0
  85. package/dist/chunk-AQ5RLBU2.mjs +286 -0
  86. package/dist/chunk-AQOE6WCG.js +1270 -0
  87. package/dist/chunk-ATAWRACV.mjs +62 -0
  88. package/dist/chunk-ATCURNUV.js +14 -0
  89. package/dist/chunk-AWPV33OO.js +6 -0
  90. package/dist/chunk-AYJPHKYV.js +337 -0
  91. package/dist/chunk-AZ5BGWHB.js +162 -0
  92. package/dist/chunk-AZAXD44P.js +1373 -0
  93. package/dist/chunk-BBGKQIJJ.mjs +406 -0
  94. package/dist/chunk-BP4JLSUA.js +1453 -0
  95. package/dist/{chunk-SUCE7FWA.mjs → chunk-BTUSVHIE.mjs} +539 -978
  96. package/dist/chunk-BU6OK542.mjs +818 -0
  97. package/dist/chunk-CVSRWM6W.js +418 -0
  98. package/dist/chunk-CYBMFMJD.mjs +247 -0
  99. package/dist/chunk-DDJLDOUX.mjs +217 -0
  100. package/dist/{chunk-V32BCG7M.js → chunk-DFZWHNRG.js} +75 -215
  101. package/dist/chunk-DJ2C7AVG.js +644 -0
  102. package/dist/chunk-DS2VU4WW.mjs +102 -0
  103. package/dist/chunk-DSAG7T5P.js +7290 -0
  104. package/dist/chunk-E2QPPH7I.js +327 -0
  105. package/dist/chunk-E65WCTIG.mjs +1187 -0
  106. package/dist/{chunk-33VCYWVL.mjs → chunk-E6QQKDNE.mjs} +30 -42
  107. package/dist/chunk-ECDK6QBF.mjs +981 -0
  108. package/dist/chunk-EIB4OWVQ.mjs +620 -0
  109. package/dist/chunk-EQUZYCGO.js +250 -0
  110. package/dist/chunk-F3UJ6ZRM.mjs +313 -0
  111. package/dist/chunk-F63N2ZTQ.js +7023 -0
  112. package/dist/chunk-F6XRYEM3.mjs +26 -0
  113. package/dist/chunk-FE6VCE4K.js +5030 -0
  114. package/dist/chunk-FLWD6GRR.js +1372 -0
  115. package/dist/chunk-FQBFWJBS.mjs +110 -0
  116. package/dist/chunk-FXVJ2HFU.js +26 -0
  117. package/dist/chunk-FZMQMQBW.js +312 -0
  118. package/dist/chunk-G3EEC44R.js +53 -0
  119. package/dist/{chunk-KG3WT4PR.mjs → chunk-GCKWKLZF.mjs} +73 -104
  120. package/dist/chunk-GCX7TY4D.mjs +6826 -0
  121. package/dist/chunk-GDB6TCSD.js +450 -0
  122. package/dist/chunk-GDCV4IWO.mjs +21 -0
  123. package/dist/chunk-GDZT5LZ5.js +170 -0
  124. package/dist/chunk-GHPUYD4I.mjs +213 -0
  125. package/dist/chunk-GHS6MIL6.mjs +1432 -0
  126. package/dist/chunk-GPS2THCL.mjs +11 -0
  127. package/dist/{chunk-EV2EVOYS.js → chunk-GTJWQAGU.js} +31 -42
  128. package/dist/chunk-GVTI6UJQ.mjs +130 -0
  129. package/dist/chunk-GXKI64OT.mjs +1138 -0
  130. package/dist/chunk-GYDYF2WX.js +275 -0
  131. package/dist/chunk-GYLP6UG4.mjs +705 -0
  132. package/dist/chunk-H3OQKK6X.js +1158 -0
  133. package/dist/chunk-H5DFSCJ6.js +40 -0
  134. package/dist/chunk-HAGEIC2L.mjs +186 -0
  135. package/dist/chunk-HAJ4JRFO.js +293 -0
  136. package/dist/chunk-HDR72GB6.js +188 -0
  137. package/dist/chunk-HF5HPS4T.mjs +40 -0
  138. package/dist/chunk-HK6LOFDS.js +218 -0
  139. package/dist/chunk-HMWYTXCY.mjs +143 -0
  140. package/dist/chunk-HPCSRCMA.js +89 -0
  141. package/dist/chunk-HSEO6TPU.js +247 -0
  142. package/dist/chunk-I5FOHCLH.js +132 -0
  143. package/dist/chunk-IDLW4NWA.mjs +85 -0
  144. package/dist/chunk-IIDZ5WUX.js +61 -0
  145. package/dist/chunk-IR74FJHU.js +2332 -0
  146. package/dist/chunk-IRVFYAKP.mjs +100 -0
  147. package/dist/{chunk-XBL3TMPC.mjs → chunk-IZDWAL53.mjs} +1795 -3287
  148. package/dist/chunk-J2KZXIU3.js +51 -0
  149. package/dist/chunk-J2U6PJSO.js +91 -0
  150. package/dist/chunk-J5AJNY2N.js +283 -0
  151. package/dist/chunk-J6KQZ4FO.mjs +821 -0
  152. package/dist/{chunk-OWW5GUSB.js → chunk-JGBCIKJV.js} +7 -6
  153. package/dist/chunk-JKGTBMU7.mjs +25 -0
  154. package/dist/chunk-JR3TNEQC.js +422 -0
  155. package/dist/chunk-JURRXY2J.mjs +29 -0
  156. package/dist/chunk-K3HW5I2A.mjs +317 -0
  157. package/dist/chunk-K46SMZ66.mjs +103 -0
  158. package/dist/chunk-K4UDGE3Z.mjs +6 -0
  159. package/dist/chunk-KDQOR4QQ.mjs +350 -0
  160. package/dist/chunk-KDTVOLHI.mjs +288 -0
  161. package/dist/chunk-KGHJH5KJ.mjs +35 -0
  162. package/dist/chunk-KIZOA5LX.mjs +140 -0
  163. package/dist/chunk-KK6HYVBI.mjs +242 -0
  164. package/dist/chunk-KMKWGXMK.js +856 -0
  165. package/dist/chunk-KPA6K5IB.js +80 -0
  166. package/dist/chunk-KU7O4IXU.mjs +260 -0
  167. package/dist/chunk-KVFNRJOR.mjs +11142 -0
  168. package/dist/chunk-KZJRSXHK.js +2432 -0
  169. package/dist/chunk-LHWPRUJL.js +79 -0
  170. package/dist/chunk-LIV3KXJG.mjs +369 -0
  171. package/dist/chunk-LKV4LACG.js +21 -0
  172. package/dist/chunk-LUY45X3U.mjs +263 -0
  173. package/dist/chunk-LYEZZEEF.mjs +17 -0
  174. package/dist/chunk-M5EXQZYY.mjs +1519 -0
  175. package/dist/chunk-ME6HGG4I.mjs +1338 -0
  176. package/dist/chunk-MEXP6DA6.js +31 -0
  177. package/dist/chunk-MG52AW3H.js +902 -0
  178. package/dist/chunk-MIPO6F72.js +334 -0
  179. package/dist/{chunk-5QW7CQBA.js → chunk-MKIJQL5Q.js} +211 -321
  180. package/dist/chunk-MN3YETVN.mjs +17 -0
  181. package/dist/chunk-MOBSBXVE.mjs +2391 -0
  182. package/dist/chunk-MOMOZEUM.mjs +88 -0
  183. package/dist/chunk-MRFUNRAP.js +62 -0
  184. package/dist/chunk-MTIHEW2M.js +433 -0
  185. package/dist/chunk-N4RGGDEL.mjs +73 -0
  186. package/dist/chunk-NH654HAT.js +10 -0
  187. package/dist/chunk-NHJUGZUR.mjs +253 -0
  188. package/dist/chunk-NMQT4HG3.mjs +757 -0
  189. package/dist/chunk-NPSYB6DC.mjs +906 -0
  190. package/dist/chunk-NW2GPMSO.js +857 -0
  191. package/dist/chunk-NXKQOQ6L.js +76 -0
  192. package/dist/chunk-NXLAZIJZ.js +309 -0
  193. package/dist/chunk-NYWNA5CF.js +148 -0
  194. package/dist/chunk-NZTKLY2W.js +1442 -0
  195. package/dist/chunk-O2ICABUD.js +36 -0
  196. package/dist/chunk-OIVVQQ22.js +862 -0
  197. package/dist/chunk-OKC2B4O3.mjs +312 -0
  198. package/dist/chunk-OLWFPDBK.js +2220 -0
  199. package/dist/chunk-OMTVH334.js +3779 -0
  200. package/dist/chunk-OQRVEM56.mjs +362 -0
  201. package/dist/chunk-OXMIBOD4.js +337 -0
  202. package/dist/chunk-PBL6YL5L.mjs +288 -0
  203. package/dist/chunk-PDOELNNQ.js +97 -0
  204. package/dist/chunk-PDQJY2GZ.js +136 -0
  205. package/dist/chunk-PKOZXD2Q.js +1274 -0
  206. package/dist/chunk-PPF2BYFL.mjs +2191 -0
  207. package/dist/chunk-PQTQKNKD.js +539 -0
  208. package/dist/chunk-PRSR4FAV.mjs +81 -0
  209. package/dist/chunk-PTRNO5UD.js +95 -0
  210. package/dist/chunk-Q2Y3VMKH.js +2000 -0
  211. package/dist/chunk-QCZOE65N.js +96 -0
  212. package/dist/chunk-QDYFLATW.mjs +52 -0
  213. package/dist/chunk-QQABGCMM.js +22 -0
  214. package/dist/chunk-QS6TRHMR.js +345 -0
  215. package/dist/chunk-R56P64LB.mjs +208 -0
  216. package/dist/chunk-RCQ2MPBV.js +428 -0
  217. package/dist/chunk-RFVRPYR2.mjs +856 -0
  218. package/dist/chunk-RKBLPGPV.js +11521 -0
  219. package/dist/chunk-RM2V4IND.mjs +327 -0
  220. package/dist/chunk-RQXN5A34.mjs +613 -0
  221. package/dist/chunk-RUVGVNOF.mjs +2687 -0
  222. package/dist/chunk-SAFJIGYB.mjs +165 -0
  223. package/dist/chunk-SKQFLBDD.js +263 -0
  224. package/dist/chunk-SMK6JU2F.mjs +2092 -0
  225. package/dist/{chunk-UVRPC2P7.js → chunk-SNNEOS5Z.js} +1984 -3476
  226. package/dist/chunk-SPCRQ6NO.mjs +1246 -0
  227. package/dist/chunk-SWX4SALA.mjs +19 -0
  228. package/dist/{chunk-JVODCGFP.mjs → chunk-SYEO2WV4.mjs} +128 -238
  229. package/dist/chunk-T2QQMX2N.js +10 -0
  230. package/dist/chunk-T3AFF3L7.mjs +57 -0
  231. package/dist/chunk-T6Z2EXYL.js +712 -0
  232. package/dist/chunk-T7LOXGYX.js +118 -0
  233. package/dist/chunk-TJCAE7RC.mjs +1315 -0
  234. package/dist/chunk-TJI3K6RP.js +137 -0
  235. package/dist/chunk-TL2SVO4P.mjs +55 -0
  236. package/dist/chunk-TM63CYGN.mjs +399 -0
  237. package/dist/chunk-TU5RYTYU.mjs +13 -0
  238. package/dist/chunk-TVJZ4GPS.js +1553 -0
  239. package/dist/chunk-TWM6DLYF.js +371 -0
  240. package/dist/chunk-U63OC4TQ.js +30 -0
  241. package/dist/{chunk-L5GKVQVJ.js → chunk-U6BVSJZ6.js} +25 -57
  242. package/dist/chunk-U6UVWEAK.mjs +792 -0
  243. package/dist/chunk-UCEPNO6N.mjs +11048 -0
  244. package/dist/{chunk-ANT574FD.js → chunk-UCR5HRYM.js} +74 -105
  245. package/dist/chunk-UG5BTOTF.mjs +334 -0
  246. package/dist/chunk-UGH37BQW.mjs +157 -0
  247. package/dist/chunk-V7ZRH3PY.mjs +271 -0
  248. package/dist/chunk-VBGHBL3E.mjs +1394 -0
  249. package/dist/chunk-VRBDAS5I.js +920 -0
  250. package/dist/chunk-VVE3Y76O.js +230 -0
  251. package/dist/chunk-W65JIRI4.mjs +1182 -0
  252. package/dist/chunk-WHYKAT7G.js +62 -0
  253. package/dist/{chunk-YOIVZ6OA.mjs → chunk-WIZRUIZB.mjs} +25 -57
  254. package/dist/chunk-WKWTDZS7.js +385 -0
  255. package/dist/chunk-WLMINRC4.mjs +78 -0
  256. package/dist/chunk-WOF3AD3J.js +22 -0
  257. package/dist/chunk-WWKMOA76.js +1262 -0
  258. package/dist/chunk-X5A5FOWW.js +615 -0
  259. package/dist/chunk-X6CN6KQF.mjs +192 -0
  260. package/dist/chunk-XD2PMH46.mjs +517 -0
  261. package/dist/chunk-XJA2NGTI.mjs +88 -0
  262. package/dist/chunk-XJIHN3BY.mjs +8 -0
  263. package/dist/chunk-XK6UDWJS.js +203 -0
  264. package/dist/chunk-XPG3N5CF.mjs +415 -0
  265. package/dist/chunk-XVZ2NKSU.mjs +74 -0
  266. package/dist/chunk-XYP45OLE.js +117 -0
  267. package/dist/chunk-XZSDGZX6.mjs +301 -0
  268. package/dist/chunk-Y2EMGN4T.mjs +120 -0
  269. package/dist/chunk-Y3XWP5XW.mjs +298 -0
  270. package/dist/chunk-Y4K22JL6.js +228 -0
  271. package/dist/chunk-Y65LXQGA.mjs +3164 -0
  272. package/dist/chunk-Y66WVMO5.mjs +87 -0
  273. package/dist/chunk-Y7JWLB25.mjs +7280 -0
  274. package/dist/chunk-YCDXAJKU.js +175 -0
  275. package/dist/chunk-YRDQCCIS.js +152 -0
  276. package/dist/chunk-YV52DGSA.js +111 -0
  277. package/dist/chunk-YXGZQPUD.js +94 -0
  278. package/dist/chunk-Z3A3AFVU.mjs +102 -0
  279. package/dist/chunk-ZCY6YKKP.mjs +475 -0
  280. package/dist/chunk-ZEQHXVU5.js +215 -0
  281. package/dist/chunk-ZF7JCXCI.js +284 -0
  282. package/dist/chunk-ZJBRUH6V.js +29 -0
  283. package/dist/chunk-ZMIL4ZOA.js +365 -0
  284. package/dist/chunk-ZR5ULMN2.mjs +337 -0
  285. package/dist/chunk-ZXREOYOW.js +87 -0
  286. package/dist/{client-BSP9U1O1.d.mts → client-CX_WR0-J.d.mts} +2 -2
  287. package/dist/client-Dytx_ZTC.d.ts +230 -0
  288. package/dist/{client-B878xeAP.d.ts → client-dqOhP9Nc.d.ts} +2 -2
  289. package/dist/client-hTKbCuhG.d.mts +230 -0
  290. package/dist/clock-B-UAjkKa.d.mts +5 -0
  291. package/dist/clock-B-UAjkKa.d.ts +5 -0
  292. package/dist/config-BlXQluJR.d.mts +36 -0
  293. package/dist/config-BlXQluJR.d.ts +36 -0
  294. package/dist/courier-Cnn-edJ4.d.ts +95 -0
  295. package/dist/courier-FmGfkvIN.d.mts +95 -0
  296. package/dist/crowd-DdHFbqKK.d.ts +186 -0
  297. package/dist/crowd-hOVSAmA3.d.mts +186 -0
  298. package/dist/danfo-BEBapFlX.d.mts +146 -0
  299. package/dist/danfo-UQ_PTIIx.d.ts +146 -0
  300. package/dist/{elements-Bty6Qs_N.d.mts → elements-DdsRig-2.d.mts} +1548 -257
  301. package/dist/{elements-Bty6Qs_N.d.ts → elements-DdsRig-2.d.ts} +1548 -257
  302. package/dist/engines/godot.d.mts +56 -0
  303. package/dist/engines/godot.d.ts +56 -0
  304. package/dist/engines/godot.js +28 -0
  305. package/dist/engines/godot.mjs +3 -0
  306. package/dist/engines/wasm.d.mts +11 -0
  307. package/dist/engines/wasm.d.ts +11 -0
  308. package/dist/engines/wasm.js +178 -0
  309. package/dist/engines/wasm.mjs +176 -0
  310. package/dist/fallback-CrG_lTFk.d.mts +270 -0
  311. package/dist/fallback-CrG_lTFk.d.ts +270 -0
  312. package/dist/fallback-KDB4Y2CE.mjs +6 -0
  313. package/dist/fallback-Y26TQENE.js +19 -0
  314. package/dist/features-CZB4rmcD.d.mts +118 -0
  315. package/dist/features-CZB4rmcD.d.ts +118 -0
  316. package/dist/fit-BWiE7rgA.d.mts +44 -0
  317. package/dist/fit-DK0oT7zO.d.ts +44 -0
  318. package/dist/five-a-side-Bv1AOUy3.d.mts +115 -0
  319. package/dist/five-a-side-EC51SJY1.d.ts +115 -0
  320. package/dist/fluid-ARr0qUIL.d.ts +939 -0
  321. package/dist/fluid-DLlEj2cs.d.mts +939 -0
  322. package/dist/game/conformance.d.mts +84 -0
  323. package/dist/game/conformance.d.ts +84 -0
  324. package/dist/game/conformance.js +1025 -0
  325. package/dist/game/conformance.mjs +994 -0
  326. package/dist/game/heap.d.mts +40 -0
  327. package/dist/game/heap.d.ts +40 -0
  328. package/dist/game/heap.js +48 -0
  329. package/dist/game/heap.mjs +7 -0
  330. package/dist/game/kit/canvas.d.mts +240 -0
  331. package/dist/game/kit/canvas.d.ts +240 -0
  332. package/dist/game/kit/canvas.js +3566 -0
  333. package/dist/game/kit/canvas.mjs +1039 -0
  334. package/dist/game/kit/courier.d.mts +17 -0
  335. package/dist/game/kit/courier.d.ts +17 -0
  336. package/dist/game/kit/courier.js +66 -0
  337. package/dist/game/kit/courier.mjs +49 -0
  338. package/dist/game/kit/danfo.d.mts +11 -0
  339. package/dist/game/kit/danfo.d.ts +11 -0
  340. package/dist/game/kit/danfo.js +109 -0
  341. package/dist/game/kit/danfo.mjs +44 -0
  342. package/dist/game/kit/engine.d.mts +29 -0
  343. package/dist/game/kit/engine.d.ts +29 -0
  344. package/dist/game/kit/engine.js +183 -0
  345. package/dist/game/kit/engine.mjs +30 -0
  346. package/dist/game/kit/five-a-side.d.mts +11 -0
  347. package/dist/game/kit/five-a-side.d.ts +11 -0
  348. package/dist/game/kit/five-a-side.js +86 -0
  349. package/dist/game/kit/five-a-side.mjs +41 -0
  350. package/dist/game/kit/frontier.d.mts +344 -0
  351. package/dist/game/kit/frontier.d.ts +344 -0
  352. package/dist/game/kit/frontier.js +435 -0
  353. package/dist/game/kit/frontier.mjs +14 -0
  354. package/dist/game/kit/genesis.d.mts +752 -0
  355. package/dist/game/kit/genesis.d.ts +752 -0
  356. package/dist/game/kit/genesis.js +380 -0
  357. package/dist/game/kit/genesis.mjs +15 -0
  358. package/dist/game/kit/ludo.d.mts +15 -0
  359. package/dist/game/kit/ludo.d.ts +15 -0
  360. package/dist/game/kit/ludo.js +87 -0
  361. package/dist/game/kit/ludo.mjs +42 -0
  362. package/dist/game/kit/runner.d.mts +12 -0
  363. package/dist/game/kit/runner.d.ts +12 -0
  364. package/dist/game/kit/runner.js +83 -0
  365. package/dist/game/kit/runner.mjs +46 -0
  366. package/dist/game/kit/shootout.d.mts +13 -0
  367. package/dist/game/kit/shootout.d.ts +13 -0
  368. package/dist/game/kit/shootout.js +122 -0
  369. package/dist/game/kit/shootout.mjs +57 -0
  370. package/dist/game/kit/slots.d.mts +392 -0
  371. package/dist/game/kit/slots.d.ts +392 -0
  372. package/dist/game/kit/slots.js +215 -0
  373. package/dist/game/kit/slots.mjs +6 -0
  374. package/dist/game/kit/tycoon.d.mts +16 -0
  375. package/dist/game/kit/tycoon.d.ts +16 -0
  376. package/dist/game/kit/tycoon.js +145 -0
  377. package/dist/game/kit/tycoon.mjs +44 -0
  378. package/dist/game/kit/word.d.mts +11 -0
  379. package/dist/game/kit/word.d.ts +11 -0
  380. package/dist/game/kit/word.js +78 -0
  381. package/dist/game/kit/word.mjs +41 -0
  382. package/dist/game/kit/worlds.d.mts +18 -0
  383. package/dist/game/kit/worlds.d.ts +18 -0
  384. package/dist/game/kit/worlds.js +74 -0
  385. package/dist/game/kit/worlds.mjs +49 -0
  386. package/dist/game/kit.d.mts +53 -0
  387. package/dist/game/kit.d.ts +53 -0
  388. package/dist/game/kit.js +2610 -0
  389. package/dist/game/kit.mjs +101 -0
  390. package/dist/game/prepared.d.mts +14 -0
  391. package/dist/game/prepared.d.ts +14 -0
  392. package/dist/game/prepared.js +81 -0
  393. package/dist/game/prepared.mjs +32 -0
  394. package/dist/game-Bx8onkhX.d.mts +1451 -0
  395. package/dist/game-fgQy2YIm.d.ts +1451 -0
  396. package/dist/game-theme-CBTw1b_d.d.mts +35 -0
  397. package/dist/game-theme-Dg-ict5A.d.ts +35 -0
  398. package/dist/game.d.mts +3546 -0
  399. package/dist/game.d.ts +3546 -0
  400. package/dist/game.js +4455 -0
  401. package/dist/game.mjs +50 -0
  402. package/dist/graphics-C6YjWYvP.d.ts +5 -0
  403. package/dist/graphics-Dk2yQnYN.d.mts +5 -0
  404. package/dist/guest-DrsA00XD.d.mts +732 -0
  405. package/dist/guest-wIdfoT05.d.ts +732 -0
  406. package/dist/hit-stop-BKkVwTq7.d.mts +43 -0
  407. package/dist/hit-stop-D-8pPYnM.d.ts +43 -0
  408. package/dist/hot-Crn9XpHJ.d.ts +29 -0
  409. package/dist/hot-DH3nOhQD.d.mts +29 -0
  410. package/dist/{index-CQStGb3B.d.mts → index-6gkHMGAq.d.mts} +2 -2
  411. package/dist/index-B8ybCKJI.d.ts +41 -0
  412. package/dist/{index-DJwXmoaP.d.ts → index-B98Xac8e.d.ts} +2 -2
  413. package/dist/{index-B7oA_1XI.d.ts → index-B_ByTtIT.d.ts} +2 -2
  414. package/dist/index-DHjNHb1c.d.mts +41 -0
  415. package/dist/{index-DhUSTAhT.d.mts → index-DbAN_VQE.d.mts} +2 -2
  416. package/dist/index.d.mts +134 -24
  417. package/dist/index.d.ts +134 -24
  418. package/dist/index.js +407 -248
  419. package/dist/index.mjs +184 -58
  420. package/dist/interactives-authoring.d.mts +231 -0
  421. package/dist/interactives-authoring.d.ts +231 -0
  422. package/dist/interactives-authoring.js +1743 -0
  423. package/dist/interactives-authoring.mjs +1704 -0
  424. package/dist/interactives-canvas.global.js +148 -0
  425. package/dist/interactives-guest.d.mts +20 -0
  426. package/dist/interactives-guest.d.ts +20 -0
  427. package/dist/interactives-guest.js +63 -0
  428. package/dist/interactives-guest.json +1 -0
  429. package/dist/interactives-guest.mjs +61 -0
  430. package/dist/interactives-jsc.global.js +9357 -0
  431. package/dist/interactives-meters.d.mts +93 -0
  432. package/dist/interactives-meters.d.ts +93 -0
  433. package/dist/interactives-meters.js +252 -0
  434. package/dist/interactives-meters.mjs +68 -0
  435. package/dist/interactives-production.d.mts +430 -0
  436. package/dist/interactives-production.d.ts +430 -0
  437. package/dist/interactives-production.js +1231 -0
  438. package/dist/interactives-production.mjs +1170 -0
  439. package/dist/interactives-record.d.mts +112 -0
  440. package/dist/interactives-record.d.ts +112 -0
  441. package/dist/interactives-record.js +302 -0
  442. package/dist/interactives-record.mjs +295 -0
  443. package/dist/interactives-runtime.d.mts +61 -0
  444. package/dist/interactives-runtime.d.ts +61 -0
  445. package/dist/interactives-runtime.js +442 -0
  446. package/dist/interactives-runtime.mjs +25 -0
  447. package/dist/interactives-studio-kernel.global.js +1 -0
  448. package/dist/interactives-studio.d.mts +806 -0
  449. package/dist/interactives-studio.d.ts +806 -0
  450. package/dist/interactives-studio.js +5741 -0
  451. package/dist/interactives-studio.mjs +5651 -0
  452. package/dist/interactives-tick.d.mts +90 -0
  453. package/dist/interactives-tick.d.ts +90 -0
  454. package/dist/interactives-tick.js +203 -0
  455. package/dist/interactives-tick.mjs +6 -0
  456. package/dist/interactives-web.d.mts +762 -0
  457. package/dist/interactives-web.d.ts +762 -0
  458. package/dist/interactives-web.js +5000 -0
  459. package/dist/interactives-web.mjs +4628 -0
  460. package/dist/interactives.d.mts +2430 -0
  461. package/dist/interactives.d.ts +2430 -0
  462. package/dist/interactives.js +5723 -0
  463. package/dist/interactives.mjs +4333 -0
  464. package/dist/juice-CoHxlpKA.d.ts +42 -0
  465. package/dist/juice-DQztFS43.d.mts +42 -0
  466. package/dist/launch-T2f4_Di4.d.mts +151 -0
  467. package/dist/launch-d6oreMzR.d.ts +151 -0
  468. package/dist/library-DXYaMFhi.d.mts +69 -0
  469. package/dist/library-DXYaMFhi.d.ts +69 -0
  470. package/dist/link-BUTqGmyi.d.mts +38 -0
  471. package/dist/link-BUTqGmyi.d.ts +38 -0
  472. package/dist/lint.js +104 -204
  473. package/dist/lint.mjs +103 -203
  474. package/dist/local-D8_I6UeL.d.mts +6967 -0
  475. package/dist/local-VZkqsCzR.d.ts +6967 -0
  476. package/dist/lockstep-BLf6dglI.d.mts +321 -0
  477. package/dist/lockstep-D50Ia0JW.d.ts +321 -0
  478. package/dist/ludo-B8ClkDqr.d.ts +205 -0
  479. package/dist/ludo-BOuohQ-M.d.mts +205 -0
  480. package/dist/mock/cli.mjs +200 -56
  481. package/dist/mock/library.js +200 -56
  482. package/dist/mock/library.mjs +200 -56
  483. package/dist/mock/msw.js +200 -56
  484. package/dist/mock/msw.mjs +200 -56
  485. package/dist/native-BodxSh03.d.mts +16 -0
  486. package/dist/native-DUHMT8gA.d.ts +16 -0
  487. package/dist/network-ZXLD7l1b.d.mts +19 -0
  488. package/dist/network-ZXLD7l1b.d.ts +19 -0
  489. package/dist/online-XeymeM9s.d.ts +381 -0
  490. package/dist/online-d7W_Al9a.d.mts +381 -0
  491. package/dist/params-DxFb5G_U.d.mts +155 -0
  492. package/dist/params-DxFb5G_U.d.ts +155 -0
  493. package/dist/play-BRRlfLhX.d.ts +940 -0
  494. package/dist/play-ClrMd_e8.d.mts +940 -0
  495. package/dist/policy-CCw8tXLm.d.mts +3078 -0
  496. package/dist/policy-CMqOSQIu.d.ts +3078 -0
  497. package/dist/ports-B_0v_P3A.d.mts +13 -0
  498. package/dist/ports-CGU_3e_0.d.ts +13 -0
  499. package/dist/prefetch-BHnicOQj.d.ts +117 -0
  500. package/dist/prefetch-CBXgYacv.d.mts +117 -0
  501. package/dist/{price-CSztR02F.d.mts → price-BOzexBww.d.mts} +1 -1
  502. package/dist/{price-C_vasx9A.d.ts → price-C1h9sPxE.d.ts} +1 -1
  503. package/dist/protocol-C8qbpUbT.d.mts +242 -0
  504. package/dist/protocol-C8qbpUbT.d.ts +242 -0
  505. package/dist/rapier-AZHT4YI7.js +7886 -0
  506. package/dist/rapier-ODEPCQA6.mjs +7792 -0
  507. package/dist/react.d.mts +157 -15
  508. package/dist/react.d.ts +157 -15
  509. package/dist/react.js +5564 -5904
  510. package/dist/react.mjs +5451 -5808
  511. package/dist/runner-CQcLL7By.d.ts +189 -0
  512. package/dist/runner-D46Yj-wE.d.mts +189 -0
  513. package/dist/runtime-BRWfkf_q.d.mts +51 -0
  514. package/dist/runtime-DyuBMkKM.d.ts +51 -0
  515. package/dist/scheduling-D2ajXpMC.d.ts +224 -0
  516. package/dist/scheduling-DSRbbaZb.d.mts +224 -0
  517. package/dist/schema-BrWxzKp6.d.mts +63 -0
  518. package/dist/schema-BrWxzKp6.d.ts +63 -0
  519. package/dist/server/evict.js +34 -37
  520. package/dist/server/evict.mjs +34 -37
  521. package/dist/server/tanstack.d.mts +49 -3
  522. package/dist/server/tanstack.d.ts +49 -3
  523. package/dist/server/tanstack.js +169 -117
  524. package/dist/server/tanstack.mjs +166 -118
  525. package/dist/{server-Dckg4Vdr.d.ts → server-D29IIuDV.d.ts} +136 -130
  526. package/dist/{server-B6dW7-Lj.d.mts → server-DQMWPnc8.d.mts} +136 -130
  527. package/dist/server.d.mts +45 -5
  528. package/dist/server.d.ts +45 -5
  529. package/dist/server.js +171 -227
  530. package/dist/server.mjs +165 -225
  531. package/dist/session-grant-CJ27DwrT.d.mts +19 -0
  532. package/dist/session-grant-CJ27DwrT.d.ts +19 -0
  533. package/dist/shootout-BJZeX6FG.d.ts +140 -0
  534. package/dist/shootout-tcZd1Rxt.d.mts +140 -0
  535. package/dist/state-replica-stMtdkVD.d.mts +42 -0
  536. package/dist/state-replica-stMtdkVD.d.ts +42 -0
  537. package/dist/studio-CowqWqez.d.mts +14 -0
  538. package/dist/studio-CowqWqez.d.ts +14 -0
  539. package/dist/styles.css +1 -1
  540. package/dist/template-AhCdB1kW.d.mts +190 -0
  541. package/dist/template-BkEGVTQj.d.ts +190 -0
  542. package/dist/terrain-BMxEc6Oc.d.ts +429 -0
  543. package/dist/terrain-C-XC1Oui.d.mts +429 -0
  544. package/dist/testing/msw.d.mts +28 -4
  545. package/dist/testing/msw.d.ts +28 -4
  546. package/dist/testing/msw.js +15 -21
  547. package/dist/testing/msw.mjs +15 -21
  548. package/dist/testing/suite.d.mts +6 -5
  549. package/dist/testing/suite.d.ts +6 -5
  550. package/dist/testing/suite.js +89 -124
  551. package/dist/testing/suite.mjs +81 -116
  552. package/dist/testing.d.mts +27 -1227
  553. package/dist/testing.d.ts +27 -1227
  554. package/dist/testing.js +127 -131
  555. package/dist/testing.mjs +19 -23
  556. package/dist/tick-transport-C8QEh8Uw.d.mts +50 -0
  557. package/dist/tick-transport-UjHY3xK1.d.ts +50 -0
  558. package/dist/timeline-protocol-hp6e8zFB.d.mts +47 -0
  559. package/dist/timeline-protocol-hp6e8zFB.d.ts +47 -0
  560. package/dist/tokens-DhanQRQS.d.mts +21 -0
  561. package/dist/tokens-K8yxwd6G.d.ts +21 -0
  562. package/dist/tree-C-Io2Hbx.d.mts +35 -0
  563. package/dist/tree-CP_qSW4H.d.ts +35 -0
  564. package/dist/tycoon-B5KHk2Xx.d.mts +255 -0
  565. package/dist/tycoon-hmHo-3HX.d.ts +255 -0
  566. package/dist/types-BQkxPwZP.d.mts +219 -0
  567. package/dist/types-D_f6UUxM.d.ts +219 -0
  568. package/dist/ui-DwHicuFv.d.mts +563 -0
  569. package/dist/ui-hi7S2YcH.d.ts +563 -0
  570. package/dist/{sign-in-DQlIdqsi.d.mts → url-52ndUruG.d.mts} +15 -1
  571. package/dist/{sign-in-DQlIdqsi.d.ts → url-52ndUruG.d.ts} +15 -1
  572. package/dist/utils.d.mts +3 -3
  573. package/dist/utils.d.ts +3 -3
  574. package/dist/utils.js +37 -37
  575. package/dist/utils.mjs +4 -4
  576. package/dist/vars-Dc_PrhBK.d.mts +511 -0
  577. package/dist/vars-Dc_PrhBK.d.ts +511 -0
  578. package/dist/vm-IUARFFAI.mjs +63 -0
  579. package/dist/vm-N7L6MGGH.js +65 -0
  580. package/dist/weave-delivery-CW-Kstut.d.mts +360 -0
  581. package/dist/weave-delivery-CW-Kstut.d.ts +360 -0
  582. package/dist/web-Dss74a7v.d.ts +883 -0
  583. package/dist/web-f9ZQPoyw.d.mts +883 -0
  584. package/dist/web-transport-C7MkBL0a.d.ts +19 -0
  585. package/dist/web-transport-aYEqXMd9.d.mts +19 -0
  586. package/dist/weight-CPGjsgjV.d.ts +92 -0
  587. package/dist/weight-tF1ODR1p.d.mts +92 -0
  588. package/dist/word-BcX9Jcmv.d.mts +70 -0
  589. package/dist/word-C7sVPLHm.d.ts +70 -0
  590. package/dist/world-PvILHDR1.d.ts +2285 -0
  591. package/dist/world-qekkXjJv.d.mts +2285 -0
  592. package/dist/worlds-Br2Pb0Cs.d.ts +109 -0
  593. package/dist/worlds-D5ydYr7d.d.mts +109 -0
  594. package/engines/c/cimplify.h +108 -0
  595. package/engines/c/cimplify.lib.js +11 -0
  596. package/engines/godot/addons/cimplify/cimplify.gd +97 -0
  597. package/engines/rust/interactives-ctx/Cargo.toml +9 -0
  598. package/engines/rust/interactives-ctx/src/lib.rs +189 -0
  599. package/package.json +189 -3
  600. package/vendor/rapier3d-compat/LICENSE +201 -0
  601. package/vendor/rapier3d-compat/PATCHES.md +61 -0
  602. package/dist/chunk-2P4KXFB6.js +0 -274
  603. package/dist/chunk-3G6RQLXK.mjs +0 -21
  604. package/dist/chunk-3V4DVXV3.mjs +0 -254
  605. package/dist/chunk-EDK3LNM6.js +0 -2436
  606. package/dist/chunk-F7J3HK27.js +0 -4549
  607. package/dist/chunk-U4MW6PYU.mjs +0 -23
  608. package/dist/chunk-XREIZ56K.js +0 -26
@@ -0,0 +1,3866 @@
1
+ interface AudioCapabilities {
2
+ readonly spatial: boolean;
3
+ readonly filters: boolean;
4
+ readonly meters: boolean;
5
+ readonly analyser: boolean;
6
+ readonly reverb: boolean;
7
+ readonly sends: boolean;
8
+ readonly loopPoints: boolean;
9
+ readonly streaming: boolean;
10
+ readonly detune: boolean;
11
+ readonly procedural: boolean;
12
+ readonly emitters?: boolean;
13
+ readonly lockstep?: boolean;
14
+ readonly voiceLimits?: boolean;
15
+ readonly voiceFilters?: boolean;
16
+ readonly limiter?: boolean;
17
+ readonly scheduling?: boolean;
18
+ readonly music?: boolean;
19
+ readonly binaural?: boolean;
20
+ readonly occlusion?: boolean;
21
+ }
22
+ interface OcclusionDesc {
23
+ readonly radius?: number;
24
+ readonly occludedGain?: number;
25
+ readonly occludedCutoff?: number;
26
+ readonly smoothingSeconds?: number;
27
+ }
28
+ type MusicQuantize = "now" | "beat" | "bar" | {
29
+ readonly bars: number;
30
+ };
31
+ interface LimiterDesc {
32
+ readonly ceilingDb?: number;
33
+ readonly releaseSeconds?: number;
34
+ }
35
+ declare const STEAL_POLICIES: readonly ["oldest", "quietest", "refuse"];
36
+ type StealPolicy = (typeof STEAL_POLICIES)[number];
37
+ interface SoundLimitDesc {
38
+ readonly voices: number;
39
+ readonly steal?: StealPolicy;
40
+ }
41
+ /**
42
+ * A sound's boot preview: mono, 22.05 kHz AAC-LC at about 24 kbps, catalogued beside the sound at its path plus this
43
+ * suffix. The publish step makes it for large sounds in a before-play group and moves the full file after start; hosts
44
+ * play the preview until the full file arrives.
45
+ */
46
+ declare const AUDIO_PREVIEW_SUFFIX = ".preview.m4a";
47
+ declare const FILTER_KINDS: readonly ["lowpass", "highpass", "bandpass", "notch", "allpass", "peaking", "lowshelf", "highshelf"];
48
+ type FilterKind = (typeof FILTER_KINDS)[number];
49
+ interface FilterDesc {
50
+ readonly kind: FilterKind;
51
+ readonly frequency: number;
52
+ readonly q?: number;
53
+ readonly gain?: number;
54
+ }
55
+ declare const DISTANCE_MODELS: readonly ["linear", "inverse", "exponential"];
56
+ type DistanceModel = (typeof DISTANCE_MODELS)[number];
57
+ interface PannerDesc {
58
+ readonly distanceModel?: DistanceModel;
59
+ readonly refDistance?: number;
60
+ readonly maxDistance?: number;
61
+ readonly rolloff?: number;
62
+ readonly coneInnerAngle?: number;
63
+ readonly coneOuterAngle?: number;
64
+ readonly coneOuterGain?: number;
65
+ readonly doppler?: number;
66
+ }
67
+ declare const DEFAULT_PANNER: {
68
+ readonly distanceModel: "inverse";
69
+ readonly refDistance: 1;
70
+ readonly maxDistance: 10000;
71
+ readonly rolloff: 1;
72
+ readonly coneInnerAngle: 360;
73
+ readonly coneOuterAngle: 360;
74
+ readonly coneOuterGain: 0;
75
+ readonly doppler: 0;
76
+ };
77
+ interface AnalyserDesc {
78
+ readonly fftSize?: number;
79
+ readonly smoothing?: number;
80
+ readonly minDecibels?: number;
81
+ readonly maxDecibels?: number;
82
+ }
83
+ declare function detuneRate(rate: number, cents: number): number;
84
+
85
+ interface AnalyserSettings {
86
+ readonly fftSize: number;
87
+ readonly smoothing: number;
88
+ readonly minDecibels: number;
89
+ readonly maxDecibels: number;
90
+ }
91
+ declare function analyserSettings(desc?: AnalyserDesc): AnalyserSettings;
92
+ declare class FftAnalyser {
93
+ readonly fftSize: number;
94
+ readonly binCount: number;
95
+ smoothing: number;
96
+ minDecibels: number;
97
+ maxDecibels: number;
98
+ private readonly ring;
99
+ private head;
100
+ private readonly real;
101
+ private readonly imag;
102
+ private readonly window;
103
+ private readonly smoothed;
104
+ private readonly bitReverse;
105
+ private readonly cos;
106
+ private readonly sin;
107
+ constructor(settings: AnalyserSettings);
108
+ push(samples: ArrayLike<number>, start: number, count: number): void;
109
+ reset(): void;
110
+ timeDomain(out: Float32Array | Uint8Array): void;
111
+ frequency(out: Float32Array | Uint8Array): void;
112
+ private transform;
113
+ }
114
+
115
+ type Scalar = "f32" | "f64" | "i8" | "i16" | "i32" | "u8" | "u16" | "u32";
116
+ type TypedArray = Float32Array | Float64Array | Int8Array | Int16Array | Int32Array | Uint8Array | Uint16Array | Uint32Array;
117
+ type ArrayFor<S extends Scalar> = S extends "f32" ? Float32Array : S extends "f64" ? Float64Array : S extends "i8" ? Int8Array : S extends "i16" ? Int16Array : S extends "i32" ? Int32Array : S extends "u8" ? Uint8Array : S extends "u16" ? Uint16Array : Uint32Array;
118
+ interface ComponentMemory {
119
+ allocate<S extends Scalar>(scalar: S, length: number): ArrayFor<S>;
120
+ }
121
+
122
+ /** Priority for `WorldPackReader.take`: `now` holds first input, `soon` follows it. */
123
+ declare const AssetPriority: {
124
+ readonly now: 0;
125
+ readonly soon: 1;
126
+ };
127
+ type DeviceTier = "low" | "mid" | "high";
128
+ interface WorldStreamingPort {
129
+ lazyPacks?(): boolean;
130
+ open(world: Uint8Array, materials: readonly number[], tier: number): number;
131
+ provide(stream: number, pack: Uint8Array): number;
132
+ update(stream: number, eye: Float32Array): void;
133
+ registers(stream: number): Uint32Array;
134
+ openLogic(stream: number, stepSeconds: number, budget: number, actors: number): number;
135
+ stepLogic(stream: number, actors: Float32Array, count: number, ops: Uint32Array): number;
136
+ collider(stream: number, index: number, out: Float32Array): void;
137
+ close(stream: number): void;
138
+ }
139
+
140
+ declare const TERRAIN_REGISTER: {
141
+ readonly requested: 0;
142
+ readonly installed: 1;
143
+ readonly inflight: 2;
144
+ readonly resident: 3;
145
+ readonly nodes: 4;
146
+ readonly touched: 5;
147
+ readonly deferred: 6;
148
+ readonly totalInstalls: 7;
149
+ };
150
+ declare const BRUSH: {
151
+ readonly raise: 0;
152
+ readonly lower: 1;
153
+ readonly smooth: 2;
154
+ readonly flatten: 3;
155
+ readonly paint: 4;
156
+ readonly hole: 5;
157
+ readonly fill: 6;
158
+ };
159
+ type BrushOp = keyof typeof BRUSH;
160
+ declare const NOISE: {
161
+ readonly perlin: 0;
162
+ readonly simplex2: 1;
163
+ readonly simplex3: 2;
164
+ readonly worley: 3;
165
+ };
166
+ type NoiseKind = keyof typeof NOISE;
167
+ interface TerrainPort {
168
+ open(desc: Float32Array, source: number, recipe: Float32Array, pack: Uint8Array | null): number;
169
+ close(terrain: number): void;
170
+ update(terrain: number, eye: Float32Array): number;
171
+ registers(terrain: number): Uint32Array;
172
+ height(x: number, z: number): number;
173
+ normal(x: number, z: number, out: Float32Array): boolean;
174
+ sculpt(terrain: number, brush: Float32Array): number;
175
+ colliders(terrain: number, x: number, y: number, z: number): number;
176
+ gravity(x: number, y: number, z: number, surface: number, radius: number): number;
177
+ grass(params: Float32Array): number;
178
+ wind(x: number, z: number, strength: number, gust: number): void;
179
+ interactors(data: Float32Array, count: number): void;
180
+ look(layers: Float32Array, count: number): void;
181
+ scatter(rules: Float32Array, out: Float32Array, capacity: number): number;
182
+ noise(kind: number, x: number, y: number, z: number, seed: number): number;
183
+ fbm(x: number, z: number, octaves: number, frequency: number, seed: number): number;
184
+ }
185
+
186
+ declare const SCENERY_REQUEST_SLOTS = 8;
187
+ declare const SCENERY_REGISTER_WORDS = 20;
188
+ declare const SCENERY_REGISTER: {
189
+ readonly chunks: 0;
190
+ readonly resident: 1;
191
+ readonly requested: 2;
192
+ readonly installed: 3;
193
+ readonly evicted: 4;
194
+ readonly deferred: 5;
195
+ readonly failed: 6;
196
+ readonly installedKib: 7;
197
+ readonly residentSplats: 8;
198
+ readonly drawnSplats: 9;
199
+ readonly listedPages: 10;
200
+ readonly poolCapacity: 11;
201
+ readonly poolFreePages: 12;
202
+ readonly tier: 13;
203
+ readonly updates: 14;
204
+ readonly heroSplats: 15;
205
+ readonly heroShed: 16;
206
+ readonly standIn: 17;
207
+ readonly deformedSplats: 18;
208
+ };
209
+ interface SceneryBodyPort {
210
+ edit(scene: number, region: number, values: Float32Array): void;
211
+ bind(scene: number, root: number): void;
212
+ heroBudget(scene: number, caps: Uint32Array | null): void;
213
+ drape(scene: number, cloths: number, cloth: number, region: number, rest: Float32Array | null): void;
214
+ motionRows(scene: number): number;
215
+ motion(scene: number, table: number, columns: Uint32Array | null, reachMillimetres: number, mask: number): void;
216
+ }
217
+ interface SceneryPort {
218
+ readonly bodies?: SceneryBodyPort | null;
219
+ open(manifest: Uint8Array): number;
220
+ provide(scene: number, index: number, chunk: Uint8Array): number;
221
+ fail(scene: number, index: number): number;
222
+ update(scene: number, eye: Float32Array, requests: Uint32Array): number;
223
+ setTransform(scene: number, transform: Float32Array): void;
224
+ registers(scene: number): Uint32Array;
225
+ close(scene: number): void;
226
+ }
227
+
228
+ declare const SOA_EXPORT_NAMES: readonly ["engine_soa_create", "engine_soa_destroy", "engine_soa_generations", "engine_soa_header", "engine_soa_turn", "engine_soa_remove", "engine_soa_map", "engine_soa_vec", "engine_soa_select", "engine_soa_reduce", "engine_soa_sort", "engine_soa_grid", "engine_soa_near", "engine_soa_nearest"];
229
+ type SoaExportName = (typeof SOA_EXPORT_NAMES)[number];
230
+ type SoaExports = Readonly<Record<SoaExportName | "engine_alloc" | "engine_free", (...args: number[]) => number>>;
231
+ declare const SOA_BULK_EXPORT_NAMES: readonly ["engine_soa_inventory", "engine_soa_effect", "engine_soa_raycast", "engine_soa_paths", "engine_soa_pick", "engine_soa_flow", "engine_flow_create", "engine_flow_destroy", "engine_flow_registers", "engine_flow_costs", "engine_flow_rasterize", "engine_flow_build"];
232
+ type SoaBulkName = (typeof SOA_BULK_EXPORT_NAMES)[number];
233
+ type SoaBulkExports = Partial<Readonly<Record<SoaBulkName, (...args: number[]) => number>>>;
234
+ interface SoaEngine {
235
+ readonly exports: SoaExports;
236
+ readonly memory: {
237
+ readonly buffer: ArrayBufferLike;
238
+ };
239
+ readonly bulk?: SoaBulkExports;
240
+ }
241
+ declare function bindSoaEngine(symbols: Readonly<Record<string, unknown>>, memory: {
242
+ readonly buffer: ArrayBufferLike;
243
+ }): SoaEngine | null;
244
+
245
+ interface Vec3Like {
246
+ x: number;
247
+ y: number;
248
+ z: number;
249
+ }
250
+ declare class Vec2 {
251
+ x: number;
252
+ y: number;
253
+ constructor(x?: number, y?: number);
254
+ set(x: number, y: number): this;
255
+ copy(v: Vec2): this;
256
+ length(): number;
257
+ add(v: Vec2): this;
258
+ sub(v: Vec2): this;
259
+ scale(s: number): this;
260
+ dot(v: Vec2): number;
261
+ cross(v: Vec2): number;
262
+ normalize(): this;
263
+ distanceTo(v: Vec2): number;
264
+ lerp(a: Vec2, b: Vec2, t: number): this;
265
+ angle(): number;
266
+ rotateAround(center: Vec2, radians: number): this;
267
+ }
268
+ declare class Vec4 {
269
+ x: number;
270
+ y: number;
271
+ z: number;
272
+ w: number;
273
+ constructor(x?: number, y?: number, z?: number, w?: number);
274
+ set(x: number, y: number, z: number, w: number): this;
275
+ copy(v: Vec4): this;
276
+ dot(v: Vec4): number;
277
+ length(): number;
278
+ scale(s: number): this;
279
+ lerp(a: Vec4, b: Vec4, t: number): this;
280
+ applyMat4(m: ArrayLike<number>, o: number): this;
281
+ readFrom(array: ArrayLike<number>, offset: number): this;
282
+ writeTo(array: Float32Array | Float64Array, offset: number): void;
283
+ }
284
+ declare class Vec3 implements Vec3Like {
285
+ x: number;
286
+ y: number;
287
+ z: number;
288
+ constructor(x?: number, y?: number, z?: number);
289
+ set(x: number, y: number, z: number): this;
290
+ copy(v: Vec3Like): this;
291
+ add(v: Vec3Like): this;
292
+ sub(v: Vec3Like): this;
293
+ scale(s: number): this;
294
+ addScaled(v: Vec3Like, s: number): this;
295
+ dot(v: Vec3Like): number;
296
+ cross(a: Vec3Like, b: Vec3Like): this;
297
+ lengthSq(): number;
298
+ length(): number;
299
+ normalize(): this;
300
+ lerp(a: Vec3Like, b: Vec3Like, t: number): this;
301
+ distanceTo(v: Vec3Like): number;
302
+ distanceToSquared(v: Vec3Like): number;
303
+ negate(): this;
304
+ min(v: Vec3Like): this;
305
+ max(v: Vec3Like): this;
306
+ clamp(lo: Vec3Like, hi: Vec3Like): this;
307
+ clampLength(min: number, max: number): this;
308
+ subVectors(a: Vec3Like, b: Vec3Like): this;
309
+ addVectors(a: Vec3Like, b: Vec3Like): this;
310
+ applyQuat(q: Quat): this;
311
+ applyMat4(m: ArrayLike<number>, o: number): this;
312
+ transformDirection(m: ArrayLike<number>, o: number): this;
313
+ projectOnVector(v: Vec3Like): this;
314
+ projectOnPlane(normal: Vec3Like): this;
315
+ reflect(normal: Vec3Like): this;
316
+ angleTo(v: Vec3Like): number;
317
+ setFromSpherical(radius: number, polar: number, azimuth: number): this;
318
+ setFromMatrixColumn(m: ArrayLike<number>, o: number, column: number): this;
319
+ equals(v: Vec3Like, tolerance?: number): boolean;
320
+ readFrom(array: ArrayLike<number>, offset: number): this;
321
+ writeTo(array: Float32Array | Float64Array, offset: number): void;
322
+ }
323
+ declare class Quat {
324
+ x: number;
325
+ y: number;
326
+ z: number;
327
+ w: number;
328
+ constructor(x?: number, y?: number, z?: number, w?: number);
329
+ set(x: number, y: number, z: number, w: number): this;
330
+ identity(): this;
331
+ copy(q: Quat): this;
332
+ setAxisAngle(axis: Vec3Like, radians: number): this;
333
+ setEuler(x: number, y: number, z: number): this;
334
+ multiply(a: Quat, b: Quat): this;
335
+ normalize(): this;
336
+ rotate(v: Vec3): Vec3;
337
+ dot(q: Quat): number;
338
+ conjugate(): this;
339
+ invert(): this;
340
+ premultiply(q: Quat): this;
341
+ slerp(a: Quat, b: Quat, t: number): this;
342
+ rotateTowards(target: Quat, maxRadians: number): this;
343
+ angleTo(q: Quat): number;
344
+ setFromUnitVectors(from: Vec3Like, to: Vec3Like): this;
345
+ setFromRotationMatrix(m: ArrayLike<number>, o: number): this;
346
+ lookRotation(forwardX: number, forwardY: number, forwardZ: number, upX?: number, upY?: number, upZ?: number): this;
347
+ toEuler(out: Vec3): Vec3;
348
+ readFrom(array: ArrayLike<number>, offset: number): this;
349
+ writeTo(array: Float32Array | Float64Array, offset: number): void;
350
+ }
351
+
352
+ declare const FRAME_STEP_SECONDS_SLOT = 0;
353
+ declare const FRAME_SECONDS_SLOT = 1;
354
+ declare const FRAME_ALPHA_SLOT = 2;
355
+ declare const TIME_SCALE_SLOT = 6;
356
+ declare const FRAME_TICK_SLOT = 7;
357
+ declare const FRAME_NOW_MS_SLOT = 8;
358
+ declare class FrameTime {
359
+ readonly values: Float64Array<ArrayBuffer>;
360
+ get stepSeconds(): number;
361
+ get frameSeconds(): number;
362
+ get alpha(): number;
363
+ get tick(): number;
364
+ }
365
+ interface LoopOptions {
366
+ fixedHz?: number;
367
+ maxSubsteps?: number;
368
+ maxFrameDeltaMs?: number;
369
+ }
370
+ declare class FixedStepLoop {
371
+ readonly time: FrameTime;
372
+ private readonly views;
373
+ rollbackViews(): readonly ArrayBufferView[];
374
+ readonly stepMs: number;
375
+ readonly maxSubsteps: number;
376
+ readonly maxFrameDeltaMs: number;
377
+ constructor(options?: LoopOptions);
378
+ get stepSeconds(): number;
379
+ get alpha(): number;
380
+ get tick(): number;
381
+ get frameDeltaSeconds(): number;
382
+ get droppedTimeMs(): number;
383
+ get timeScale(): number;
384
+ set timeScale(scale: number);
385
+ begin(nowMs: number): number;
386
+ beginAtClock(): number;
387
+ /** Keeps the clock at this frame without stepping, so a held game resumes without catching up the time it was held. */
388
+ hold(): void;
389
+ completeStep(): void;
390
+ settle(steps: number): void;
391
+ reset(): void;
392
+ }
393
+
394
+ declare const AGENT_X = 0;
395
+ declare const AGENT_STRIDE = 8;
396
+ declare const AGENT_IDLE = 0;
397
+ declare const AGENT_REQUESTING = 1;
398
+ declare const AGENT_MOVING = 2;
399
+ declare const AGENT_ARRIVED = 3;
400
+ declare const AGENT_LOST = 4;
401
+ declare const AGENT_ON_LINK = 5;
402
+ declare const NO_LINK = -1;
403
+ declare const POSE_X = 0;
404
+ declare const POSE_Z = 2;
405
+ declare const POSE_DIR_X = 3;
406
+ declare const POSE_DIR_Z = 4;
407
+ declare const POSE_SPEED = 5;
408
+ declare const POSE_LANE = 6;
409
+ declare const POSE_STRIDE$1 = 8;
410
+ declare const SIGNAL_GREEN = 0;
411
+ declare const SIGNAL_AMBER = 1;
412
+ declare const SIGNAL_RED = 2;
413
+ interface NavDesc {
414
+ readonly tileWorld: number;
415
+ readonly origin?: readonly [number, number];
416
+ readonly maxTiles?: number;
417
+ readonly queryNodes?: number;
418
+ readonly maxAgents?: number;
419
+ readonly neighbourDistance?: number;
420
+ readonly timeHorizon?: number;
421
+ readonly pathBudget?: number;
422
+ readonly maxPathPolys?: number;
423
+ readonly extents?: readonly [number, number, number];
424
+ }
425
+ interface AgentDesc {
426
+ readonly radius?: number;
427
+ readonly maxSpeed?: number;
428
+ readonly maxAcceleration?: number;
429
+ }
430
+ interface OffMeshLinkDesc {
431
+ readonly start: readonly [number, number, number];
432
+ readonly end: readonly [number, number, number];
433
+ readonly radius?: number;
434
+ readonly bidirectional?: boolean;
435
+ readonly area?: number;
436
+ readonly user?: number;
437
+ }
438
+ interface DriverDesc {
439
+ readonly length?: number;
440
+ readonly desire?: number;
441
+ readonly headway?: number;
442
+ readonly jam?: number;
443
+ readonly accel?: number;
444
+ readonly decel?: number;
445
+ }
446
+ interface LaneSpec {
447
+ readonly points: readonly (readonly [number, number, number])[];
448
+ readonly speedLimit: number;
449
+ readonly next?: readonly number[];
450
+ readonly signal?: number;
451
+ readonly group?: number;
452
+ readonly giveWay?: boolean;
453
+ readonly conflicts?: readonly number[];
454
+ }
455
+ interface SignalSpec {
456
+ readonly phases: readonly {
457
+ readonly groups: readonly number[];
458
+ readonly seconds: number;
459
+ }[];
460
+ readonly amber: number;
461
+ readonly offset?: number;
462
+ }
463
+ interface RoadGraphDesc {
464
+ readonly lanes: readonly LaneSpec[];
465
+ readonly signals?: readonly SignalSpec[];
466
+ readonly maxVehicles: number;
467
+ readonly seed?: number;
468
+ }
469
+ interface NavPort {
470
+ readonly name: string;
471
+ init(desc: NavDesc): void;
472
+ addTile(bytes: Uint8Array): number;
473
+ removeTile(x: number, z: number): void;
474
+ addLink(start: readonly [number, number, number], end: readonly [number, number, number], radius: number, bidirectional: boolean, area: number, user: number): number;
475
+ removeLink(link: number): void;
476
+ setAreaCost(area: number, cost: number): void;
477
+ setIncludeMask(low: number, high: number): void;
478
+ nearest(x: number, y: number, z: number, out: Float32Array): boolean;
479
+ findPath(sx: number, sy: number, sz: number, ex: number, ey: number, ez: number, out: Float32Array): number;
480
+ readonly pathComplete: boolean;
481
+ batchHandle?(): number;
482
+ addAgent(x: number, y: number, z: number, radius: number, speed: number, accel: number): number;
483
+ removeAgent(agent: number): void;
484
+ setAgentTarget(agent: number, x: number, y: number, z: number): void;
485
+ stopAgent(agent: number): void;
486
+ agents(): Float32Array;
487
+ loadRoads(words: Uint32Array): void;
488
+ addVehicle(lane: number, position: number, speed: number, driver: Float32Array): number;
489
+ removeVehicle(vehicle: number): void;
490
+ setExternalVehicle(vehicle: number, lane: number, position: number, speed: number): void;
491
+ vehicles(): Float32Array;
492
+ signal(lane: number): number;
493
+ step(dt: number): void;
494
+ dispose(): void;
495
+ }
496
+
497
+ interface RollbackState {
498
+ rollbackViews(): readonly ArrayBufferView[];
499
+ }
500
+
501
+ type SnapshotPolicy = "scan" | "marked";
502
+ interface WorldRollbackDesc {
503
+ readonly regionBytes?: number;
504
+ readonly trackedBytes?: number;
505
+ readonly journalBytes?: number;
506
+ readonly frames?: number;
507
+ }
508
+ interface WorldSnapshotStats {
509
+ readonly depth: number;
510
+ readonly newest: number | null;
511
+ readonly oldest: number | null;
512
+ readonly dirtyPages: number;
513
+ readonly scannedPages: number;
514
+ readonly restoredPages: number;
515
+ readonly saveMs: number;
516
+ readonly restoreMs: number;
517
+ readonly evicted: number;
518
+ readonly heapBytes: number;
519
+ readonly trackedPages: number;
520
+ readonly spilled: boolean;
521
+ readonly breaks: number;
522
+ readonly residents: number;
523
+ readonly quietPages: number;
524
+ readonly missedPages: number;
525
+ }
526
+ interface KeyframeDesc {
527
+ readonly every?: number;
528
+ readonly slots?: number;
529
+ readonly leaves?: number;
530
+ }
531
+ interface KeyframeStats {
532
+ readonly frames: number;
533
+ readonly oldest: number | null;
534
+ readonly newest: number | null;
535
+ readonly leavesUsed: number;
536
+ readonly leavesShared: number;
537
+ readonly captures: number;
538
+ readonly evicted: number;
539
+ readonly installs: number;
540
+ }
541
+ declare class WorldSnapshots {
542
+ private readonly exports;
543
+ private readonly memory;
544
+ readonly world: number;
545
+ private readonly beforeRestore;
546
+ private view;
547
+ private digestAt;
548
+ private readonly ring;
549
+ private keyRing;
550
+ private keyframes;
551
+ private every;
552
+ private readonly states;
553
+ private constructor();
554
+ static bind(symbols: Readonly<Record<string, unknown>>, memory: {
555
+ readonly buffer: ArrayBufferLike;
556
+ }, world: number, beforeRestore?: () => void, frames?: number): WorldSnapshots | null;
557
+ attach(state: RollbackState): void;
558
+ enableKeyframes(desc: KeyframeDesc): boolean;
559
+ get keyframeEvery(): number;
560
+ keyframe(tick: number): boolean;
561
+ nearestKeyframe(at: number): number | null;
562
+ seekKeyframe(tick: number): boolean;
563
+ truncateKeyframes(after: number): void;
564
+ clearKeyframes(): void;
565
+ keyframeStats(): KeyframeStats | null;
566
+ get stateBreaks(): number;
567
+ save(tick: number): number;
568
+ restore(tick: number): boolean;
569
+ clear(): void;
570
+ private adopt;
571
+ track(view: ArrayBufferView, policy?: SnapshotPolicy): void;
572
+ trackTable(table: number, policy?: SnapshotPolicy): void;
573
+ untrack(view: ArrayBufferView): void;
574
+ mark(view: ArrayBufferView & {
575
+ readonly BYTES_PER_ELEMENT: number;
576
+ }, from?: number, to?: number): boolean;
577
+ digest(): bigint;
578
+ stats(): WorldSnapshotStats;
579
+ private registers;
580
+ private owned;
581
+ private check;
582
+ }
583
+
584
+ type BodyKind = "dynamic" | "kinematic" | "fixed";
585
+ interface BodyDesc {
586
+ readonly kind: BodyKind;
587
+ readonly linearDamping?: number;
588
+ readonly angularDamping?: number;
589
+ readonly gravityScale?: number;
590
+ readonly ccd?: boolean;
591
+ readonly canSleep?: boolean;
592
+ readonly lockRotations?: boolean;
593
+ readonly lockTranslations?: boolean;
594
+ readonly enabledTranslations?: readonly [boolean, boolean, boolean];
595
+ readonly enabledRotations?: readonly [boolean, boolean, boolean];
596
+ readonly planar?: boolean;
597
+ readonly dominance?: number;
598
+ }
599
+ type PrimitiveShapeDesc = {
600
+ readonly kind: "ball";
601
+ readonly radius: number;
602
+ } | {
603
+ readonly kind: "cuboid";
604
+ readonly halfExtents: readonly [number, number, number];
605
+ } | {
606
+ readonly kind: "capsule";
607
+ readonly halfHeight: number;
608
+ readonly radius: number;
609
+ } | {
610
+ readonly kind: "cylinder";
611
+ readonly halfHeight: number;
612
+ readonly radius: number;
613
+ } | {
614
+ readonly kind: "cone";
615
+ readonly halfHeight: number;
616
+ readonly radius: number;
617
+ } | {
618
+ readonly kind: "round_cuboid";
619
+ readonly halfExtents: readonly [number, number, number];
620
+ readonly border: number;
621
+ } | {
622
+ readonly kind: "round_cylinder";
623
+ readonly halfHeight: number;
624
+ readonly radius: number;
625
+ readonly border: number;
626
+ } | {
627
+ readonly kind: "round_cone";
628
+ readonly halfHeight: number;
629
+ readonly radius: number;
630
+ readonly border: number;
631
+ };
632
+ interface CompoundPartDesc {
633
+ readonly shape: PrimitiveShapeDesc;
634
+ readonly offset?: readonly [number, number, number];
635
+ readonly rotation?: readonly [number, number, number, number];
636
+ }
637
+ type ShapeDesc = PrimitiveShapeDesc | {
638
+ readonly kind: "round_convex_hull";
639
+ readonly points: Float32Array;
640
+ readonly border: number;
641
+ } | {
642
+ readonly kind: "compound";
643
+ readonly parts: readonly CompoundPartDesc[];
644
+ } | {
645
+ readonly kind: "trimesh";
646
+ readonly vertices: Float32Array;
647
+ readonly indices: Uint32Array;
648
+ } | {
649
+ readonly kind: "convex_hull";
650
+ readonly points: Float32Array;
651
+ } | {
652
+ readonly kind: "heightfield";
653
+ readonly rows: number;
654
+ readonly columns: number;
655
+ readonly heights: Float32Array;
656
+ readonly scale: readonly [number, number, number];
657
+ };
658
+ interface ColliderDesc {
659
+ readonly shape: ShapeDesc;
660
+ readonly offset?: readonly [number, number, number];
661
+ readonly rotation?: readonly [number, number, number, number];
662
+ readonly density?: number;
663
+ readonly mass?: number;
664
+ readonly friction?: number;
665
+ readonly restitution?: number;
666
+ readonly sensor?: boolean;
667
+ readonly events?: boolean;
668
+ readonly membership?: number;
669
+ readonly filter?: number;
670
+ }
671
+ type JointDesc = {
672
+ readonly kind: "fixed";
673
+ readonly anchorA: readonly [number, number, number];
674
+ readonly anchorB: readonly [number, number, number];
675
+ } | {
676
+ readonly kind: "spherical";
677
+ readonly anchorA: readonly [number, number, number];
678
+ readonly anchorB: readonly [number, number, number];
679
+ } | {
680
+ readonly kind: "revolute";
681
+ readonly anchorA: readonly [number, number, number];
682
+ readonly anchorB: readonly [number, number, number];
683
+ readonly axis: readonly [number, number, number];
684
+ readonly limits?: readonly [number, number];
685
+ } | {
686
+ readonly kind: "prismatic";
687
+ readonly anchorA: readonly [number, number, number];
688
+ readonly anchorB: readonly [number, number, number];
689
+ readonly axis: readonly [number, number, number];
690
+ readonly limits?: readonly [number, number];
691
+ } | {
692
+ readonly kind: "rope";
693
+ readonly anchorA: readonly [number, number, number];
694
+ readonly anchorB: readonly [number, number, number];
695
+ readonly length: number;
696
+ } | {
697
+ readonly kind: "spring";
698
+ readonly anchorA: readonly [number, number, number];
699
+ readonly anchorB: readonly [number, number, number];
700
+ readonly restLength: number;
701
+ readonly stiffness: number;
702
+ readonly damping: number;
703
+ } | {
704
+ readonly kind: "cone";
705
+ readonly anchorA: readonly [number, number, number];
706
+ readonly anchorB: readonly [number, number, number];
707
+ readonly axis: readonly [number, number, number];
708
+ readonly swing: number;
709
+ readonly twist: readonly [number, number];
710
+ } | {
711
+ readonly kind: "six_dof";
712
+ readonly anchorA: readonly [number, number, number];
713
+ readonly anchorB: readonly [number, number, number];
714
+ readonly frameA?: readonly [number, number, number, number];
715
+ readonly frameB?: readonly [number, number, number, number];
716
+ readonly linear?: readonly [AxisMotion, AxisMotion, AxisMotion];
717
+ readonly angular?: readonly [AxisMotion, AxisMotion, AxisMotion];
718
+ readonly swingCone?: number;
719
+ };
720
+ type AxisMotion = "locked" | "free" | readonly [number, number];
721
+ interface CharacterControllerDesc {
722
+ readonly offset?: number;
723
+ readonly maxSlopeClimbDegrees?: number;
724
+ readonly minSlopeSlideDegrees?: number;
725
+ readonly autostepMaxHeight?: number;
726
+ readonly autostepMinWidth?: number;
727
+ readonly snapToGround?: number;
728
+ readonly slide?: boolean;
729
+ readonly up?: readonly [number, number, number];
730
+ }
731
+ declare const MAX_SOLVER_ITERATIONS = 64;
732
+ declare const MAX_PGS_ITERATIONS = 16;
733
+ declare const MAX_CCD_SUBSTEPS = 16;
734
+ interface SolverSettings {
735
+ readonly iterations?: number;
736
+ readonly pgsIterations?: number;
737
+ readonly ccdSubsteps?: number;
738
+ }
739
+ interface SleepThresholds {
740
+ readonly linear?: number;
741
+ readonly angular?: number;
742
+ readonly seconds?: number;
743
+ }
744
+ interface PhysicsWorldDesc {
745
+ readonly gravity?: readonly [number, number, number];
746
+ readonly stepSeconds: number;
747
+ readonly maxBodies?: number;
748
+ readonly maxColliders?: number;
749
+ readonly maxJoints?: number;
750
+ readonly maxContactEvents?: number;
751
+ readonly maxCharacterControllers?: number;
752
+ readonly rollback?: WorldRollbackDesc;
753
+ }
754
+ declare class RayQuery {
755
+ readonly origin: Vec3;
756
+ readonly direction: Vec3;
757
+ maxDistance: number;
758
+ solid: boolean;
759
+ includeSensors: boolean;
760
+ excludeCollider: number;
761
+ set(ox: number, oy: number, oz: number, dx: number, dy: number, dz: number, maxDistance: number): this;
762
+ }
763
+ declare class RayHit {
764
+ hit: boolean;
765
+ collider: number;
766
+ distance: number;
767
+ pointX: number;
768
+ pointY: number;
769
+ pointZ: number;
770
+ normalX: number;
771
+ normalY: number;
772
+ normalZ: number;
773
+ }
774
+ declare class CharacterMove {
775
+ grounded: boolean;
776
+ x: number;
777
+ y: number;
778
+ z: number;
779
+ }
780
+
781
+ type Base = Omit<StandardMaterialDesc, "kind" | "metalness" | "metalnessMap">;
782
+ interface SkinMaterialDesc extends Base {
783
+ readonly kind: "skin";
784
+ readonly scatter?: readonly [number, number, number];
785
+ readonly thickness?: number;
786
+ readonly sheen?: number;
787
+ readonly sheenRoughness?: number;
788
+ readonly warmth?: number;
789
+ readonly rim?: number;
790
+ }
791
+ interface EyeMaterialDesc extends Base {
792
+ readonly kind: "eye";
793
+ readonly irisMap?: TextureId;
794
+ readonly irisRadius?: number;
795
+ readonly irisDepth?: number;
796
+ readonly limbus?: number;
797
+ readonly pupil?: number;
798
+ }
799
+ interface HairMaterialDesc extends Base {
800
+ readonly kind: "hair";
801
+ readonly melanin?: number;
802
+ readonly redness?: number;
803
+ readonly azimuthalRoughness?: number;
804
+ readonly density?: number;
805
+ }
806
+
807
+ declare const geometryBrand: unique symbol;
808
+ declare const materialBrand: unique symbol;
809
+ declare const textureBrand: unique symbol;
810
+ declare const nodeBrand: unique symbol;
811
+ declare const renderTargetBrand: unique symbol;
812
+ declare const postChainBrand: unique symbol;
813
+ declare const renderPassBrand: unique symbol;
814
+ declare const modelBrand: unique symbol;
815
+ declare const clipActionBrand: unique symbol;
816
+ declare const emitterBrand: unique symbol;
817
+ declare const fontBrand: unique symbol;
818
+ type GeometryId = number & {
819
+ readonly [geometryBrand]: true;
820
+ };
821
+ type MaterialId = number & {
822
+ readonly [materialBrand]: true;
823
+ };
824
+ type TextureId = number & {
825
+ readonly [textureBrand]: true;
826
+ };
827
+ type NodeId = number & {
828
+ readonly [nodeBrand]: true;
829
+ };
830
+ type RenderTargetId = number & {
831
+ readonly [renderTargetBrand]: true;
832
+ };
833
+ type PostChainId = number & {
834
+ readonly [postChainBrand]: true;
835
+ };
836
+ type RenderPassId = number & {
837
+ readonly [renderPassBrand]: true;
838
+ };
839
+ type ModelId = number & {
840
+ readonly [modelBrand]: true;
841
+ };
842
+ type ClipActionId = number & {
843
+ readonly [clipActionBrand]: true;
844
+ };
845
+ type EmitterId = number & {
846
+ readonly [emitterBrand]: true;
847
+ };
848
+ type FontId = number & {
849
+ readonly [fontBrand]: true;
850
+ };
851
+ type TextAlign = "start" | "end" | "left" | "center" | "right";
852
+ type TextDirection = "auto" | "ltr" | "rtl";
853
+ interface FontSource {
854
+ readonly atlas: AssetSource;
855
+ readonly table: AssetSource;
856
+ /** The font file the atlas was baked from: game UI text shapes the letters the atlas lacks through it (complex scripts, marks). */
857
+ readonly face?: AssetSource;
858
+ }
859
+ interface TextStyleDesc {
860
+ readonly size?: number;
861
+ readonly color?: number;
862
+ readonly opacity?: number;
863
+ readonly maxWidth?: number;
864
+ readonly lineHeight?: number;
865
+ readonly letterSpacing?: number;
866
+ readonly align?: TextAlign;
867
+ readonly direction?: TextDirection;
868
+ readonly anchor?: readonly [number, number];
869
+ readonly outlineWidth?: number;
870
+ readonly outlineColor?: number;
871
+ readonly capacity?: number;
872
+ }
873
+ interface PickHit {
874
+ node: NodeId;
875
+ instance: number;
876
+ triangle: number;
877
+ distance: number;
878
+ readonly point: Float32Array;
879
+ readonly barycentric: Float32Array;
880
+ readonly uv: Float32Array;
881
+ }
882
+ declare function createPickHit(): PickHit;
883
+ type VertexData = Float32Array | Uint32Array | Uint16Array | Uint8Array | Int16Array | Int8Array;
884
+ interface VertexAttributeDesc {
885
+ readonly data: VertexData;
886
+ readonly itemSize: 1 | 2 | 3 | 4;
887
+ readonly normalized?: boolean;
888
+ readonly dynamic?: boolean;
889
+ readonly customSlot?: number;
890
+ }
891
+ interface GeometryGroup {
892
+ readonly start: number;
893
+ readonly count: number;
894
+ readonly materialIndex: number;
895
+ }
896
+ interface MorphTargetDesc {
897
+ readonly name: string;
898
+ readonly position: Float32Array;
899
+ readonly normal?: Float32Array;
900
+ }
901
+ interface GeometryDesc {
902
+ readonly attributes: Readonly<Record<string, VertexAttributeDesc>>;
903
+ readonly index?: Uint16Array | Uint32Array;
904
+ readonly groups?: readonly GeometryGroup[];
905
+ readonly morphTargets?: readonly MorphTargetDesc[];
906
+ readonly morphRelative?: boolean;
907
+ }
908
+ type ColorSpace = "srgb" | "linear";
909
+ type TextureWrap = "repeat" | "clamp" | "mirror";
910
+ type TextureFilter = "linear" | "nearest";
911
+ type TexelData = Uint8Array | Uint16Array | Uint32Array | Int32Array | Float32Array;
912
+ type TextureKind = "2d" | "cube" | "equirect" | "2d-array" | "3d";
913
+ type TexelFormat = "rgba8" | "rgba16f" | "rgba32f" | "r8" | "rg8" | "r16f" | "rg16f" | "r32f" | "rg32f" | "r8ui" | "r16ui" | "r32ui" | "rg32ui" | "rgba8ui" | "rgba16ui" | "rgba32ui" | "r32i" | "rgba32i";
914
+ interface TextureRegion {
915
+ readonly x: number;
916
+ readonly y: number;
917
+ readonly z?: number;
918
+ readonly width: number;
919
+ readonly height: number;
920
+ readonly depth?: number;
921
+ }
922
+ type TextureSource = {
923
+ readonly kind: "pixels";
924
+ readonly width: number;
925
+ readonly height: number;
926
+ readonly depth?: number;
927
+ readonly data: TexelData;
928
+ readonly format?: TexelFormat;
929
+ } | {
930
+ readonly kind: "image";
931
+ readonly image: TexImageSource;
932
+ } | {
933
+ readonly kind: "video";
934
+ readonly width: number;
935
+ readonly height: number;
936
+ };
937
+ type VideoFrameSource = TexImageSource;
938
+ interface TextureDesc {
939
+ readonly source: TextureSource;
940
+ readonly kind?: TextureKind;
941
+ readonly colorSpace?: ColorSpace;
942
+ readonly wrap?: TextureWrap;
943
+ readonly filter?: TextureFilter;
944
+ readonly mipmaps?: boolean;
945
+ readonly flipY?: boolean;
946
+ readonly encode?: TextureEncode;
947
+ }
948
+ type TextureEncode = "none" | "blocks" | "astc" | "bc7";
949
+ type Side = "front" | "back" | "double";
950
+ type Blending = "normal" | "additive" | "multiply" | "none" | "custom";
951
+ type CompareFunction = "never" | "less" | "equal" | "lessEqual" | "greater" | "notEqual" | "greaterEqual" | "always";
952
+ type BlendEquation = "add" | "subtract" | "reverseSubtract" | "min" | "max";
953
+ type BlendFactor = "zero" | "one" | "srcColor" | "oneMinusSrcColor" | "srcAlpha" | "oneMinusSrcAlpha" | "dstColor" | "oneMinusDstColor" | "dstAlpha" | "oneMinusDstAlpha" | "srcAlphaSaturate";
954
+ type StencilOperation = "keep" | "zero" | "replace" | "increment" | "decrement" | "invert" | "incrementWrap" | "decrementWrap";
955
+ type Transparency = "sorted" | "oit";
956
+ interface BlendDesc {
957
+ readonly equation?: BlendEquation;
958
+ readonly alphaEquation?: BlendEquation;
959
+ readonly src?: BlendFactor;
960
+ readonly dst?: BlendFactor;
961
+ readonly srcAlpha?: BlendFactor;
962
+ readonly dstAlpha?: BlendFactor;
963
+ }
964
+ interface StencilDesc {
965
+ readonly func?: CompareFunction;
966
+ readonly ref?: number;
967
+ readonly readMask?: number;
968
+ readonly writeMask?: number;
969
+ readonly fail?: StencilOperation;
970
+ readonly depthFail?: StencilOperation;
971
+ readonly pass?: StencilOperation;
972
+ }
973
+ interface PolygonOffsetDesc {
974
+ readonly factor: number;
975
+ readonly units: number;
976
+ }
977
+ type Plane = readonly [number, number, number, number];
978
+ interface TextureTransform {
979
+ readonly offset?: readonly [number, number];
980
+ readonly repeat?: readonly [number, number];
981
+ readonly rotation?: number;
982
+ readonly center?: readonly [number, number];
983
+ readonly channel?: number;
984
+ }
985
+ interface MaterialStateDesc {
986
+ readonly blend?: BlendDesc;
987
+ readonly stencil?: StencilDesc;
988
+ readonly depthFunc?: CompareFunction;
989
+ readonly polygonOffset?: PolygonOffsetDesc;
990
+ readonly clippingPlanes?: readonly Plane[];
991
+ readonly alphaToCoverage?: boolean;
992
+ readonly transparency?: Transparency;
993
+ readonly envMapIntensity?: number;
994
+ }
995
+ interface MaterialCommon extends MaterialStateDesc {
996
+ readonly transparent?: boolean;
997
+ readonly opacity?: number;
998
+ readonly side?: Side;
999
+ readonly depthTest?: boolean;
1000
+ readonly depthWrite?: boolean;
1001
+ readonly blending?: Blending;
1002
+ readonly vertexColors?: boolean;
1003
+ readonly wireframe?: boolean;
1004
+ readonly alphaTest?: number;
1005
+ readonly textureTransforms?: Readonly<Partial<Record<MaterialTextureSlot, TextureTransform>>>;
1006
+ }
1007
+ interface StandardMaterialDesc extends MaterialCommon {
1008
+ readonly kind: "standard";
1009
+ readonly color?: number;
1010
+ readonly metalness?: number;
1011
+ readonly roughness?: number;
1012
+ readonly emissive?: number;
1013
+ readonly emissiveIntensity?: number;
1014
+ readonly map?: TextureId;
1015
+ readonly normalMap?: TextureId;
1016
+ readonly roughnessMap?: TextureId;
1017
+ readonly metalnessMap?: TextureId;
1018
+ readonly emissiveMap?: TextureId;
1019
+ readonly aoMap?: TextureId;
1020
+ readonly flatShading?: boolean;
1021
+ readonly tintable?: boolean;
1022
+ readonly tintMask?: TextureId;
1023
+ }
1024
+ interface KitTint {
1025
+ readonly primary?: number;
1026
+ readonly secondary?: number;
1027
+ readonly tertiary?: number;
1028
+ }
1029
+ interface MaterialTint {
1030
+ readonly tintable: boolean;
1031
+ readonly mask: TextureId | undefined;
1032
+ }
1033
+ declare function materialTint(desc: MaterialDesc): MaterialTint;
1034
+ interface PhysicalMaterialDesc extends Omit<StandardMaterialDesc, "kind"> {
1035
+ readonly kind: "physical";
1036
+ readonly clearcoat?: number;
1037
+ readonly clearcoatRoughness?: number;
1038
+ readonly clearcoatMap?: TextureId;
1039
+ readonly clearcoatRoughnessMap?: TextureId;
1040
+ readonly clearcoatNormalMap?: TextureId;
1041
+ readonly clearcoatNormalScale?: number;
1042
+ readonly transmission?: number;
1043
+ readonly transmissionMap?: TextureId;
1044
+ readonly ior?: number;
1045
+ readonly thickness?: number;
1046
+ readonly sheen?: number;
1047
+ readonly sheenColor?: number;
1048
+ readonly sheenRoughness?: number;
1049
+ readonly sheenColorMap?: TextureId;
1050
+ readonly sheenRoughnessMap?: TextureId;
1051
+ readonly specularColor?: number;
1052
+ readonly specularIntensity?: number;
1053
+ readonly specularIntensityMap?: TextureId;
1054
+ readonly specularColorMap?: TextureId;
1055
+ readonly iridescence?: number;
1056
+ readonly iridescenceIOR?: number;
1057
+ readonly iridescenceThicknessRange?: readonly [number, number];
1058
+ readonly iridescenceMap?: TextureId;
1059
+ readonly iridescenceThicknessMap?: TextureId;
1060
+ readonly anisotropy?: number;
1061
+ readonly anisotropyRotation?: number;
1062
+ readonly anisotropyMap?: TextureId;
1063
+ readonly attenuationColor?: number;
1064
+ readonly attenuationDistance?: number;
1065
+ readonly dispersion?: number;
1066
+ }
1067
+ interface ToonMaterialDesc extends MaterialCommon {
1068
+ readonly kind: "toon";
1069
+ readonly color?: number;
1070
+ readonly map?: TextureId;
1071
+ readonly gradientMap?: TextureId;
1072
+ readonly normalMap?: TextureId;
1073
+ readonly emissive?: number;
1074
+ readonly emissiveIntensity?: number;
1075
+ readonly emissiveMap?: TextureId;
1076
+ readonly aoMap?: TextureId;
1077
+ }
1078
+ interface MatcapMaterialDesc extends MaterialCommon {
1079
+ readonly kind: "matcap";
1080
+ readonly color?: number;
1081
+ readonly map?: TextureId;
1082
+ readonly matcap?: TextureId;
1083
+ readonly normalMap?: TextureId;
1084
+ readonly flatShading?: boolean;
1085
+ }
1086
+ interface UnlitMaterialDesc extends MaterialCommon {
1087
+ readonly kind: "unlit";
1088
+ readonly color?: number;
1089
+ readonly map?: TextureId;
1090
+ }
1091
+ interface SpriteMaterialDesc extends MaterialCommon {
1092
+ readonly kind: "sprite";
1093
+ readonly color?: number;
1094
+ readonly map?: TextureId;
1095
+ readonly sizeAttenuation?: boolean;
1096
+ readonly rotation?: number;
1097
+ }
1098
+ interface PointsMaterialDesc extends MaterialCommon {
1099
+ readonly kind: "points";
1100
+ readonly color?: number;
1101
+ readonly size?: number;
1102
+ readonly map?: TextureId;
1103
+ readonly sizeAttenuation?: boolean;
1104
+ }
1105
+ interface LinesMaterialDesc extends MaterialCommon {
1106
+ readonly kind: "lines";
1107
+ readonly color?: number;
1108
+ readonly width?: number;
1109
+ readonly worldUnits?: boolean;
1110
+ readonly dashSize?: number;
1111
+ readonly gapSize?: number;
1112
+ readonly dashScale?: number;
1113
+ }
1114
+ interface WgslSource {
1115
+ readonly vertex?: string;
1116
+ readonly fragment: string;
1117
+ }
1118
+ interface GlslSource {
1119
+ readonly vertex: string;
1120
+ readonly fragment: string;
1121
+ }
1122
+ interface ShaderSource {
1123
+ readonly wgsl: WgslSource;
1124
+ readonly glsl?: GlslSource;
1125
+ }
1126
+ type UniformType = "f32" | "i32" | "vec2" | "vec3" | "vec4" | "mat4" | "texture";
1127
+ interface UniformDesc {
1128
+ readonly type: UniformType;
1129
+ readonly value?: number | Float32Array | TextureId;
1130
+ }
1131
+ interface ShaderMaterialDesc extends MaterialCommon {
1132
+ readonly kind: "shader";
1133
+ readonly shader: ShaderSource;
1134
+ readonly uniforms?: Readonly<Record<string, UniformDesc>>;
1135
+ readonly lights?: boolean;
1136
+ }
1137
+ type MaterialDesc = StandardMaterialDesc | PhysicalMaterialDesc | ToonMaterialDesc | MatcapMaterialDesc | UnlitMaterialDesc | SpriteMaterialDesc | PointsMaterialDesc | LinesMaterialDesc | ShaderMaterialDesc | SkinMaterialDesc | EyeMaterialDesc | HairMaterialDesc;
1138
+ type MaterialTextureSlot = "map" | "normalMap" | "roughnessMap" | "metalnessMap" | "emissiveMap" | "aoMap" | "clearcoatMap" | "clearcoatRoughnessMap" | "clearcoatNormalMap" | "sheenColorMap" | "sheenRoughnessMap" | "specularIntensityMap" | "specularColorMap" | "transmissionMap" | "gradientMap" | "matcap";
1139
+ interface SkeletonDesc {
1140
+ readonly parents: Int16Array;
1141
+ readonly bindPose: Float32Array;
1142
+ readonly inverseBindMatrices?: Float32Array;
1143
+ }
1144
+ interface ShadowDesc {
1145
+ readonly castShadow?: boolean;
1146
+ readonly receiveShadow?: boolean;
1147
+ readonly giExclude?: boolean;
1148
+ }
1149
+ type GlobalIlluminationMode = "off" | "field" | "full";
1150
+ interface GlobalIlluminationDesc {
1151
+ readonly mode?: GlobalIlluminationMode;
1152
+ readonly intensity?: number;
1153
+ readonly spacing?: number;
1154
+ readonly sunAngle?: number;
1155
+ }
1156
+ interface ShadowParamsDesc {
1157
+ readonly cascades?: 1 | 2 | 3;
1158
+ readonly split?: number;
1159
+ readonly maxFar?: number;
1160
+ readonly fade?: number;
1161
+ readonly bias?: number;
1162
+ readonly normalBias?: number;
1163
+ readonly radius?: number;
1164
+ readonly blurSamples?: number;
1165
+ readonly type?: ShadowType;
1166
+ }
1167
+ type ShadowType = "pcf" | "pcss";
1168
+ interface LodRange {
1169
+ readonly near?: number;
1170
+ readonly far?: number;
1171
+ readonly hysteresis?: number;
1172
+ }
1173
+ interface NodeCommon {
1174
+ readonly renderOrder?: number;
1175
+ readonly lod?: LodRange;
1176
+ }
1177
+ type LightKind = "directional" | "point" | "spot" | "ambient" | "hemisphere" | "rectArea" | "probe" | "reflectionProbe";
1178
+ type Vec3Tuple = readonly [number, number, number];
1179
+ declare const SH_COEFFICIENT_FLOATS = 27;
1180
+ type Interpolation = "linear" | "step" | "cubic";
1181
+ type EmitterShape = {
1182
+ readonly kind: "point";
1183
+ } | {
1184
+ readonly kind: "sphere";
1185
+ readonly radius: number;
1186
+ } | {
1187
+ readonly kind: "cone";
1188
+ readonly angle: number;
1189
+ readonly radius?: number;
1190
+ } | {
1191
+ readonly kind: "box";
1192
+ readonly size: readonly [number, number, number];
1193
+ } | {
1194
+ readonly kind: "disc";
1195
+ readonly radius: number;
1196
+ };
1197
+ type EmitterCollision = {
1198
+ readonly kind: "none";
1199
+ } | {
1200
+ readonly kind: "plane";
1201
+ readonly plane: Plane;
1202
+ readonly bounce?: number;
1203
+ } | {
1204
+ readonly kind: "depth";
1205
+ readonly bounce?: number;
1206
+ };
1207
+ interface CurvePoint {
1208
+ readonly t: number;
1209
+ readonly value: number | readonly [number, number, number, number];
1210
+ }
1211
+ interface EmitterDesc {
1212
+ readonly capacity: number;
1213
+ readonly rate?: number;
1214
+ readonly burst?: number;
1215
+ readonly lifetime?: readonly [number, number];
1216
+ readonly speed?: readonly [number, number];
1217
+ readonly size?: readonly [number, number];
1218
+ readonly color?: readonly [number, number];
1219
+ readonly alpha?: readonly [number, number];
1220
+ readonly gravity?: readonly [number, number, number];
1221
+ readonly drag?: number;
1222
+ readonly noise?: {
1223
+ readonly strength: number;
1224
+ readonly scale: number;
1225
+ };
1226
+ readonly shape?: EmitterShape;
1227
+ readonly collision?: EmitterCollision;
1228
+ readonly material?: MaterialId;
1229
+ readonly spread?: number;
1230
+ readonly spin?: number;
1231
+ readonly seed?: number;
1232
+ readonly soft?: boolean;
1233
+ readonly sorted?: boolean;
1234
+ readonly localSpace?: boolean;
1235
+ readonly deterministic?: boolean;
1236
+ readonly additive?: boolean;
1237
+ readonly stretch?: boolean;
1238
+ readonly oit?: boolean;
1239
+ readonly velocityAligned?: boolean;
1240
+ readonly sizeCurve?: readonly CurvePoint[];
1241
+ readonly colorCurve?: readonly CurvePoint[];
1242
+ }
1243
+ type NodeDesc = NodeCommon & NodeKindDesc;
1244
+ type NodeKindDesc = ({
1245
+ readonly kind: "mesh";
1246
+ readonly geometry: GeometryId;
1247
+ readonly material: MaterialId | readonly MaterialId[];
1248
+ } & ShadowDesc) | ({
1249
+ readonly kind: "instanced";
1250
+ readonly geometry: GeometryId;
1251
+ readonly material: MaterialId;
1252
+ readonly capacity: number;
1253
+ readonly colors?: boolean;
1254
+ readonly batchSlots?: number;
1255
+ } & ShadowDesc) | ({
1256
+ readonly kind: "skinned";
1257
+ readonly geometry: GeometryId;
1258
+ readonly material: MaterialId;
1259
+ readonly skeleton: SkeletonDesc;
1260
+ } & ShadowDesc) | {
1261
+ readonly kind: "points";
1262
+ readonly geometry: GeometryId;
1263
+ readonly material: MaterialId;
1264
+ } | {
1265
+ readonly kind: "lines";
1266
+ readonly geometry: GeometryId;
1267
+ readonly material: MaterialId;
1268
+ readonly segments?: boolean;
1269
+ } | {
1270
+ readonly kind: "sprite";
1271
+ readonly material: MaterialId;
1272
+ readonly center?: readonly [number, number];
1273
+ } | {
1274
+ readonly kind: "camera";
1275
+ readonly projection: "perspective";
1276
+ readonly fov?: number;
1277
+ readonly near?: number;
1278
+ readonly far?: number;
1279
+ } | {
1280
+ readonly kind: "camera";
1281
+ readonly projection: "orthographic";
1282
+ readonly height: number;
1283
+ readonly near?: number;
1284
+ readonly far?: number;
1285
+ } | {
1286
+ readonly kind: "camera";
1287
+ readonly projection: "custom";
1288
+ readonly matrix: Float32Array;
1289
+ readonly near: number;
1290
+ readonly far: number;
1291
+ } | {
1292
+ readonly kind: "decal";
1293
+ readonly material: MaterialId;
1294
+ readonly angleFade?: number;
1295
+ readonly fade?: number;
1296
+ } | {
1297
+ readonly kind: "light";
1298
+ readonly light: LightKind;
1299
+ readonly color?: number;
1300
+ readonly intensity?: number;
1301
+ readonly distance?: number;
1302
+ readonly decay?: number;
1303
+ readonly angle?: number;
1304
+ readonly penumbra?: number;
1305
+ readonly groundColor?: number;
1306
+ readonly castShadow?: boolean;
1307
+ readonly shadowMapSize?: number;
1308
+ readonly shadow?: ShadowParamsDesc;
1309
+ readonly width?: number;
1310
+ readonly height?: number;
1311
+ readonly sh?: Float32Array;
1312
+ readonly fromEnvironment?: boolean;
1313
+ readonly texture?: TextureId;
1314
+ readonly boxMin?: Vec3Tuple;
1315
+ readonly boxMax?: Vec3Tuple;
1316
+ } | {
1317
+ readonly kind: "particles";
1318
+ readonly emitter: EmitterId;
1319
+ } | {
1320
+ readonly kind: "group";
1321
+ } | {
1322
+ readonly kind: "shape2d";
1323
+ readonly shape: "rect" | "circle";
1324
+ readonly width?: number;
1325
+ readonly height?: number;
1326
+ readonly radius?: number;
1327
+ readonly color?: number;
1328
+ readonly alpha?: number;
1329
+ } | ({
1330
+ readonly kind: "text2d";
1331
+ readonly text: string;
1332
+ readonly font?: FontId;
1333
+ readonly fontFamily?: string;
1334
+ } & TextStyleDesc) | ({
1335
+ readonly kind: "text3d";
1336
+ readonly font: FontId;
1337
+ readonly text?: string;
1338
+ readonly billboard?: boolean;
1339
+ } & TextStyleDesc);
1340
+ type RenderTargetFormat = "rgba8" | "rgba16f" | "rgba32f";
1341
+ interface RenderTargetDesc {
1342
+ readonly width: number;
1343
+ readonly height: number;
1344
+ readonly format?: RenderTargetFormat;
1345
+ readonly depth?: boolean;
1346
+ readonly samples?: number;
1347
+ readonly kind?: "2d" | "cube" | "2d-array";
1348
+ readonly layers?: number;
1349
+ readonly sampleDepth?: boolean;
1350
+ readonly colors?: number;
1351
+ }
1352
+ type PostEffectDesc = {
1353
+ readonly kind: "bloom";
1354
+ readonly strength?: number;
1355
+ readonly radius?: number;
1356
+ readonly threshold?: number;
1357
+ readonly physical?: boolean;
1358
+ } | {
1359
+ readonly kind: "fxaa";
1360
+ } | {
1361
+ readonly kind: "ao";
1362
+ readonly radius?: number;
1363
+ readonly intensity?: number;
1364
+ readonly thickness?: number;
1365
+ readonly quality?: number;
1366
+ } | {
1367
+ readonly kind: "smaa";
1368
+ readonly threshold?: number;
1369
+ readonly temporal?: boolean;
1370
+ } | {
1371
+ readonly kind: "taa";
1372
+ readonly feedback?: number;
1373
+ readonly sharpness?: number;
1374
+ } | {
1375
+ readonly kind: "outline";
1376
+ readonly thickness?: number;
1377
+ readonly depthThreshold?: number;
1378
+ readonly normalThreshold?: number;
1379
+ readonly color?: number;
1380
+ } | {
1381
+ readonly kind: "ssr";
1382
+ readonly intensity?: number;
1383
+ readonly maxDistance?: number;
1384
+ readonly thickness?: number;
1385
+ readonly fade?: number;
1386
+ } | {
1387
+ readonly kind: "dof";
1388
+ readonly focus?: number;
1389
+ readonly aperture?: number;
1390
+ readonly maxBlur?: number;
1391
+ } | {
1392
+ readonly kind: "motion_blur";
1393
+ readonly intensity?: number;
1394
+ readonly samples?: number;
1395
+ } | {
1396
+ readonly kind: "lut";
1397
+ readonly texture: TextureId;
1398
+ readonly intensity?: number;
1399
+ readonly size?: number;
1400
+ } | {
1401
+ readonly kind: "grain";
1402
+ readonly intensity?: number;
1403
+ } | {
1404
+ readonly kind: "god_rays";
1405
+ readonly intensity?: number;
1406
+ readonly decay?: number;
1407
+ readonly density?: number;
1408
+ readonly weight?: number;
1409
+ } | {
1410
+ readonly kind: "lens_dirt";
1411
+ readonly texture: TextureId;
1412
+ readonly intensity?: number;
1413
+ } | {
1414
+ readonly kind: "sharpen";
1415
+ readonly sharpness?: number;
1416
+ } | {
1417
+ readonly kind: "chromatic";
1418
+ readonly amount?: number;
1419
+ } | {
1420
+ readonly kind: "mask";
1421
+ readonly texture: TextureId;
1422
+ readonly outline?: boolean;
1423
+ readonly bloom?: boolean;
1424
+ readonly hidden?: number;
1425
+ } | {
1426
+ readonly kind: "weather";
1427
+ readonly rain?: number;
1428
+ readonly snow?: number;
1429
+ readonly wetness?: number;
1430
+ readonly night?: number;
1431
+ } | {
1432
+ readonly kind: "vignette";
1433
+ readonly offset?: number;
1434
+ readonly darkness?: number;
1435
+ } | {
1436
+ readonly kind: "color_grade";
1437
+ readonly exposure?: number;
1438
+ readonly contrast?: number;
1439
+ readonly saturation?: number;
1440
+ } | {
1441
+ readonly kind: "shader";
1442
+ readonly shader: ShaderSource;
1443
+ readonly uniforms?: Readonly<Record<string, UniformDesc>>;
1444
+ readonly textures?: readonly TextureId[];
1445
+ } | {
1446
+ readonly kind: "lens_flare";
1447
+ readonly intensity?: number;
1448
+ readonly ghosts?: number;
1449
+ readonly halo?: number;
1450
+ readonly dispersal?: number;
1451
+ };
1452
+ interface PostChainDesc {
1453
+ readonly effects: readonly PostEffectDesc[];
1454
+ }
1455
+ interface RenderPassDesc {
1456
+ readonly camera: NodeId;
1457
+ readonly target: RenderTargetId | null;
1458
+ readonly layers?: number;
1459
+ readonly clearColor?: number;
1460
+ readonly clearAlpha?: number;
1461
+ readonly order?: number;
1462
+ readonly viewport?: readonly [number, number, number, number];
1463
+ readonly slice?: number;
1464
+ readonly cubeFace?: boolean;
1465
+ readonly reflect?: readonly [number, number, number, number];
1466
+ readonly once?: boolean;
1467
+ }
1468
+ type ToneMapping = "none" | "linear" | "reinhard" | "aces" | "agx" | "neutral" | "cineon" | "custom";
1469
+ type FogDesc = {
1470
+ readonly mode?: "linear";
1471
+ readonly color: number;
1472
+ readonly near: number;
1473
+ readonly far: number;
1474
+ } | {
1475
+ readonly mode: "exp2";
1476
+ readonly color: number;
1477
+ readonly density: number;
1478
+ } | {
1479
+ readonly mode: "height";
1480
+ readonly color: number;
1481
+ readonly density: number;
1482
+ readonly height: number;
1483
+ readonly falloff: number;
1484
+ };
1485
+ interface WeatherState {
1486
+ readonly cloudCover?: number;
1487
+ readonly haze?: number;
1488
+ readonly precipitation?: number;
1489
+ readonly snow?: boolean;
1490
+ readonly wetness?: number;
1491
+ readonly wind?: readonly [number, number];
1492
+ }
1493
+ interface VolumetricFogDesc {
1494
+ readonly density?: number;
1495
+ readonly height?: number;
1496
+ readonly falloff?: number;
1497
+ readonly anisotropy?: number;
1498
+ readonly albedo?: number;
1499
+ readonly noise?: number;
1500
+ readonly range?: number;
1501
+ readonly ambient?: number;
1502
+ }
1503
+ interface VolumetricCloudsDesc {
1504
+ readonly coverage?: number;
1505
+ readonly density?: number;
1506
+ readonly altitude?: number;
1507
+ readonly thickness?: number;
1508
+ readonly type?: number;
1509
+ readonly shadow?: number;
1510
+ readonly detail?: number;
1511
+ }
1512
+ interface AtmosphereDesc {
1513
+ readonly rayleigh?: number;
1514
+ readonly mie?: number;
1515
+ readonly mieAnisotropy?: number;
1516
+ readonly ozone?: number;
1517
+ readonly groundAlbedo?: number;
1518
+ readonly sunDiscDegrees?: number;
1519
+ }
1520
+ interface VolumetricsDesc {
1521
+ readonly enabled?: boolean;
1522
+ readonly fog?: VolumetricFogDesc;
1523
+ readonly clouds?: VolumetricCloudsDesc;
1524
+ readonly atmosphere?: AtmosphereDesc;
1525
+ }
1526
+ interface CloudDesc {
1527
+ readonly coverage?: number;
1528
+ readonly density?: number;
1529
+ readonly scale?: number;
1530
+ readonly speed?: number;
1531
+ readonly elevation?: number;
1532
+ }
1533
+ interface SkyDesc {
1534
+ readonly turbidity?: number;
1535
+ readonly rayleigh?: number;
1536
+ readonly mie?: number;
1537
+ readonly mieDirectionalG?: number;
1538
+ readonly clouds?: CloudDesc | false;
1539
+ }
1540
+ interface EnvironmentDesc {
1541
+ readonly sky?: SkyDesc | false;
1542
+ readonly background?: {
1543
+ readonly color: number;
1544
+ } | {
1545
+ readonly texture: TextureId;
1546
+ } | {
1547
+ readonly environment: true;
1548
+ } | {
1549
+ readonly sky: true;
1550
+ };
1551
+ readonly backgroundBlurriness?: number;
1552
+ readonly backgroundIntensity?: number;
1553
+ readonly environment?: TextureId;
1554
+ readonly environmentIntensity?: number;
1555
+ readonly environmentRotation?: number;
1556
+ readonly fog?: FogDesc;
1557
+ readonly toneMapping?: ToneMapping;
1558
+ readonly toneCurve?: TextureId;
1559
+ readonly exposure?: number;
1560
+ readonly shadows?: boolean;
1561
+ readonly volumetrics?: VolumetricsDesc;
1562
+ readonly gi?: GlobalIlluminationDesc;
1563
+ }
1564
+ type AssetSource = {
1565
+ readonly url: string;
1566
+ } | {
1567
+ readonly bytes: ArrayBuffer;
1568
+ } | {
1569
+ readonly text: string;
1570
+ };
1571
+ interface ModelInfo {
1572
+ readonly id: ModelId;
1573
+ readonly nodeNames: readonly string[];
1574
+ readonly clipNames: readonly string[];
1575
+ readonly materialNames: readonly string[];
1576
+ readonly materials: readonly MaterialId[];
1577
+ }
1578
+ interface TextureUpgrade {
1579
+ readonly texture: TextureId;
1580
+ readonly inPlace: boolean;
1581
+ }
1582
+ interface ModelUpgrade {
1583
+ readonly model: ModelInfo;
1584
+ readonly inPlace: boolean;
1585
+ }
1586
+ interface GraphicsCapabilities {
1587
+ readonly backend: string;
1588
+ readonly dimensions: "2d" | "3d";
1589
+ readonly rendering: boolean;
1590
+ readonly webgpu: boolean;
1591
+ readonly compute: boolean;
1592
+ readonly shaderLanguages: readonly ("wgsl" | "glsl")[];
1593
+ readonly instancing: boolean;
1594
+ readonly skinning: boolean;
1595
+ readonly morphTargets: boolean;
1596
+ readonly renderTargets: boolean;
1597
+ readonly postProcessing: boolean;
1598
+ readonly models: boolean;
1599
+ readonly particles?: boolean;
1600
+ readonly orderIndependentTransparency?: boolean;
1601
+ readonly imageBasedLighting?: boolean;
1602
+ readonly cascadedShadows?: boolean;
1603
+ readonly renderState?: boolean;
1604
+ readonly rawRender?: boolean;
1605
+ readonly decals?: boolean;
1606
+ readonly lod?: boolean;
1607
+ readonly fatLines?: boolean;
1608
+ readonly text?: boolean;
1609
+ readonly picking?: boolean;
1610
+ readonly pointShadows?: boolean;
1611
+ readonly sky?: boolean;
1612
+ readonly customProjection?: boolean;
1613
+ readonly gpuTiming?: boolean;
1614
+ readonly globalIllumination?: boolean;
1615
+ readonly rayTracing?: boolean;
1616
+ readonly vectorSurfaces?: number;
1617
+ }
1618
+ interface GpuStats {
1619
+ gpuLastNs: number;
1620
+ gpuP50Ns: number;
1621
+ gpuP95Ns: number;
1622
+ gpuBytes: number;
1623
+ thermalTier: number;
1624
+ particlesAlive: number;
1625
+ rawDispatches: number;
1626
+ rawGpuNs: number;
1627
+ rawDisabled: number;
1628
+ transparentSorted: number;
1629
+ textGlyphs: number;
1630
+ drawCalls: number;
1631
+ triangles: number;
1632
+ readonly passNs: Float64Array;
1633
+ }
1634
+ declare const GPU_PASS_NAMES: readonly ["cull", "particles", "shadow", "main", "overlay", "post", "targets", "gi", "rt", "volumetrics"];
1635
+ declare function createGpuStats(): GpuStats;
1636
+ interface BatchBuffers {
1637
+ readonly slots: Uint32Array;
1638
+ readonly ranges: Uint32Array;
1639
+ }
1640
+ interface ViewOffset {
1641
+ readonly fullWidth: number;
1642
+ readonly fullHeight: number;
1643
+ readonly x: number;
1644
+ readonly y: number;
1645
+ readonly width: number;
1646
+ readonly height: number;
1647
+ }
1648
+ interface GraphicsStats {
1649
+ nodes: number;
1650
+ geometries: number;
1651
+ materials: number;
1652
+ textures: number;
1653
+ renderTargets: number;
1654
+ postChains: number;
1655
+ renderPasses: number;
1656
+ frames: number;
1657
+ }
1658
+ interface GameSurface {
1659
+ readonly canvas: HTMLCanvasElement | OffscreenCanvas;
1660
+ readonly width: number;
1661
+ readonly height: number;
1662
+ readonly pixelRatio: number;
1663
+ }
1664
+
1665
+ declare const KERNEL_ISA_VERSION = 4;
1666
+ declare const KERNEL_ISA_BASE = 1;
1667
+ declare const KERNEL_ISA_CALLS = 2;
1668
+ declare const KERNEL_ISA_WRITES = 3;
1669
+ declare const KERNEL_FEATURE = "kernel_isa_1";
1670
+ declare const KERNEL_CALLS_FEATURE = "kernel_isa_2";
1671
+ declare const KERNEL_WRITES_FEATURE = "kernel_isa_3";
1672
+ declare const KERNEL_ISA_EXTENDED = 4;
1673
+ declare const KERNEL_EXTENDED_FEATURE = "kernel_isa_4";
1674
+ declare const PROGRAM_MAGIC = 827345731;
1675
+ declare const LIBRARY_MAGIC = 827083587;
1676
+ declare const PROGRAM_HEADER_WORDS = 16;
1677
+ declare const LIBRARY_HEADER_WORDS = 4;
1678
+ declare const INSTRUCTION_WORDS = 4;
1679
+ declare const GROUP_WORDS = 4;
1680
+ declare const NONE = 4294967295;
1681
+ declare const UNIFORM = 2147483648;
1682
+ declare const DST_BITS = 8;
1683
+ declare const MAX_REGISTERS: number;
1684
+ declare const MAX_SLOTS = 256;
1685
+ declare const MAX_UNIFORMS: number;
1686
+ declare const MAX_GROUPS = 256;
1687
+ declare const MAX_TRIPS: number;
1688
+ declare const KERNEL_LIBRARY_PATH = "kernels.ckl";
1689
+ declare const H_MAGIC = 0;
1690
+ declare const H_VERSION = 1;
1691
+ declare const H_FLAGS = 2;
1692
+ declare const H_REGISTERS = 3;
1693
+ declare const H_SLOTS = 4;
1694
+ declare const H_ARGS = 5;
1695
+ declare const H_CONSTANTS = 6;
1696
+ declare const H_LOOPS = 7;
1697
+ declare const H_INSTRUCTIONS = 8;
1698
+ declare const H_GROUPS = 9;
1699
+ declare const H_STATE = 10;
1700
+ declare const H_POSITION_X = 11;
1701
+ declare const H_POSITION_Y = 12;
1702
+ declare const H_POSITION_Z = 13;
1703
+ declare const H_EVENTS = 14;
1704
+ declare const CHANNEL_WORDS = 4;
1705
+ declare const MAX_CHANNELS = 64;
1706
+ declare const MAX_EVENT_WORDS = 8;
1707
+ declare const EVENT_HEADER_WORDS = 2;
1708
+ declare const EVENT_STRIDE: number;
1709
+ declare const FLAG_NEIGHBOURS = 1;
1710
+ declare const FLAG_GROUPS = 2;
1711
+ declare const KIND_F32 = 0;
1712
+ declare const KIND_I32 = 1;
1713
+ declare const KIND_U32 = 2;
1714
+ declare const KIND_BOOL = 3;
1715
+ declare const ACCESS_READ: number;
1716
+ declare const ACCESS_WRITE: number;
1717
+ declare const ACCESS_NEIGHBOUR: number;
1718
+ declare const ACCESS_SCRATCH: number;
1719
+ declare const ACCESS_HIGH: number;
1720
+ declare const ACCESS_SPAWN: number;
1721
+ declare const SERVICE_RAYCAST = 1;
1722
+ declare const SERVICE_LINE_OF_SIGHT = 2;
1723
+ declare const SERVICE_GROUND_HEIGHT = 3;
1724
+ declare const SERVICE_PATH = 4;
1725
+ declare const SERVICE_FLOW = 5;
1726
+ declare const SERVICE_FORCE = 6;
1727
+ declare const SERVICE_IMPULSE = 7;
1728
+ declare const SERVICE_VELOCITY = 8;
1729
+ declare const SERVICE_OVERLAP = 9;
1730
+ declare const SERVICE_SWEEP = 10;
1731
+ declare const SERVICE_CLIP_WEIGHT = 11;
1732
+ declare const SERVICE_PLAY_CLIP = 12;
1733
+ declare const SERVICE_IK_TARGET = 13;
1734
+ declare const SERVICE_INSTANCE = 14;
1735
+ declare const SERVICE_INSTANCE_COLOUR = 15;
1736
+ declare const SERVICE_ANCHOR = 16;
1737
+ declare const SERVICE_SOUND = 17;
1738
+ declare const SERVICE_PICK = 18;
1739
+ declare const SERVICE_VOXEL_GET = 19;
1740
+ declare const SERVICE_VOXEL_SET = 20;
1741
+ declare const SERVICE_CHEMISTRY = 21;
1742
+ declare const SERVICE_SPAWN = 22;
1743
+ declare const SERVICE_KILL = 23;
1744
+ declare const SERVICE_BITS = 8;
1745
+ declare const SERVICE_MASK: number;
1746
+ declare const MAX_SPAWN_FIELDS = 64;
1747
+ declare function serviceOf(dst: number): number;
1748
+ declare function operandCount(dst: number): number;
1749
+ declare function serviceVersion(service: number): number;
1750
+ declare function deferredService(service: number): boolean;
1751
+ interface ServiceSignature {
1752
+ readonly args: readonly number[];
1753
+ readonly results: readonly number[];
1754
+ }
1755
+ declare const SERVICE_SIGNATURES: Readonly<Record<number, ServiceSignature>>;
1756
+ declare const ATTACH_UI = 4;
1757
+ declare const ATTACH_AUDIO = 5;
1758
+ declare const ATTACH_VOXELS = 6;
1759
+ declare const ATTACH_CHEMISTRY_GRID = 7;
1760
+ declare const ATTACH_SPAWN_TABLE = 9;
1761
+ declare const SPAWN_STATS_WORDS = 3;
1762
+ declare const GROUP_DEFAULT = 1;
1763
+ declare const LOOP_COUNT_F32 = 1;
1764
+ declare const Op: {
1765
+ readonly NOP: 0;
1766
+ readonly MOV: 1;
1767
+ readonly LOAD: 2;
1768
+ readonly STORE: 3;
1769
+ readonly ROW: 4;
1770
+ readonly SEL: 5;
1771
+ readonly JNONE: 6;
1772
+ readonly LOOP_INIT: 8;
1773
+ readonly LOOP_NEXT: 9;
1774
+ readonly NEIGHBOURS: 11;
1775
+ readonly NLOAD: 12;
1776
+ readonly OUTER: 13;
1777
+ readonly NROW: 14;
1778
+ readonly ACC_FADD: 15;
1779
+ readonly ACC_FMIN: 16;
1780
+ readonly ACC_FMAX: 17;
1781
+ readonly ACC_IADD: 18;
1782
+ readonly EXT: 19;
1783
+ readonly FADD: 20;
1784
+ readonly FSUB: 21;
1785
+ readonly FMUL: 22;
1786
+ readonly FDIV: 23;
1787
+ readonly FMIN: 24;
1788
+ readonly FMAX: 25;
1789
+ readonly FMOD: 26;
1790
+ readonly FPOW: 27;
1791
+ readonly FATAN2: 28;
1792
+ readonly FMULADD: 29;
1793
+ readonly FMULSUB: 30;
1794
+ readonly FSUBMUL: 31;
1795
+ readonly FADDMUL: 32;
1796
+ readonly FCLAMP: 33;
1797
+ readonly FLERP: 34;
1798
+ readonly FLOG2: 39;
1799
+ readonly FNEG: 40;
1800
+ readonly FABS: 41;
1801
+ readonly FSQRT: 42;
1802
+ readonly FFLOOR: 43;
1803
+ readonly FCEIL: 44;
1804
+ readonly FROUND: 45;
1805
+ readonly FTRUNC: 46;
1806
+ readonly FSIGN: 47;
1807
+ readonly FSIN: 48;
1808
+ readonly FCOS: 49;
1809
+ readonly FTAN: 50;
1810
+ readonly FASIN: 51;
1811
+ readonly FACOS: 52;
1812
+ readonly FATAN: 53;
1813
+ readonly FEXP: 54;
1814
+ readonly FLOG: 55;
1815
+ readonly FLEN2: 56;
1816
+ readonly FLEN3: 57;
1817
+ readonly FDOT2: 58;
1818
+ readonly FDOT3: 59;
1819
+ readonly FLT: 60;
1820
+ readonly FLE: 61;
1821
+ readonly FEQ: 62;
1822
+ readonly FNE: 63;
1823
+ readonly IADD: 70;
1824
+ readonly ISUB: 71;
1825
+ readonly IMUL: 72;
1826
+ readonly IREM: 73;
1827
+ readonly UREM: 74;
1828
+ readonly IAND: 75;
1829
+ readonly IOR: 76;
1830
+ readonly IXOR: 77;
1831
+ readonly ISHL: 78;
1832
+ readonly ISHR: 79;
1833
+ readonly IUSHR: 80;
1834
+ readonly IMIN: 81;
1835
+ readonly IMAX: 82;
1836
+ readonly UMIN: 83;
1837
+ readonly UMAX: 84;
1838
+ readonly INEG: 85;
1839
+ readonly IABS: 86;
1840
+ readonly INOT: 87;
1841
+ readonly ILT: 90;
1842
+ readonly ILE: 91;
1843
+ readonly IEQ: 92;
1844
+ readonly INE: 93;
1845
+ readonly ULT: 94;
1846
+ readonly ULE: 95;
1847
+ readonly ITOF: 100;
1848
+ readonly UTOF: 101;
1849
+ readonly FTOI: 102;
1850
+ readonly BTOF: 103;
1851
+ readonly BTOI: 104;
1852
+ readonly FTOB: 105;
1853
+ readonly ITOB: 106;
1854
+ readonly MAND: 110;
1855
+ readonly MOR: 111;
1856
+ readonly MANDN: 112;
1857
+ readonly MNOT: 113;
1858
+ readonly NOISE2: 120;
1859
+ readonly NOISE3: 121;
1860
+ readonly HASH: 122;
1861
+ readonly RAND: 123;
1862
+ readonly EMIT: 124;
1863
+ readonly CALL: 125;
1864
+ readonly UADDC: 126;
1865
+ readonly USUBB: 127;
1866
+ readonly UMULHI: 128;
1867
+ };
1868
+ type OpCode = (typeof Op)[keyof typeof Op];
1869
+ declare const STATUS_FAILURE = 0;
1870
+ declare const STATUS_SUCCESS = 1;
1871
+ declare const STATUS_RUNNING = 2;
1872
+ declare const KERNEL_EXPORT_NAMES: readonly ["engine_kernel_isa", "engine_kernel_load", "engine_kernel_unload", "engine_kernel_bind", "engine_kernel_unbind", "engine_kernel_run", "engine_kernel_events", "engine_kernel_clear_events"];
1873
+ declare const KERNEL_CALL_EXPORT_NAMES: readonly ["engine_kernel_attach"];
1874
+ declare const KERNEL_WRITE_EXPORT_NAMES: readonly ["engine_kernel_attach_handle", "engine_kernel_spawns"];
1875
+ declare const KERNEL_STAGE_EXPORT_NAMES: readonly ["engine_kernel_stage_begin", "engine_kernel_stage_uniforms", "engine_kernel_stage_column", "engine_kernel_stage_storage", "engine_kernel_stage_records", "engine_kernel_stage_call", "engine_kernel_stage_finish", "engine_kernel_stage_end"];
1876
+ declare const KERNEL_DATA_EXPORT_NAMES: readonly ["engine_kernel_bind_table", "engine_kernel_bind_pool", "engine_kernel_data"];
1877
+ declare const DATA_REPORT_HEADER = 70;
1878
+ declare const RING_HEADER_WORDS = 2;
1879
+ declare const RING_COUNT = 0;
1880
+ declare const RING_DROPPED = 1;
1881
+ declare const DEFAULT_EVENT_CAPACITY = 4096;
1882
+ declare const CROSS_OP: {
1883
+ readonly REDUCE: 160;
1884
+ readonly ARG: 161;
1885
+ readonly HIST: 162;
1886
+ readonly SCATTER: 163;
1887
+ readonly SCAN: 164;
1888
+ readonly COMPACT: 165;
1889
+ };
1890
+ declare const ACCESS_ARRAY: number;
1891
+ declare const CROSS_BLOCK = 256;
1892
+ declare const REDUCE_FSUM = 0;
1893
+ declare const REDUCE_ISUM = 1;
1894
+ declare const REDUCE_FMIN = 2;
1895
+ declare const REDUCE_FMAX = 3;
1896
+ declare const REDUCE_IMIN = 4;
1897
+ declare const REDUCE_IMAX = 5;
1898
+ declare const REDUCE_UMIN = 6;
1899
+ declare const REDUCE_UMAX = 7;
1900
+ declare const ARG_FMIN = 0;
1901
+ declare const ARG_FMAX = 1;
1902
+ declare const ARG_IMIN = 2;
1903
+ declare const ARG_IMAX = 3;
1904
+ declare const ARG_UMIN = 4;
1905
+ declare const ARG_UMAX = 5;
1906
+ declare const SCATTER_FADD = 0;
1907
+ declare const SCATTER_IADD = 1;
1908
+ declare const SCAN_F_INCLUSIVE = 0;
1909
+ declare const SCAN_F_EXCLUSIVE = 1;
1910
+ declare const SCAN_I_INCLUSIVE = 2;
1911
+ declare const SCAN_I_EXCLUSIVE = 3;
1912
+ declare function crossRow(op: number): boolean;
1913
+ declare const LOOKUP_OP: {
1914
+ readonly CURVE: 176;
1915
+ readonly LUT1: 177;
1916
+ readonly LUT2: 178;
1917
+ readonly SAMPLE: 179;
1918
+ readonly CELL: 180;
1919
+ };
1920
+ declare const ACCESS_INDEXED: number;
1921
+ declare const CURVE_STEP = 0;
1922
+ declare const CURVE_LINEAR = 1;
1923
+ declare const CURVE_HERMITE = 2;
1924
+ declare const CURVE_BEZIER = 3;
1925
+ declare const CURVE_HEADER = 4;
1926
+ declare const CURVE_MAX_KEYS = 256;
1927
+ declare const CURVE_MAX_CHANNELS = 4;
1928
+ declare const LUT1_HEADER = 4;
1929
+ declare const LUT1_MAX: number;
1930
+ declare const LUT2_HEADER = 8;
1931
+ declare const LUT2_MAX: number;
1932
+ declare const LUT_LINEAR = 1;
1933
+ declare const LUT_WRAP = 2;
1934
+ declare const SAMPLER_WORDS = 8;
1935
+ declare const SAMPLE_NEAREST = 0;
1936
+ declare const SAMPLE_BILINEAR = 1;
1937
+ declare const SAMPLE_NORMAL_X = 2;
1938
+ declare const SAMPLE_NORMAL_Y = 3;
1939
+ declare const SAMPLE_NORMAL_Z = 4;
1940
+ declare const CELL_WRAP: number;
1941
+ declare function lookupOp(op: number): boolean;
1942
+ declare const XOP_QUERY = 4096;
1943
+ declare const XOP_QSHAPE = 4097;
1944
+ declare const XOP_QFILTER = 4098;
1945
+ declare const XOP_QSTOP = 4099;
1946
+ declare const XOP_QRANK = 4100;
1947
+ declare const KERNEL_QUERY_RANK_FEATURE = "kernel_query_rank_1";
1948
+ declare const QUERY_SPHERE = 0;
1949
+ declare const QUERY_CONE = 1;
1950
+ declare const QUERY_BOX = 2;
1951
+ declare const QUERY_SEGMENT = 3;
1952
+ declare const QUERY_SHAPE = 3;
1953
+ declare const QUERY_FILTERED = 4;
1954
+ declare const QFILTER_EQUAL = 1;
1955
+ declare const QFILTER_ANY = 2;
1956
+ declare const QFILTER_NONE = 3;
1957
+ declare function curveWords(kind: number, keys: number, channels: number): number;
1958
+ declare const XOP = 175;
1959
+ declare const XOP_MAX = 65535;
1960
+ declare const XOP_RANGE_SHIFT = 12;
1961
+ declare const XOP_RANGE: {
1962
+ readonly CROSS: 0;
1963
+ readonly SAMPLING: 1;
1964
+ readonly NARROW: 2;
1965
+ readonly DATA: 3;
1966
+ readonly STDLIB: 4;
1967
+ readonly SYSTEMS: 5;
1968
+ readonly NEURAL: 6;
1969
+ readonly SIMD: 7;
1970
+ };
1971
+ declare const XOP_MLP_IN = 24576;
1972
+ declare const XOP_MLP_RUN = 24577;
1973
+ declare const XOP_MLP_OUT = 24578;
1974
+ declare const XOP_MLP_MOE = 24579;
1975
+ declare const KERNEL_MOE_FEATURE = "kernel_moe_1";
1976
+ declare const MLP_MAX_WIDTH = 128;
1977
+ declare const MLP_MAX_OUTPUTS = 32;
1978
+ declare const SIMD_MAP = 28672;
1979
+ declare const SIMD_MAP_OPS = 256;
1980
+ declare const SIMD_SHUFFLE = 28928;
1981
+ declare const SIMD_EXTRACT = 28929;
1982
+ declare const SIMD_REPLACE = 28930;
1983
+ declare const SIMD_PACK = 28931;
1984
+ declare const SIMD_DOT = 28944;
1985
+ declare const SIMD_REDUCE = 28945;
1986
+ declare const SIMD_LENGTH = 28946;
1987
+ declare const SIMD_NORMALIZE = 28947;
1988
+ declare const SIMD_CROSS = 28948;
1989
+ declare const SIMD_MIN_WIDTH = 2;
1990
+ declare const SIMD_MAX_WIDTH = 4;
1991
+ declare const SIMD_WIDTH_MASK = 7;
1992
+ declare const SIMD_SCALAR_A: number;
1993
+ declare const SIMD_SCALAR_B: number;
1994
+ declare const SIMD_SCALAR_C: number;
1995
+ declare const SIMD_LANE_BITS = 3;
1996
+ declare const SIMD_LANE_MASK: number;
1997
+ declare const SIMD_DOT_F32 = 0;
1998
+ declare const SIMD_DOT_I32 = 1;
1999
+ declare const SIMD_CROSS_WIDTH = 3;
2000
+ declare const KERNEL_SIMD_FEATURE = "kernel_simd_1";
2001
+ declare function xopRange(sub: number): number;
2002
+ declare const ACCESS_TABLE_SHIFT = 19;
2003
+ declare const ACCESS_TABLE_MASK = 15;
2004
+ declare const ACCESS_TABLE: number;
2005
+ declare const ACCESS_POOL: number;
2006
+ declare const DATA_TABLES = 16;
2007
+ declare const DATA_KEYOF = 12288;
2008
+ declare const DATA_ROWOF = 12289;
2009
+ declare const DATA_FLOAD = 12290;
2010
+ declare const DATA_ROWS = 12291;
2011
+ declare const DATA_LIST = 12304;
2012
+ declare const DATA_PGET = 12305;
2013
+ declare const DATA_PSET = 12306;
2014
+ declare const DATA_TALLY = 12307;
2015
+ declare const DATA_SEND = 12320;
2016
+ declare const DATA_PICK = 12336;
2017
+ declare const DATA_LIST_MAX = 4096;
2018
+ declare const DATA_TALLIES = 64;
2019
+ declare const SEND: {
2020
+ readonly SET: 0;
2021
+ readonly FADD: 1;
2022
+ readonly FMUL: 2;
2023
+ readonly FMIN: 3;
2024
+ readonly FMAX: 4;
2025
+ readonly IADD: 5;
2026
+ readonly IMIN: 6;
2027
+ readonly IMAX: 7;
2028
+ readonly UMIN: 8;
2029
+ readonly UMAX: 9;
2030
+ readonly OR: 10;
2031
+ readonly AND: 11;
2032
+ readonly PUSH: 12;
2033
+ };
2034
+ declare const PICK_U32 = 0;
2035
+ declare const PICK_F32 = 1;
2036
+ declare const XOP_SORT = 1;
2037
+ declare const XOP_TOPK = 2;
2038
+ declare const XOP_GROUP = 3;
2039
+ declare const XOP_DEDUP = 4;
2040
+ declare const XOP_GATHER = 16;
2041
+ declare const XOP_FIELD = 17;
2042
+ declare const FIELD_MAX = 64;
2043
+ declare const KERNEL_GATHER_FEATURE = "kernel_gather_1";
2044
+ declare const XOP_RECUR = 32;
2045
+ declare const XOP_RECUR_IN = 33;
2046
+ declare const KERNEL_SCAN_FEATURE = "kernel_scan_1";
2047
+ declare const KERNEL_MLP_FEATURE = "kernel_mlp_1";
2048
+ declare const RECUR: {
2049
+ readonly LINEAR_F32: 0;
2050
+ readonly LINEAR_U32: 1;
2051
+ readonly FEEDBACK_F32: 2;
2052
+ readonly PHASE_F64: 3;
2053
+ readonly ADD_F32: 4;
2054
+ readonly MUL_F32: 5;
2055
+ readonly MIN_F32: 6;
2056
+ readonly MAX_F32: 7;
2057
+ readonly ADD_INT: 8;
2058
+ readonly MUL_INT: 9;
2059
+ readonly MIN_I32: 10;
2060
+ readonly MAX_I32: 11;
2061
+ readonly MIN_U32: 12;
2062
+ readonly MAX_U32: 13;
2063
+ readonly AND: 14;
2064
+ readonly OR: 15;
2065
+ readonly XOR: 16;
2066
+ };
2067
+ declare const RECUR_KINDS = 17;
2068
+ declare const RECUR_KIND_MASK = 31;
2069
+ declare const RECUR_EXCLUSIVE = 32;
2070
+ declare const RECUR_WIDE = 64;
2071
+ declare function recurSub(sub: number): boolean;
2072
+ declare function recurStateWords(kind: number): number;
2073
+ declare function recurCoefficient(kind: number): boolean;
2074
+ declare function recurFloatOutput(kind: number): boolean;
2075
+ declare const XOP_COMPONENTS_GRID = 20480;
2076
+ declare const XOP_REACH_GRID = 20481;
2077
+ declare const XOP_PROPAGATE_GRID = 20482;
2078
+ declare const XOP_COMPONENTS_EDGES = 20483;
2079
+ declare const GRAPH_EMPTY = 4294967295;
2080
+ declare const SORT_KEY_U32 = 0;
2081
+ declare const SORT_KEY_I32 = 1;
2082
+ declare const SORT_KEY_F32 = 2;
2083
+ declare const SORT_KEY_MASK = 3;
2084
+ declare const SORT_DESCENDING = 4;
2085
+ declare const SORT_RADIX_BITS = 8;
2086
+ declare function sortKey(kind: number, raw: number): number;
2087
+ declare function stageEnds(sub: number): boolean;
2088
+ declare function stageEndingOp(op: number, sub: number): boolean;
2089
+
2090
+ declare const isa_ACCESS_ARRAY: typeof ACCESS_ARRAY;
2091
+ declare const isa_ACCESS_HIGH: typeof ACCESS_HIGH;
2092
+ declare const isa_ACCESS_INDEXED: typeof ACCESS_INDEXED;
2093
+ declare const isa_ACCESS_NEIGHBOUR: typeof ACCESS_NEIGHBOUR;
2094
+ declare const isa_ACCESS_POOL: typeof ACCESS_POOL;
2095
+ declare const isa_ACCESS_READ: typeof ACCESS_READ;
2096
+ declare const isa_ACCESS_SCRATCH: typeof ACCESS_SCRATCH;
2097
+ declare const isa_ACCESS_SPAWN: typeof ACCESS_SPAWN;
2098
+ declare const isa_ACCESS_TABLE: typeof ACCESS_TABLE;
2099
+ declare const isa_ACCESS_TABLE_MASK: typeof ACCESS_TABLE_MASK;
2100
+ declare const isa_ACCESS_TABLE_SHIFT: typeof ACCESS_TABLE_SHIFT;
2101
+ declare const isa_ACCESS_WRITE: typeof ACCESS_WRITE;
2102
+ declare const isa_ARG_FMAX: typeof ARG_FMAX;
2103
+ declare const isa_ARG_FMIN: typeof ARG_FMIN;
2104
+ declare const isa_ARG_IMAX: typeof ARG_IMAX;
2105
+ declare const isa_ARG_IMIN: typeof ARG_IMIN;
2106
+ declare const isa_ARG_UMAX: typeof ARG_UMAX;
2107
+ declare const isa_ARG_UMIN: typeof ARG_UMIN;
2108
+ declare const isa_ATTACH_AUDIO: typeof ATTACH_AUDIO;
2109
+ declare const isa_ATTACH_CHEMISTRY_GRID: typeof ATTACH_CHEMISTRY_GRID;
2110
+ declare const isa_ATTACH_SPAWN_TABLE: typeof ATTACH_SPAWN_TABLE;
2111
+ declare const isa_ATTACH_UI: typeof ATTACH_UI;
2112
+ declare const isa_ATTACH_VOXELS: typeof ATTACH_VOXELS;
2113
+ declare const isa_CELL_WRAP: typeof CELL_WRAP;
2114
+ declare const isa_CHANNEL_WORDS: typeof CHANNEL_WORDS;
2115
+ declare const isa_CROSS_BLOCK: typeof CROSS_BLOCK;
2116
+ declare const isa_CROSS_OP: typeof CROSS_OP;
2117
+ declare const isa_CURVE_BEZIER: typeof CURVE_BEZIER;
2118
+ declare const isa_CURVE_HEADER: typeof CURVE_HEADER;
2119
+ declare const isa_CURVE_HERMITE: typeof CURVE_HERMITE;
2120
+ declare const isa_CURVE_LINEAR: typeof CURVE_LINEAR;
2121
+ declare const isa_CURVE_MAX_CHANNELS: typeof CURVE_MAX_CHANNELS;
2122
+ declare const isa_CURVE_MAX_KEYS: typeof CURVE_MAX_KEYS;
2123
+ declare const isa_CURVE_STEP: typeof CURVE_STEP;
2124
+ declare const isa_DATA_FLOAD: typeof DATA_FLOAD;
2125
+ declare const isa_DATA_KEYOF: typeof DATA_KEYOF;
2126
+ declare const isa_DATA_LIST: typeof DATA_LIST;
2127
+ declare const isa_DATA_LIST_MAX: typeof DATA_LIST_MAX;
2128
+ declare const isa_DATA_PGET: typeof DATA_PGET;
2129
+ declare const isa_DATA_PICK: typeof DATA_PICK;
2130
+ declare const isa_DATA_PSET: typeof DATA_PSET;
2131
+ declare const isa_DATA_REPORT_HEADER: typeof DATA_REPORT_HEADER;
2132
+ declare const isa_DATA_ROWOF: typeof DATA_ROWOF;
2133
+ declare const isa_DATA_ROWS: typeof DATA_ROWS;
2134
+ declare const isa_DATA_SEND: typeof DATA_SEND;
2135
+ declare const isa_DATA_TABLES: typeof DATA_TABLES;
2136
+ declare const isa_DATA_TALLIES: typeof DATA_TALLIES;
2137
+ declare const isa_DATA_TALLY: typeof DATA_TALLY;
2138
+ declare const isa_DEFAULT_EVENT_CAPACITY: typeof DEFAULT_EVENT_CAPACITY;
2139
+ declare const isa_DST_BITS: typeof DST_BITS;
2140
+ declare const isa_EVENT_HEADER_WORDS: typeof EVENT_HEADER_WORDS;
2141
+ declare const isa_EVENT_STRIDE: typeof EVENT_STRIDE;
2142
+ declare const isa_FIELD_MAX: typeof FIELD_MAX;
2143
+ declare const isa_FLAG_GROUPS: typeof FLAG_GROUPS;
2144
+ declare const isa_FLAG_NEIGHBOURS: typeof FLAG_NEIGHBOURS;
2145
+ declare const isa_GRAPH_EMPTY: typeof GRAPH_EMPTY;
2146
+ declare const isa_GROUP_DEFAULT: typeof GROUP_DEFAULT;
2147
+ declare const isa_GROUP_WORDS: typeof GROUP_WORDS;
2148
+ declare const isa_H_ARGS: typeof H_ARGS;
2149
+ declare const isa_H_CONSTANTS: typeof H_CONSTANTS;
2150
+ declare const isa_H_EVENTS: typeof H_EVENTS;
2151
+ declare const isa_H_FLAGS: typeof H_FLAGS;
2152
+ declare const isa_H_GROUPS: typeof H_GROUPS;
2153
+ declare const isa_H_INSTRUCTIONS: typeof H_INSTRUCTIONS;
2154
+ declare const isa_H_LOOPS: typeof H_LOOPS;
2155
+ declare const isa_H_MAGIC: typeof H_MAGIC;
2156
+ declare const isa_H_POSITION_X: typeof H_POSITION_X;
2157
+ declare const isa_H_POSITION_Y: typeof H_POSITION_Y;
2158
+ declare const isa_H_POSITION_Z: typeof H_POSITION_Z;
2159
+ declare const isa_H_REGISTERS: typeof H_REGISTERS;
2160
+ declare const isa_H_SLOTS: typeof H_SLOTS;
2161
+ declare const isa_H_STATE: typeof H_STATE;
2162
+ declare const isa_H_VERSION: typeof H_VERSION;
2163
+ declare const isa_INSTRUCTION_WORDS: typeof INSTRUCTION_WORDS;
2164
+ declare const isa_KERNEL_CALLS_FEATURE: typeof KERNEL_CALLS_FEATURE;
2165
+ declare const isa_KERNEL_CALL_EXPORT_NAMES: typeof KERNEL_CALL_EXPORT_NAMES;
2166
+ declare const isa_KERNEL_DATA_EXPORT_NAMES: typeof KERNEL_DATA_EXPORT_NAMES;
2167
+ declare const isa_KERNEL_EXPORT_NAMES: typeof KERNEL_EXPORT_NAMES;
2168
+ declare const isa_KERNEL_EXTENDED_FEATURE: typeof KERNEL_EXTENDED_FEATURE;
2169
+ declare const isa_KERNEL_FEATURE: typeof KERNEL_FEATURE;
2170
+ declare const isa_KERNEL_GATHER_FEATURE: typeof KERNEL_GATHER_FEATURE;
2171
+ declare const isa_KERNEL_ISA_BASE: typeof KERNEL_ISA_BASE;
2172
+ declare const isa_KERNEL_ISA_CALLS: typeof KERNEL_ISA_CALLS;
2173
+ declare const isa_KERNEL_ISA_EXTENDED: typeof KERNEL_ISA_EXTENDED;
2174
+ declare const isa_KERNEL_ISA_VERSION: typeof KERNEL_ISA_VERSION;
2175
+ declare const isa_KERNEL_ISA_WRITES: typeof KERNEL_ISA_WRITES;
2176
+ declare const isa_KERNEL_LIBRARY_PATH: typeof KERNEL_LIBRARY_PATH;
2177
+ declare const isa_KERNEL_MLP_FEATURE: typeof KERNEL_MLP_FEATURE;
2178
+ declare const isa_KERNEL_MOE_FEATURE: typeof KERNEL_MOE_FEATURE;
2179
+ declare const isa_KERNEL_QUERY_RANK_FEATURE: typeof KERNEL_QUERY_RANK_FEATURE;
2180
+ declare const isa_KERNEL_SCAN_FEATURE: typeof KERNEL_SCAN_FEATURE;
2181
+ declare const isa_KERNEL_SIMD_FEATURE: typeof KERNEL_SIMD_FEATURE;
2182
+ declare const isa_KERNEL_STAGE_EXPORT_NAMES: typeof KERNEL_STAGE_EXPORT_NAMES;
2183
+ declare const isa_KERNEL_WRITES_FEATURE: typeof KERNEL_WRITES_FEATURE;
2184
+ declare const isa_KERNEL_WRITE_EXPORT_NAMES: typeof KERNEL_WRITE_EXPORT_NAMES;
2185
+ declare const isa_KIND_BOOL: typeof KIND_BOOL;
2186
+ declare const isa_KIND_F32: typeof KIND_F32;
2187
+ declare const isa_KIND_I32: typeof KIND_I32;
2188
+ declare const isa_KIND_U32: typeof KIND_U32;
2189
+ declare const isa_LIBRARY_HEADER_WORDS: typeof LIBRARY_HEADER_WORDS;
2190
+ declare const isa_LIBRARY_MAGIC: typeof LIBRARY_MAGIC;
2191
+ declare const isa_LOOKUP_OP: typeof LOOKUP_OP;
2192
+ declare const isa_LOOP_COUNT_F32: typeof LOOP_COUNT_F32;
2193
+ declare const isa_LUT1_HEADER: typeof LUT1_HEADER;
2194
+ declare const isa_LUT1_MAX: typeof LUT1_MAX;
2195
+ declare const isa_LUT2_HEADER: typeof LUT2_HEADER;
2196
+ declare const isa_LUT2_MAX: typeof LUT2_MAX;
2197
+ declare const isa_LUT_LINEAR: typeof LUT_LINEAR;
2198
+ declare const isa_LUT_WRAP: typeof LUT_WRAP;
2199
+ declare const isa_MAX_CHANNELS: typeof MAX_CHANNELS;
2200
+ declare const isa_MAX_EVENT_WORDS: typeof MAX_EVENT_WORDS;
2201
+ declare const isa_MAX_GROUPS: typeof MAX_GROUPS;
2202
+ declare const isa_MAX_REGISTERS: typeof MAX_REGISTERS;
2203
+ declare const isa_MAX_SLOTS: typeof MAX_SLOTS;
2204
+ declare const isa_MAX_SPAWN_FIELDS: typeof MAX_SPAWN_FIELDS;
2205
+ declare const isa_MAX_TRIPS: typeof MAX_TRIPS;
2206
+ declare const isa_MAX_UNIFORMS: typeof MAX_UNIFORMS;
2207
+ declare const isa_MLP_MAX_OUTPUTS: typeof MLP_MAX_OUTPUTS;
2208
+ declare const isa_MLP_MAX_WIDTH: typeof MLP_MAX_WIDTH;
2209
+ declare const isa_NONE: typeof NONE;
2210
+ declare const isa_Op: typeof Op;
2211
+ type isa_OpCode = OpCode;
2212
+ declare const isa_PICK_F32: typeof PICK_F32;
2213
+ declare const isa_PICK_U32: typeof PICK_U32;
2214
+ declare const isa_PROGRAM_HEADER_WORDS: typeof PROGRAM_HEADER_WORDS;
2215
+ declare const isa_PROGRAM_MAGIC: typeof PROGRAM_MAGIC;
2216
+ declare const isa_QFILTER_ANY: typeof QFILTER_ANY;
2217
+ declare const isa_QFILTER_EQUAL: typeof QFILTER_EQUAL;
2218
+ declare const isa_QFILTER_NONE: typeof QFILTER_NONE;
2219
+ declare const isa_QUERY_BOX: typeof QUERY_BOX;
2220
+ declare const isa_QUERY_CONE: typeof QUERY_CONE;
2221
+ declare const isa_QUERY_FILTERED: typeof QUERY_FILTERED;
2222
+ declare const isa_QUERY_SEGMENT: typeof QUERY_SEGMENT;
2223
+ declare const isa_QUERY_SHAPE: typeof QUERY_SHAPE;
2224
+ declare const isa_QUERY_SPHERE: typeof QUERY_SPHERE;
2225
+ declare const isa_RECUR: typeof RECUR;
2226
+ declare const isa_RECUR_EXCLUSIVE: typeof RECUR_EXCLUSIVE;
2227
+ declare const isa_RECUR_KINDS: typeof RECUR_KINDS;
2228
+ declare const isa_RECUR_KIND_MASK: typeof RECUR_KIND_MASK;
2229
+ declare const isa_RECUR_WIDE: typeof RECUR_WIDE;
2230
+ declare const isa_REDUCE_FMAX: typeof REDUCE_FMAX;
2231
+ declare const isa_REDUCE_FMIN: typeof REDUCE_FMIN;
2232
+ declare const isa_REDUCE_FSUM: typeof REDUCE_FSUM;
2233
+ declare const isa_REDUCE_IMAX: typeof REDUCE_IMAX;
2234
+ declare const isa_REDUCE_IMIN: typeof REDUCE_IMIN;
2235
+ declare const isa_REDUCE_ISUM: typeof REDUCE_ISUM;
2236
+ declare const isa_REDUCE_UMAX: typeof REDUCE_UMAX;
2237
+ declare const isa_REDUCE_UMIN: typeof REDUCE_UMIN;
2238
+ declare const isa_RING_COUNT: typeof RING_COUNT;
2239
+ declare const isa_RING_DROPPED: typeof RING_DROPPED;
2240
+ declare const isa_RING_HEADER_WORDS: typeof RING_HEADER_WORDS;
2241
+ declare const isa_SAMPLER_WORDS: typeof SAMPLER_WORDS;
2242
+ declare const isa_SAMPLE_BILINEAR: typeof SAMPLE_BILINEAR;
2243
+ declare const isa_SAMPLE_NEAREST: typeof SAMPLE_NEAREST;
2244
+ declare const isa_SAMPLE_NORMAL_X: typeof SAMPLE_NORMAL_X;
2245
+ declare const isa_SAMPLE_NORMAL_Y: typeof SAMPLE_NORMAL_Y;
2246
+ declare const isa_SAMPLE_NORMAL_Z: typeof SAMPLE_NORMAL_Z;
2247
+ declare const isa_SCAN_F_EXCLUSIVE: typeof SCAN_F_EXCLUSIVE;
2248
+ declare const isa_SCAN_F_INCLUSIVE: typeof SCAN_F_INCLUSIVE;
2249
+ declare const isa_SCAN_I_EXCLUSIVE: typeof SCAN_I_EXCLUSIVE;
2250
+ declare const isa_SCAN_I_INCLUSIVE: typeof SCAN_I_INCLUSIVE;
2251
+ declare const isa_SCATTER_FADD: typeof SCATTER_FADD;
2252
+ declare const isa_SCATTER_IADD: typeof SCATTER_IADD;
2253
+ declare const isa_SEND: typeof SEND;
2254
+ declare const isa_SERVICE_ANCHOR: typeof SERVICE_ANCHOR;
2255
+ declare const isa_SERVICE_BITS: typeof SERVICE_BITS;
2256
+ declare const isa_SERVICE_CHEMISTRY: typeof SERVICE_CHEMISTRY;
2257
+ declare const isa_SERVICE_CLIP_WEIGHT: typeof SERVICE_CLIP_WEIGHT;
2258
+ declare const isa_SERVICE_FLOW: typeof SERVICE_FLOW;
2259
+ declare const isa_SERVICE_FORCE: typeof SERVICE_FORCE;
2260
+ declare const isa_SERVICE_GROUND_HEIGHT: typeof SERVICE_GROUND_HEIGHT;
2261
+ declare const isa_SERVICE_IK_TARGET: typeof SERVICE_IK_TARGET;
2262
+ declare const isa_SERVICE_IMPULSE: typeof SERVICE_IMPULSE;
2263
+ declare const isa_SERVICE_INSTANCE: typeof SERVICE_INSTANCE;
2264
+ declare const isa_SERVICE_INSTANCE_COLOUR: typeof SERVICE_INSTANCE_COLOUR;
2265
+ declare const isa_SERVICE_KILL: typeof SERVICE_KILL;
2266
+ declare const isa_SERVICE_LINE_OF_SIGHT: typeof SERVICE_LINE_OF_SIGHT;
2267
+ declare const isa_SERVICE_MASK: typeof SERVICE_MASK;
2268
+ declare const isa_SERVICE_OVERLAP: typeof SERVICE_OVERLAP;
2269
+ declare const isa_SERVICE_PATH: typeof SERVICE_PATH;
2270
+ declare const isa_SERVICE_PICK: typeof SERVICE_PICK;
2271
+ declare const isa_SERVICE_PLAY_CLIP: typeof SERVICE_PLAY_CLIP;
2272
+ declare const isa_SERVICE_RAYCAST: typeof SERVICE_RAYCAST;
2273
+ declare const isa_SERVICE_SIGNATURES: typeof SERVICE_SIGNATURES;
2274
+ declare const isa_SERVICE_SOUND: typeof SERVICE_SOUND;
2275
+ declare const isa_SERVICE_SPAWN: typeof SERVICE_SPAWN;
2276
+ declare const isa_SERVICE_SWEEP: typeof SERVICE_SWEEP;
2277
+ declare const isa_SERVICE_VELOCITY: typeof SERVICE_VELOCITY;
2278
+ declare const isa_SERVICE_VOXEL_GET: typeof SERVICE_VOXEL_GET;
2279
+ declare const isa_SERVICE_VOXEL_SET: typeof SERVICE_VOXEL_SET;
2280
+ declare const isa_SIMD_CROSS: typeof SIMD_CROSS;
2281
+ declare const isa_SIMD_CROSS_WIDTH: typeof SIMD_CROSS_WIDTH;
2282
+ declare const isa_SIMD_DOT: typeof SIMD_DOT;
2283
+ declare const isa_SIMD_DOT_F32: typeof SIMD_DOT_F32;
2284
+ declare const isa_SIMD_DOT_I32: typeof SIMD_DOT_I32;
2285
+ declare const isa_SIMD_EXTRACT: typeof SIMD_EXTRACT;
2286
+ declare const isa_SIMD_LANE_BITS: typeof SIMD_LANE_BITS;
2287
+ declare const isa_SIMD_LANE_MASK: typeof SIMD_LANE_MASK;
2288
+ declare const isa_SIMD_LENGTH: typeof SIMD_LENGTH;
2289
+ declare const isa_SIMD_MAP: typeof SIMD_MAP;
2290
+ declare const isa_SIMD_MAP_OPS: typeof SIMD_MAP_OPS;
2291
+ declare const isa_SIMD_MAX_WIDTH: typeof SIMD_MAX_WIDTH;
2292
+ declare const isa_SIMD_MIN_WIDTH: typeof SIMD_MIN_WIDTH;
2293
+ declare const isa_SIMD_NORMALIZE: typeof SIMD_NORMALIZE;
2294
+ declare const isa_SIMD_PACK: typeof SIMD_PACK;
2295
+ declare const isa_SIMD_REDUCE: typeof SIMD_REDUCE;
2296
+ declare const isa_SIMD_REPLACE: typeof SIMD_REPLACE;
2297
+ declare const isa_SIMD_SCALAR_A: typeof SIMD_SCALAR_A;
2298
+ declare const isa_SIMD_SCALAR_B: typeof SIMD_SCALAR_B;
2299
+ declare const isa_SIMD_SCALAR_C: typeof SIMD_SCALAR_C;
2300
+ declare const isa_SIMD_SHUFFLE: typeof SIMD_SHUFFLE;
2301
+ declare const isa_SIMD_WIDTH_MASK: typeof SIMD_WIDTH_MASK;
2302
+ declare const isa_SORT_DESCENDING: typeof SORT_DESCENDING;
2303
+ declare const isa_SORT_KEY_F32: typeof SORT_KEY_F32;
2304
+ declare const isa_SORT_KEY_I32: typeof SORT_KEY_I32;
2305
+ declare const isa_SORT_KEY_MASK: typeof SORT_KEY_MASK;
2306
+ declare const isa_SORT_KEY_U32: typeof SORT_KEY_U32;
2307
+ declare const isa_SORT_RADIX_BITS: typeof SORT_RADIX_BITS;
2308
+ declare const isa_SPAWN_STATS_WORDS: typeof SPAWN_STATS_WORDS;
2309
+ declare const isa_STATUS_FAILURE: typeof STATUS_FAILURE;
2310
+ declare const isa_STATUS_RUNNING: typeof STATUS_RUNNING;
2311
+ declare const isa_STATUS_SUCCESS: typeof STATUS_SUCCESS;
2312
+ type isa_ServiceSignature = ServiceSignature;
2313
+ declare const isa_UNIFORM: typeof UNIFORM;
2314
+ declare const isa_XOP: typeof XOP;
2315
+ declare const isa_XOP_COMPONENTS_EDGES: typeof XOP_COMPONENTS_EDGES;
2316
+ declare const isa_XOP_COMPONENTS_GRID: typeof XOP_COMPONENTS_GRID;
2317
+ declare const isa_XOP_DEDUP: typeof XOP_DEDUP;
2318
+ declare const isa_XOP_FIELD: typeof XOP_FIELD;
2319
+ declare const isa_XOP_GATHER: typeof XOP_GATHER;
2320
+ declare const isa_XOP_GROUP: typeof XOP_GROUP;
2321
+ declare const isa_XOP_MAX: typeof XOP_MAX;
2322
+ declare const isa_XOP_MLP_IN: typeof XOP_MLP_IN;
2323
+ declare const isa_XOP_MLP_MOE: typeof XOP_MLP_MOE;
2324
+ declare const isa_XOP_MLP_OUT: typeof XOP_MLP_OUT;
2325
+ declare const isa_XOP_MLP_RUN: typeof XOP_MLP_RUN;
2326
+ declare const isa_XOP_PROPAGATE_GRID: typeof XOP_PROPAGATE_GRID;
2327
+ declare const isa_XOP_QFILTER: typeof XOP_QFILTER;
2328
+ declare const isa_XOP_QRANK: typeof XOP_QRANK;
2329
+ declare const isa_XOP_QSHAPE: typeof XOP_QSHAPE;
2330
+ declare const isa_XOP_QSTOP: typeof XOP_QSTOP;
2331
+ declare const isa_XOP_QUERY: typeof XOP_QUERY;
2332
+ declare const isa_XOP_RANGE: typeof XOP_RANGE;
2333
+ declare const isa_XOP_RANGE_SHIFT: typeof XOP_RANGE_SHIFT;
2334
+ declare const isa_XOP_REACH_GRID: typeof XOP_REACH_GRID;
2335
+ declare const isa_XOP_RECUR: typeof XOP_RECUR;
2336
+ declare const isa_XOP_RECUR_IN: typeof XOP_RECUR_IN;
2337
+ declare const isa_XOP_SORT: typeof XOP_SORT;
2338
+ declare const isa_XOP_TOPK: typeof XOP_TOPK;
2339
+ declare const isa_crossRow: typeof crossRow;
2340
+ declare const isa_curveWords: typeof curveWords;
2341
+ declare const isa_deferredService: typeof deferredService;
2342
+ declare const isa_lookupOp: typeof lookupOp;
2343
+ declare const isa_operandCount: typeof operandCount;
2344
+ declare const isa_recurCoefficient: typeof recurCoefficient;
2345
+ declare const isa_recurFloatOutput: typeof recurFloatOutput;
2346
+ declare const isa_recurStateWords: typeof recurStateWords;
2347
+ declare const isa_recurSub: typeof recurSub;
2348
+ declare const isa_serviceOf: typeof serviceOf;
2349
+ declare const isa_serviceVersion: typeof serviceVersion;
2350
+ declare const isa_sortKey: typeof sortKey;
2351
+ declare const isa_stageEndingOp: typeof stageEndingOp;
2352
+ declare const isa_stageEnds: typeof stageEnds;
2353
+ declare const isa_xopRange: typeof xopRange;
2354
+ declare namespace isa {
2355
+ export { isa_ACCESS_ARRAY as ACCESS_ARRAY, isa_ACCESS_HIGH as ACCESS_HIGH, isa_ACCESS_INDEXED as ACCESS_INDEXED, isa_ACCESS_NEIGHBOUR as ACCESS_NEIGHBOUR, isa_ACCESS_POOL as ACCESS_POOL, isa_ACCESS_READ as ACCESS_READ, isa_ACCESS_SCRATCH as ACCESS_SCRATCH, isa_ACCESS_SPAWN as ACCESS_SPAWN, isa_ACCESS_TABLE as ACCESS_TABLE, isa_ACCESS_TABLE_MASK as ACCESS_TABLE_MASK, isa_ACCESS_TABLE_SHIFT as ACCESS_TABLE_SHIFT, isa_ACCESS_WRITE as ACCESS_WRITE, isa_ARG_FMAX as ARG_FMAX, isa_ARG_FMIN as ARG_FMIN, isa_ARG_IMAX as ARG_IMAX, isa_ARG_IMIN as ARG_IMIN, isa_ARG_UMAX as ARG_UMAX, isa_ARG_UMIN as ARG_UMIN, isa_ATTACH_AUDIO as ATTACH_AUDIO, isa_ATTACH_CHEMISTRY_GRID as ATTACH_CHEMISTRY_GRID, isa_ATTACH_SPAWN_TABLE as ATTACH_SPAWN_TABLE, isa_ATTACH_UI as ATTACH_UI, isa_ATTACH_VOXELS as ATTACH_VOXELS, isa_CELL_WRAP as CELL_WRAP, isa_CHANNEL_WORDS as CHANNEL_WORDS, isa_CROSS_BLOCK as CROSS_BLOCK, isa_CROSS_OP as CROSS_OP, isa_CURVE_BEZIER as CURVE_BEZIER, isa_CURVE_HEADER as CURVE_HEADER, isa_CURVE_HERMITE as CURVE_HERMITE, isa_CURVE_LINEAR as CURVE_LINEAR, isa_CURVE_MAX_CHANNELS as CURVE_MAX_CHANNELS, isa_CURVE_MAX_KEYS as CURVE_MAX_KEYS, isa_CURVE_STEP as CURVE_STEP, isa_DATA_FLOAD as DATA_FLOAD, isa_DATA_KEYOF as DATA_KEYOF, isa_DATA_LIST as DATA_LIST, isa_DATA_LIST_MAX as DATA_LIST_MAX, isa_DATA_PGET as DATA_PGET, isa_DATA_PICK as DATA_PICK, isa_DATA_PSET as DATA_PSET, isa_DATA_REPORT_HEADER as DATA_REPORT_HEADER, isa_DATA_ROWOF as DATA_ROWOF, isa_DATA_ROWS as DATA_ROWS, isa_DATA_SEND as DATA_SEND, isa_DATA_TABLES as DATA_TABLES, isa_DATA_TALLIES as DATA_TALLIES, isa_DATA_TALLY as DATA_TALLY, isa_DEFAULT_EVENT_CAPACITY as DEFAULT_EVENT_CAPACITY, isa_DST_BITS as DST_BITS, isa_EVENT_HEADER_WORDS as EVENT_HEADER_WORDS, isa_EVENT_STRIDE as EVENT_STRIDE, isa_FIELD_MAX as FIELD_MAX, isa_FLAG_GROUPS as FLAG_GROUPS, isa_FLAG_NEIGHBOURS as FLAG_NEIGHBOURS, isa_GRAPH_EMPTY as GRAPH_EMPTY, isa_GROUP_DEFAULT as GROUP_DEFAULT, isa_GROUP_WORDS as GROUP_WORDS, isa_H_ARGS as H_ARGS, isa_H_CONSTANTS as H_CONSTANTS, isa_H_EVENTS as H_EVENTS, isa_H_FLAGS as H_FLAGS, isa_H_GROUPS as H_GROUPS, isa_H_INSTRUCTIONS as H_INSTRUCTIONS, isa_H_LOOPS as H_LOOPS, isa_H_MAGIC as H_MAGIC, isa_H_POSITION_X as H_POSITION_X, isa_H_POSITION_Y as H_POSITION_Y, isa_H_POSITION_Z as H_POSITION_Z, isa_H_REGISTERS as H_REGISTERS, isa_H_SLOTS as H_SLOTS, isa_H_STATE as H_STATE, isa_H_VERSION as H_VERSION, isa_INSTRUCTION_WORDS as INSTRUCTION_WORDS, isa_KERNEL_CALLS_FEATURE as KERNEL_CALLS_FEATURE, isa_KERNEL_CALL_EXPORT_NAMES as KERNEL_CALL_EXPORT_NAMES, isa_KERNEL_DATA_EXPORT_NAMES as KERNEL_DATA_EXPORT_NAMES, isa_KERNEL_EXPORT_NAMES as KERNEL_EXPORT_NAMES, isa_KERNEL_EXTENDED_FEATURE as KERNEL_EXTENDED_FEATURE, isa_KERNEL_FEATURE as KERNEL_FEATURE, isa_KERNEL_GATHER_FEATURE as KERNEL_GATHER_FEATURE, isa_KERNEL_ISA_BASE as KERNEL_ISA_BASE, isa_KERNEL_ISA_CALLS as KERNEL_ISA_CALLS, isa_KERNEL_ISA_EXTENDED as KERNEL_ISA_EXTENDED, isa_KERNEL_ISA_VERSION as KERNEL_ISA_VERSION, isa_KERNEL_ISA_WRITES as KERNEL_ISA_WRITES, isa_KERNEL_LIBRARY_PATH as KERNEL_LIBRARY_PATH, isa_KERNEL_MLP_FEATURE as KERNEL_MLP_FEATURE, isa_KERNEL_MOE_FEATURE as KERNEL_MOE_FEATURE, isa_KERNEL_QUERY_RANK_FEATURE as KERNEL_QUERY_RANK_FEATURE, isa_KERNEL_SCAN_FEATURE as KERNEL_SCAN_FEATURE, isa_KERNEL_SIMD_FEATURE as KERNEL_SIMD_FEATURE, isa_KERNEL_STAGE_EXPORT_NAMES as KERNEL_STAGE_EXPORT_NAMES, isa_KERNEL_WRITES_FEATURE as KERNEL_WRITES_FEATURE, isa_KERNEL_WRITE_EXPORT_NAMES as KERNEL_WRITE_EXPORT_NAMES, isa_KIND_BOOL as KIND_BOOL, isa_KIND_F32 as KIND_F32, isa_KIND_I32 as KIND_I32, isa_KIND_U32 as KIND_U32, isa_LIBRARY_HEADER_WORDS as LIBRARY_HEADER_WORDS, isa_LIBRARY_MAGIC as LIBRARY_MAGIC, isa_LOOKUP_OP as LOOKUP_OP, isa_LOOP_COUNT_F32 as LOOP_COUNT_F32, isa_LUT1_HEADER as LUT1_HEADER, isa_LUT1_MAX as LUT1_MAX, isa_LUT2_HEADER as LUT2_HEADER, isa_LUT2_MAX as LUT2_MAX, isa_LUT_LINEAR as LUT_LINEAR, isa_LUT_WRAP as LUT_WRAP, isa_MAX_CHANNELS as MAX_CHANNELS, isa_MAX_EVENT_WORDS as MAX_EVENT_WORDS, isa_MAX_GROUPS as MAX_GROUPS, isa_MAX_REGISTERS as MAX_REGISTERS, isa_MAX_SLOTS as MAX_SLOTS, isa_MAX_SPAWN_FIELDS as MAX_SPAWN_FIELDS, isa_MAX_TRIPS as MAX_TRIPS, isa_MAX_UNIFORMS as MAX_UNIFORMS, isa_MLP_MAX_OUTPUTS as MLP_MAX_OUTPUTS, isa_MLP_MAX_WIDTH as MLP_MAX_WIDTH, isa_NONE as NONE, isa_Op as Op, type isa_OpCode as OpCode, isa_PICK_F32 as PICK_F32, isa_PICK_U32 as PICK_U32, isa_PROGRAM_HEADER_WORDS as PROGRAM_HEADER_WORDS, isa_PROGRAM_MAGIC as PROGRAM_MAGIC, isa_QFILTER_ANY as QFILTER_ANY, isa_QFILTER_EQUAL as QFILTER_EQUAL, isa_QFILTER_NONE as QFILTER_NONE, isa_QUERY_BOX as QUERY_BOX, isa_QUERY_CONE as QUERY_CONE, isa_QUERY_FILTERED as QUERY_FILTERED, isa_QUERY_SEGMENT as QUERY_SEGMENT, isa_QUERY_SHAPE as QUERY_SHAPE, isa_QUERY_SPHERE as QUERY_SPHERE, isa_RECUR as RECUR, isa_RECUR_EXCLUSIVE as RECUR_EXCLUSIVE, isa_RECUR_KINDS as RECUR_KINDS, isa_RECUR_KIND_MASK as RECUR_KIND_MASK, isa_RECUR_WIDE as RECUR_WIDE, isa_REDUCE_FMAX as REDUCE_FMAX, isa_REDUCE_FMIN as REDUCE_FMIN, isa_REDUCE_FSUM as REDUCE_FSUM, isa_REDUCE_IMAX as REDUCE_IMAX, isa_REDUCE_IMIN as REDUCE_IMIN, isa_REDUCE_ISUM as REDUCE_ISUM, isa_REDUCE_UMAX as REDUCE_UMAX, isa_REDUCE_UMIN as REDUCE_UMIN, isa_RING_COUNT as RING_COUNT, isa_RING_DROPPED as RING_DROPPED, isa_RING_HEADER_WORDS as RING_HEADER_WORDS, isa_SAMPLER_WORDS as SAMPLER_WORDS, isa_SAMPLE_BILINEAR as SAMPLE_BILINEAR, isa_SAMPLE_NEAREST as SAMPLE_NEAREST, isa_SAMPLE_NORMAL_X as SAMPLE_NORMAL_X, isa_SAMPLE_NORMAL_Y as SAMPLE_NORMAL_Y, isa_SAMPLE_NORMAL_Z as SAMPLE_NORMAL_Z, isa_SCAN_F_EXCLUSIVE as SCAN_F_EXCLUSIVE, isa_SCAN_F_INCLUSIVE as SCAN_F_INCLUSIVE, isa_SCAN_I_EXCLUSIVE as SCAN_I_EXCLUSIVE, isa_SCAN_I_INCLUSIVE as SCAN_I_INCLUSIVE, isa_SCATTER_FADD as SCATTER_FADD, isa_SCATTER_IADD as SCATTER_IADD, isa_SEND as SEND, isa_SERVICE_ANCHOR as SERVICE_ANCHOR, isa_SERVICE_BITS as SERVICE_BITS, isa_SERVICE_CHEMISTRY as SERVICE_CHEMISTRY, isa_SERVICE_CLIP_WEIGHT as SERVICE_CLIP_WEIGHT, isa_SERVICE_FLOW as SERVICE_FLOW, isa_SERVICE_FORCE as SERVICE_FORCE, isa_SERVICE_GROUND_HEIGHT as SERVICE_GROUND_HEIGHT, isa_SERVICE_IK_TARGET as SERVICE_IK_TARGET, isa_SERVICE_IMPULSE as SERVICE_IMPULSE, isa_SERVICE_INSTANCE as SERVICE_INSTANCE, isa_SERVICE_INSTANCE_COLOUR as SERVICE_INSTANCE_COLOUR, isa_SERVICE_KILL as SERVICE_KILL, isa_SERVICE_LINE_OF_SIGHT as SERVICE_LINE_OF_SIGHT, isa_SERVICE_MASK as SERVICE_MASK, isa_SERVICE_OVERLAP as SERVICE_OVERLAP, isa_SERVICE_PATH as SERVICE_PATH, isa_SERVICE_PICK as SERVICE_PICK, isa_SERVICE_PLAY_CLIP as SERVICE_PLAY_CLIP, isa_SERVICE_RAYCAST as SERVICE_RAYCAST, isa_SERVICE_SIGNATURES as SERVICE_SIGNATURES, isa_SERVICE_SOUND as SERVICE_SOUND, isa_SERVICE_SPAWN as SERVICE_SPAWN, isa_SERVICE_SWEEP as SERVICE_SWEEP, isa_SERVICE_VELOCITY as SERVICE_VELOCITY, isa_SERVICE_VOXEL_GET as SERVICE_VOXEL_GET, isa_SERVICE_VOXEL_SET as SERVICE_VOXEL_SET, isa_SIMD_CROSS as SIMD_CROSS, isa_SIMD_CROSS_WIDTH as SIMD_CROSS_WIDTH, isa_SIMD_DOT as SIMD_DOT, isa_SIMD_DOT_F32 as SIMD_DOT_F32, isa_SIMD_DOT_I32 as SIMD_DOT_I32, isa_SIMD_EXTRACT as SIMD_EXTRACT, isa_SIMD_LANE_BITS as SIMD_LANE_BITS, isa_SIMD_LANE_MASK as SIMD_LANE_MASK, isa_SIMD_LENGTH as SIMD_LENGTH, isa_SIMD_MAP as SIMD_MAP, isa_SIMD_MAP_OPS as SIMD_MAP_OPS, isa_SIMD_MAX_WIDTH as SIMD_MAX_WIDTH, isa_SIMD_MIN_WIDTH as SIMD_MIN_WIDTH, isa_SIMD_NORMALIZE as SIMD_NORMALIZE, isa_SIMD_PACK as SIMD_PACK, isa_SIMD_REDUCE as SIMD_REDUCE, isa_SIMD_REPLACE as SIMD_REPLACE, isa_SIMD_SCALAR_A as SIMD_SCALAR_A, isa_SIMD_SCALAR_B as SIMD_SCALAR_B, isa_SIMD_SCALAR_C as SIMD_SCALAR_C, isa_SIMD_SHUFFLE as SIMD_SHUFFLE, isa_SIMD_WIDTH_MASK as SIMD_WIDTH_MASK, isa_SORT_DESCENDING as SORT_DESCENDING, isa_SORT_KEY_F32 as SORT_KEY_F32, isa_SORT_KEY_I32 as SORT_KEY_I32, isa_SORT_KEY_MASK as SORT_KEY_MASK, isa_SORT_KEY_U32 as SORT_KEY_U32, isa_SORT_RADIX_BITS as SORT_RADIX_BITS, isa_SPAWN_STATS_WORDS as SPAWN_STATS_WORDS, isa_STATUS_FAILURE as STATUS_FAILURE, isa_STATUS_RUNNING as STATUS_RUNNING, isa_STATUS_SUCCESS as STATUS_SUCCESS, type isa_ServiceSignature as ServiceSignature, isa_UNIFORM as UNIFORM, isa_XOP as XOP, isa_XOP_COMPONENTS_EDGES as XOP_COMPONENTS_EDGES, isa_XOP_COMPONENTS_GRID as XOP_COMPONENTS_GRID, isa_XOP_DEDUP as XOP_DEDUP, isa_XOP_FIELD as XOP_FIELD, isa_XOP_GATHER as XOP_GATHER, isa_XOP_GROUP as XOP_GROUP, isa_XOP_MAX as XOP_MAX, isa_XOP_MLP_IN as XOP_MLP_IN, isa_XOP_MLP_MOE as XOP_MLP_MOE, isa_XOP_MLP_OUT as XOP_MLP_OUT, isa_XOP_MLP_RUN as XOP_MLP_RUN, isa_XOP_PROPAGATE_GRID as XOP_PROPAGATE_GRID, isa_XOP_QFILTER as XOP_QFILTER, isa_XOP_QRANK as XOP_QRANK, isa_XOP_QSHAPE as XOP_QSHAPE, isa_XOP_QSTOP as XOP_QSTOP, isa_XOP_QUERY as XOP_QUERY, isa_XOP_RANGE as XOP_RANGE, isa_XOP_RANGE_SHIFT as XOP_RANGE_SHIFT, isa_XOP_REACH_GRID as XOP_REACH_GRID, isa_XOP_RECUR as XOP_RECUR, isa_XOP_RECUR_IN as XOP_RECUR_IN, isa_XOP_SORT as XOP_SORT, isa_XOP_TOPK as XOP_TOPK, isa_crossRow as crossRow, isa_curveWords as curveWords, isa_deferredService as deferredService, isa_lookupOp as lookupOp, isa_operandCount as operandCount, isa_recurCoefficient as recurCoefficient, isa_recurFloatOutput as recurFloatOutput, isa_recurStateWords as recurStateWords, isa_recurSub as recurSub, isa_serviceOf as serviceOf, isa_serviceVersion as serviceVersion, isa_sortKey as sortKey, isa_stageEndingOp as stageEndingOp, isa_stageEnds as stageEnds, isa_xopRange as xopRange };
2356
+ }
2357
+
2358
+ type CastShapeKind = "ball" | "cuboid" | "capsule" | "cylinder";
2359
+ declare class ShapeCastQuery {
2360
+ kind: CastShapeKind;
2361
+ readonly params: Vec3;
2362
+ readonly origin: Vec3;
2363
+ readonly rotation: Float32Array<ArrayBuffer>;
2364
+ readonly direction: Vec3;
2365
+ maxDistance: number;
2366
+ includeSensors: boolean;
2367
+ excludeBody: number;
2368
+ ball(radius: number): this;
2369
+ cuboid(hx: number, hy: number, hz: number): this;
2370
+ capsule(halfHeight: number, radius: number): this;
2371
+ cylinder(halfHeight: number, radius: number): this;
2372
+ }
2373
+ interface SphereOverlap {
2374
+ count: number;
2375
+ collider: number;
2376
+ }
2377
+
2378
+ type KernelExportName = (typeof KERNEL_EXPORT_NAMES)[number];
2379
+ type KernelExports = Readonly<Record<KernelExportName | "engine_alloc" | "engine_free", (...args: number[]) => number>>;
2380
+ type KernelAttach = (binding: number, physics: number, nav: number, flow: number, render: number) => number;
2381
+ type KernelAttachHandle = (binding: number, which: number, handle: number) => number;
2382
+ type KernelSpawns = (binding: number) => number;
2383
+ interface KernelEngine {
2384
+ readonly exports: KernelExports;
2385
+ readonly memory: {
2386
+ readonly buffer: ArrayBufferLike;
2387
+ };
2388
+ readonly isa?: number;
2389
+ readonly attach?: KernelAttach | null;
2390
+ readonly attachHandle?: KernelAttachHandle | null;
2391
+ readonly spawns?: KernelSpawns | null;
2392
+ readonly data?: KernelDataExports | null;
2393
+ readonly runRegion?: KernelRunRegion | null;
2394
+ }
2395
+ type KernelRunRegion = (program: number, columns: number, rows: number, count: number, args: number, argWords: number) => number;
2396
+ interface KernelDataExports {
2397
+ readonly bindTable: (binding: number, which: number, table: number) => number;
2398
+ readonly bindPool: (binding: number, slot: number, pool: number, words: number) => number;
2399
+ readonly report: (binding: number) => number;
2400
+ }
2401
+ declare function bindKernelEngine(symbols: Readonly<Record<string, unknown>>, memory: {
2402
+ readonly buffer: ArrayBufferLike;
2403
+ }): KernelEngine | null;
2404
+
2405
+ declare const CHEMISTRY_EXPORT_NAMES: readonly ["engine_chemistry_open", "engine_chemistry_close", "engine_chemistry_define", "engine_chemistry_find", "engine_chemistry_catalog", "engine_chemistry_text", "engine_chemistry_counts", "engine_chemistry_species_info", "engine_chemistry_reaction_info", "engine_chemistry_grid_open", "engine_chemistry_grid_close", "engine_chemistry_grid_step", "engine_chemistry_grid_paint", "engine_chemistry_grid_set", "engine_chemistry_grid_heat", "engine_chemistry_grid_power", "engine_chemistry_grid_columns", "engine_chemistry_grid_colours", "engine_chemistry_grid_events", "engine_chemistry_grid_clear_events", "engine_chemistry_grid_watch", "engine_chemistry_grid_threshold", "engine_chemistry_grid_unthreshold", "engine_chemistry_grid_fired", "engine_chemistry_grid_stats", "engine_chemistry_grid_probe", "engine_chemistry_grid_save", "engine_chemistry_grid_saved", "engine_chemistry_grid_load", "engine_chemistry_vessel_open", "engine_chemistry_vessel_close", "engine_chemistry_vessel_add", "engine_chemistry_vessel_take", "engine_chemistry_vessel_heat", "engine_chemistry_vessel_power", "engine_chemistry_vessel_step", "engine_chemistry_vessel_vent", "engine_chemistry_vessel_state", "engine_chemistry_particles_open", "engine_chemistry_particles_close", "engine_chemistry_particles_spawn", "engine_chemistry_particles_step", "engine_chemistry_particles_columns", "engine_chemistry_particles_events"];
2406
+ type ChemistryExportName = (typeof CHEMISTRY_EXPORT_NAMES)[number];
2407
+ type ChemistryExports = Readonly<Record<ChemistryExportName | "engine_alloc" | "engine_free", (...args: number[]) => number>>;
2408
+ interface ChemistryEngine {
2409
+ readonly exports: ChemistryExports;
2410
+ readonly memory: {
2411
+ readonly buffer: ArrayBufferLike;
2412
+ };
2413
+ }
2414
+ declare const CHEMISTRY_NATURE_WORDS = 8;
2415
+ declare const CHEMISTRY_BOX_WORDS = 6;
2416
+ declare const CHEMISTRY_SPECIES_WORDS = 16;
2417
+ declare const CHEMISTRY_REACTION_WORDS = 24;
2418
+ declare const CHEMISTRY_COLUMNS = 16;
2419
+ declare const CHEMISTRY_STATS_WORDS = 16;
2420
+ declare const CHEMISTRY_PROBE_WORDS = 16;
2421
+ declare const CHEMISTRY_EVENT_HEADER = 2;
2422
+ declare const CHEMISTRY_EVENT_WORDS = 4;
2423
+ declare const CHEMISTRY_VESSEL_SLOTS = 16;
2424
+ declare const CHEMISTRY_VESSEL_WORDS: number;
2425
+ declare const CHEMISTRY_ATMOSPHERE = 0;
2426
+ declare const CHEMISTRY_VACUUM = 4294967295;
2427
+ declare const CHEMISTRY_REFUSED = 65536;
2428
+ declare const CHEMISTRY_SLOTS = 4;
2429
+ declare const CHEMISTRY_TQ = 16;
2430
+ declare const CHEMISTRY_UNSET = 4294967295;
2431
+ declare function bindChemistryEngine(symbols: Readonly<Record<string, unknown>>, memory: {
2432
+ readonly buffer: ArrayBufferLike;
2433
+ }): ChemistryEngine | null;
2434
+
2435
+ declare const clipMaskBrand: unique symbol;
2436
+ declare const blendSpaceBrand: unique symbol;
2437
+ declare const ikChainBrand: unique symbol;
2438
+ declare const rootMotionBrand: unique symbol;
2439
+ type ClipMaskId = number & {
2440
+ readonly [clipMaskBrand]: true;
2441
+ };
2442
+ type BlendSpaceId = number & {
2443
+ readonly [blendSpaceBrand]: true;
2444
+ };
2445
+ type IkChainId = number & {
2446
+ readonly [ikChainBrand]: true;
2447
+ };
2448
+ type RootMotionId = number & {
2449
+ readonly [rootMotionBrand]: true;
2450
+ };
2451
+ declare const boneSetBrand: unique symbol;
2452
+ type BoneSetId = number & {
2453
+ readonly [boneSetBrand]: true;
2454
+ };
2455
+ type ClipLoop = "once" | "repeat" | "pingpong";
2456
+ type BlendSpaceKind = "1d" | "cartesian" | "directional";
2457
+ type IkSolver = "twoBone" | "lookAt" | "fabrik" | "ccd";
2458
+ type ClipEventKind = "event" | "loop" | "finished";
2459
+ type ClipSyncMode = "phase" | "markers";
2460
+ declare const HUMAN_BONES: readonly ["hips", "spine", "chest", "upperChest", "neck", "head", "leftEye", "rightEye", "jaw", "leftUpperLeg", "leftLowerLeg", "leftFoot", "leftToes", "rightUpperLeg", "rightLowerLeg", "rightFoot", "rightToes", "leftShoulder", "leftUpperArm", "leftLowerArm", "leftHand", "rightShoulder", "rightUpperArm", "rightLowerArm", "rightHand", "leftThumbMetacarpal", "leftThumbProximal", "leftThumbDistal", "leftIndexProximal", "leftIndexIntermediate", "leftIndexDistal", "leftMiddleProximal", "leftMiddleIntermediate", "leftMiddleDistal", "leftRingProximal", "leftRingIntermediate", "leftRingDistal", "leftLittleProximal", "leftLittleIntermediate", "leftLittleDistal", "rightThumbMetacarpal", "rightThumbProximal", "rightThumbDistal", "rightIndexProximal", "rightIndexIntermediate", "rightIndexDistal", "rightMiddleProximal", "rightMiddleIntermediate", "rightMiddleDistal", "rightRingProximal", "rightRingIntermediate", "rightRingDistal", "rightLittleProximal", "rightLittleIntermediate", "rightLittleDistal"];
2461
+ type HumanBone = (typeof HUMAN_BONES)[number];
2462
+ type HumanoidMap = Partial<Record<HumanBone, string>>;
2463
+ interface ClipInfo {
2464
+ readonly duration: number;
2465
+ readonly tracks: number;
2466
+ readonly morphWeights: number;
2467
+ readonly events: number;
2468
+ }
2469
+ interface ClipEventDesc {
2470
+ readonly time: number;
2471
+ readonly id: number;
2472
+ }
2473
+ interface ClipEvent {
2474
+ action: ClipActionId;
2475
+ kind: ClipEventKind;
2476
+ id: number;
2477
+ time: number;
2478
+ }
2479
+ interface ClipActionState {
2480
+ time: number;
2481
+ weight: number;
2482
+ speed: number;
2483
+ running: boolean;
2484
+ paused: boolean;
2485
+ finished: boolean;
2486
+ }
2487
+ interface BlendSpaceMember {
2488
+ readonly action: ClipActionId;
2489
+ readonly x: number;
2490
+ readonly y?: number;
2491
+ }
2492
+ interface BlendSpaceDesc {
2493
+ readonly kind: BlendSpaceKind;
2494
+ readonly members: readonly BlendSpaceMember[];
2495
+ }
2496
+ interface IkDesc {
2497
+ readonly solver: IkSolver;
2498
+ readonly bones: readonly string[];
2499
+ readonly iterations?: number;
2500
+ readonly tolerance?: number;
2501
+ readonly maxAngle?: number;
2502
+ readonly forward?: readonly [number, number, number];
2503
+ }
2504
+ interface RootMotionDesc {
2505
+ readonly bone: string;
2506
+ readonly horizontal?: boolean;
2507
+ readonly vertical?: boolean;
2508
+ readonly yaw?: boolean;
2509
+ readonly apply?: boolean;
2510
+ }
2511
+ declare const propertyClipBrand: unique symbol;
2512
+ type PropertyClipId = number & {
2513
+ readonly [propertyClipBrand]: true;
2514
+ };
2515
+ type TrackInterpolation = "linear" | "step" | "cubic";
2516
+ type PropertyTarget = {
2517
+ readonly kind: "uniform";
2518
+ readonly material: MaterialId;
2519
+ readonly name: string;
2520
+ } | {
2521
+ readonly kind: "light";
2522
+ readonly node: NodeId;
2523
+ readonly color: number;
2524
+ } | {
2525
+ readonly kind: "post";
2526
+ readonly chain: PostChainId;
2527
+ readonly effect: number;
2528
+ readonly name: string;
2529
+ } | {
2530
+ readonly kind: "emitterRate";
2531
+ readonly emitter: EmitterId;
2532
+ };
2533
+ interface PropertyTrackDesc {
2534
+ readonly target: PropertyTarget;
2535
+ readonly size?: number;
2536
+ readonly interpolation?: TrackInterpolation;
2537
+ readonly times: ArrayLike<number>;
2538
+ readonly values: ArrayLike<number>;
2539
+ readonly rest: ArrayLike<number>;
2540
+ }
2541
+ interface PropertyClipDesc {
2542
+ readonly duration: number;
2543
+ readonly tracks: readonly PropertyTrackDesc[];
2544
+ }
2545
+ interface HumanoidMaps {
2546
+ readonly source: HumanoidMap;
2547
+ readonly target: HumanoidMap;
2548
+ }
2549
+ interface BakeRetargetOptions {
2550
+ readonly rate?: number;
2551
+ readonly maps?: HumanoidMaps;
2552
+ }
2553
+ interface ClipAnimationPort {
2554
+ createPropertyClip(desc: PropertyClipDesc): PropertyClipId;
2555
+ playPropertyClip(clip: PropertyClipId, loop: boolean, fadeSeconds: number, speed: number): ClipActionId;
2556
+ setPropertyClipEvents(clip: PropertyClipId, events: readonly ClipEventDesc[]): void;
2557
+ destroyPropertyClip(clip: PropertyClipId): void;
2558
+ setClipTime(action: ClipActionId, seconds: number): void;
2559
+ setClipSpeed(action: ClipActionId, speed: number): void;
2560
+ setClipLoop(action: ClipActionId, loop: ClipLoop, repetitions: number, clampWhenFinished: boolean): void;
2561
+ setClipPaused(action: ClipActionId, paused: boolean): void;
2562
+ setClipRange(action: ClipActionId, start: number, end: number): void;
2563
+ setClipSync(action: ClipActionId, group: number | null): void;
2564
+ setClipSyncMode(action: ClipActionId, mode: ClipSyncMode): void;
2565
+ setClipSyncMarkers(root: NodeId, clip: string, markers: readonly ClipEventDesc[]): void;
2566
+ inertialize(from: ClipActionId, to: ClipActionId, seconds: number): void;
2567
+ bakeRetarget(target: NodeId, source: NodeId, clip: string, options?: BakeRetargetOptions): string;
2568
+ setClipEventsEnabled(action: ClipActionId, enabled: boolean): void;
2569
+ setClipAdditive(action: ClipActionId, referenceTime: number | null): void;
2570
+ crossFade(from: ClipActionId, to: ClipActionId, seconds: number, warp: boolean): void;
2571
+ fadeClip(action: ClipActionId, weight: number, seconds: number): void;
2572
+ fadeClipFrom(action: ClipActionId, values: Float32Array | Float64Array, offset: number): void;
2573
+ createClipMask(root: NodeId, weights: Readonly<Record<string, number>>): ClipMaskId;
2574
+ setClipMask(action: ClipActionId, mask: ClipMaskId | null): void;
2575
+ destroyClipMask(root: NodeId, mask: ClipMaskId): void;
2576
+ setClipEvents(root: NodeId, clip: string, events: readonly ClipEventDesc[]): void;
2577
+ clipInfo(root: NodeId, clip: string): ClipInfo;
2578
+ createBlendSpace(root: NodeId, desc: BlendSpaceDesc): BlendSpaceId;
2579
+ setBlendParameter(space: BlendSpaceId, x: number, y: number, weight: number): void;
2580
+ setBlendParameterFrom(space: BlendSpaceId, values: Float32Array | Float64Array, offset: number): void;
2581
+ destroyBlendSpace(root: NodeId, space: BlendSpaceId): void;
2582
+ createIk(root: NodeId, desc: IkDesc): IkChainId;
2583
+ setIkTarget(chain: IkChainId, x: number, y: number, z: number, weight: number): void;
2584
+ setIkTargetFrom(chain: IkChainId, values: Float32Array | Float64Array, offset: number): void;
2585
+ setIkPole(chain: IkChainId, x: number, y: number, z: number): void;
2586
+ destroyIk(root: NodeId, chain: IkChainId): void;
2587
+ humanoid(root: NodeId): HumanoidMap;
2588
+ retarget(target: NodeId, source: NodeId, maps?: {
2589
+ readonly source: HumanoidMap;
2590
+ readonly target: HumanoidMap;
2591
+ }): void;
2592
+ stopRetarget(target: NodeId): void;
2593
+ setAnimationLod(root: NodeId, interval: number): void;
2594
+ createBoneSet(root: NodeId, bones: readonly string[]): BoneSetId;
2595
+ readBonePoses(set: BoneSetId, out: Float32Array | Float64Array, offset: number): void;
2596
+ destroyBoneSet(set: BoneSetId): void;
2597
+ enableRootMotion(root: NodeId, desc: RootMotionDesc): RootMotionId;
2598
+ disableRootMotion(root: NodeId): void;
2599
+ readRootMotion(motion: RootMotionId, out: Float32Array, offset: number): void;
2600
+ readClipState(action: ClipActionId, out: ClipActionState): void;
2601
+ readClipEvents(out: ClipEvent[]): number;
2602
+ }
2603
+
2604
+ declare const vectorAssetBrand: unique symbol;
2605
+ declare const vectorSurfaceBrand: unique symbol;
2606
+ type VectorAssetId = number & {
2607
+ readonly [vectorAssetBrand]: true;
2608
+ };
2609
+ type VectorSurfaceId = number & {
2610
+ readonly [vectorSurfaceBrand]: true;
2611
+ };
2612
+ type VectorSurfacePhase = "down" | "move" | "up" | "cancel";
2613
+ type VectorSurfacePlay = "machine" | "animation" | "stop";
2614
+ type VectorSurfaceSeek = Exclude<VectorSurfacePlay, "stop">;
2615
+ type VectorSurfaceTier = "low" | "mid" | "high";
2616
+ declare const VECTOR_SURFACE_TIERS: Readonly<Record<VectorSurfaceTier, number>>;
2617
+ declare const VECTOR_SURFACE_CAPS: Readonly<Record<VectorSurfaceTier, number>>;
2618
+ declare const VECTOR_SURFACE_EDGES: Readonly<Record<VectorSurfaceTier, number>>;
2619
+ interface VectorSurfaceDesc {
2620
+ readonly asset: VectorAssetId;
2621
+ readonly artboard?: number;
2622
+ readonly target: RenderTargetId;
2623
+ readonly node?: NodeId | null;
2624
+ }
2625
+ interface VectorSurfaceEvent {
2626
+ surface: VectorSurfaceId;
2627
+ event: number;
2628
+ }
2629
+ interface VectorSurfaceStats {
2630
+ cap: number;
2631
+ live: number;
2632
+ encoded: number;
2633
+ unchanged: number;
2634
+ offscreen: number;
2635
+ occluded: number;
2636
+ overCap: number;
2637
+ droppedEvents: number;
2638
+ }
2639
+ declare function createVectorSurfaceStats(): VectorSurfaceStats;
2640
+ interface VectorSurfacePort {
2641
+ readonly cap: number;
2642
+ load(bytes: Uint8Array): VectorAssetId;
2643
+ unload(asset: VectorAssetId): void;
2644
+ create(desc: VectorSurfaceDesc): VectorSurfaceId;
2645
+ destroy(surface: VectorSurfaceId): void;
2646
+ setNode(surface: VectorSurfaceId, node: NodeId | null): void;
2647
+ play(surface: VectorSurfaceId, kind: VectorSurfacePlay, index: number): void;
2648
+ seek?(surface: VectorSurfaceId, kind: VectorSurfaceSeek, index: number, seconds: number): void;
2649
+ inputIndex(surface: VectorSurfaceId, name: string): number;
2650
+ setInput(surface: VectorSurfaceId, input: number, value: number): void;
2651
+ dataIndex(surface: VectorSurfaceId, path: string): number;
2652
+ setData(surface: VectorSurfaceId, handle: number, kind: "number" | "bool" | "color" | "id" | "fire", value: number): void;
2653
+ pointer(surface: VectorSurfaceId, phase: VectorSurfacePhase, u: number, v: number): boolean;
2654
+ pick(origin: ArrayLike<number>, direction: ArrayLike<number>, far: number, phase: VectorSurfacePhase): VectorSurfaceId | null;
2655
+ events(out: VectorSurfaceEvent[]): number;
2656
+ stats(out: VectorSurfaceStats): void;
2657
+ setTier(tier: VectorSurfaceTier): void;
2658
+ }
2659
+
2660
+ declare const gpuBufferBrand: unique symbol;
2661
+ declare const gpuShaderBrand: unique symbol;
2662
+ declare const gpuPipelineBrand: unique symbol;
2663
+ declare const gpuBindGroupBrand: unique symbol;
2664
+ type GpuBufferId = number & {
2665
+ readonly [gpuBufferBrand]: true;
2666
+ };
2667
+ type GpuShaderId = number & {
2668
+ readonly [gpuShaderBrand]: true;
2669
+ };
2670
+ type GpuPipelineId = number & {
2671
+ readonly [gpuPipelineBrand]: true;
2672
+ };
2673
+ type GpuBindGroupId = number & {
2674
+ readonly [gpuBindGroupBrand]: true;
2675
+ };
2676
+ declare const gpuTextureBrand: unique symbol;
2677
+ declare const gpuSamplerBrand: unique symbol;
2678
+ type GpuTextureId = number & {
2679
+ readonly [gpuTextureBrand]: true;
2680
+ };
2681
+ type GpuSamplerId = number & {
2682
+ readonly [gpuSamplerBrand]: true;
2683
+ };
2684
+ type GpuTextureFormat = "rgba8" | "rgba16f" | "rgba32f";
2685
+ type GpuTextureUsage = "sampled" | "storage" | "target";
2686
+ type GpuSceneTexture = "depth" | "motion" | "color";
2687
+ type GpuTopology = "triangle-list" | "triangle-strip" | "line-list" | "point-list";
2688
+ type GpuBlendFactor = "zero" | "one" | "src" | "one-minus-src" | "src-alpha" | "one-minus-src-alpha" | "dst" | "one-minus-dst" | "dst-alpha" | "one-minus-dst-alpha" | "src-alpha-saturated";
2689
+ interface GpuTextureDesc {
2690
+ readonly width: number;
2691
+ readonly height: number;
2692
+ readonly format: GpuTextureFormat;
2693
+ readonly usage: readonly GpuTextureUsage[];
2694
+ readonly mipLevels?: number;
2695
+ readonly label?: string;
2696
+ }
2697
+ interface GpuSamplerDesc {
2698
+ readonly filter?: "linear" | "nearest";
2699
+ readonly wrap?: "repeat" | "clamp" | "mirror";
2700
+ }
2701
+ interface GpuBlendComponent {
2702
+ readonly src: GpuBlendFactor;
2703
+ readonly dst: GpuBlendFactor;
2704
+ }
2705
+ interface GpuBlend {
2706
+ readonly color: GpuBlendComponent;
2707
+ readonly alpha: GpuBlendComponent;
2708
+ }
2709
+ interface GpuRenderPipelineDesc {
2710
+ readonly shader: GpuShaderId;
2711
+ readonly vertexEntry: string;
2712
+ readonly fragmentEntry: string;
2713
+ readonly targets: readonly GpuTextureFormat[];
2714
+ readonly blend?: GpuBlend;
2715
+ readonly topology?: GpuTopology;
2716
+ readonly label?: string;
2717
+ }
2718
+ interface GpuRect {
2719
+ readonly x: number;
2720
+ readonly y: number;
2721
+ readonly width: number;
2722
+ readonly height: number;
2723
+ }
2724
+ interface GpuDrawOptions {
2725
+ readonly hook?: GpuHook;
2726
+ readonly target?: GpuTextureId | "color";
2727
+ readonly instances?: number;
2728
+ }
2729
+ interface GpuTextureCopy {
2730
+ readonly from?: readonly [number, number];
2731
+ readonly to?: readonly [number, number];
2732
+ readonly size?: readonly [number, number];
2733
+ readonly hook?: GpuHook;
2734
+ }
2735
+ type GpuBufferUsage = "storage" | "uniform" | "vertex" | "index" | "indirect" | "copy_src" | "copy_dst" | "map_read";
2736
+ type GpuHook = "beforeScene" | "afterOpaque" | "afterTransparent" | "post" | "afterPost";
2737
+ type GpuSceneResource = "depth" | "motion" | "color" | "instances" | "particles";
2738
+ interface GpuDispatchOptions {
2739
+ readonly hook?: GpuHook;
2740
+ readonly indirect?: GpuBufferId;
2741
+ }
2742
+ interface GpuBufferDesc {
2743
+ readonly size: number;
2744
+ readonly usage: readonly GpuBufferUsage[];
2745
+ readonly label?: string;
2746
+ }
2747
+ interface GpuComputePipelineDesc {
2748
+ readonly shader: GpuShaderId;
2749
+ readonly entryPoint: string;
2750
+ readonly workgroupSize?: readonly [number, number, number];
2751
+ readonly label?: string;
2752
+ }
2753
+ type GpuBindingDesc = {
2754
+ readonly binding: number;
2755
+ readonly buffer: GpuBufferId | GpuSceneResource;
2756
+ readonly offset?: number;
2757
+ readonly size?: number;
2758
+ } | {
2759
+ readonly binding: number;
2760
+ readonly texture: GpuTextureId | GpuSceneTexture;
2761
+ } | {
2762
+ readonly binding: number;
2763
+ readonly sampler: GpuSamplerId;
2764
+ };
2765
+ interface RawGpu {
2766
+ readonly api: "wgsl" | "webgpu";
2767
+ createBuffer(desc: GpuBufferDesc): GpuBufferId;
2768
+ writeBuffer(buffer: GpuBufferId, offset: number, data: ArrayBufferView): void;
2769
+ createShader(wgsl: string, label?: string): GpuShaderId;
2770
+ createComputePipeline(desc: GpuComputePipelineDesc): GpuPipelineId;
2771
+ createBindGroup(pipeline: GpuPipelineId, group: number, bindings: readonly GpuBindingDesc[]): GpuBindGroupId;
2772
+ dispatch(pipeline: GpuPipelineId, bindGroup: GpuBindGroupId, x: number, y?: number, z?: number, options?: GpuDispatchOptions): void;
2773
+ copyBuffer(source: GpuBufferId, sourceOffset: number, target: GpuBufferId, targetOffset: number, size: number): void;
2774
+ submit(): void;
2775
+ readBuffer(buffer: GpuBufferId, offset: number, out: Uint8Array): Promise<void>;
2776
+ destroyBuffer(buffer: GpuBufferId): void;
2777
+ createTexture(desc: GpuTextureDesc): GpuTextureId;
2778
+ writeTexture(texture: GpuTextureId, data: ArrayBufferView): void;
2779
+ readTexture(texture: GpuTextureId, rect: GpuRect, out: Uint8Array): Promise<void>;
2780
+ copyTexture(source: GpuTextureId, target: GpuTextureId, copy?: GpuTextureCopy): void;
2781
+ destroyTexture(texture: GpuTextureId): void;
2782
+ createSampler(desc?: GpuSamplerDesc): GpuSamplerId;
2783
+ createRenderPipeline(desc: GpuRenderPipelineDesc): GpuPipelineId;
2784
+ draw(pipeline: GpuPipelineId, bindGroup: GpuBindGroupId, vertexCount: number, options?: GpuDrawOptions): void;
2785
+ dispose(): void;
2786
+ }
2787
+
2788
+ interface CurveTable {
2789
+ readonly x: readonly number[];
2790
+ readonly y: readonly number[];
2791
+ }
2792
+ declare function sampleCurve(curve: CurveTable, x: number): number;
2793
+ declare function peakCurve(peakSlip: number, peakValue: number, slideSlip: number, slideValue: number): CurveTable;
2794
+
2795
+ declare const GEAR_AUTO = 100;
2796
+ declare const GEAR_REVERSE = -1;
2797
+ declare const GEAR_NEUTRAL = 0;
2798
+ declare const WHEEL_CENTER = 0;
2799
+ declare const WHEEL_SPIN = 3;
2800
+ declare const WHEEL_STEER = 4;
2801
+ declare const WHEEL_LENGTH = 5;
2802
+ declare const WHEEL_GROUND = 6;
2803
+ declare const WHEEL_POINT = 7;
2804
+ declare const WHEEL_SLIP = 10;
2805
+ declare const WHEEL_SLIP_ANGLE = 11;
2806
+ declare const WHEEL_LOAD = 12;
2807
+ declare const WHEEL_OMEGA = 13;
2808
+ declare const WHEEL_FORCE_LONG = 14;
2809
+ declare const WHEEL_FORCE_LAT = 15;
2810
+ interface WheelDesc {
2811
+ readonly position: readonly [number, number, number];
2812
+ readonly radius: number;
2813
+ readonly inertia?: number;
2814
+ readonly restLength?: number;
2815
+ readonly travel?: number;
2816
+ readonly stiffness?: number;
2817
+ readonly compressionDamping?: number;
2818
+ readonly relaxationDamping?: number;
2819
+ readonly maxSuspensionForce?: number;
2820
+ readonly steer?: number;
2821
+ readonly drive?: number;
2822
+ readonly brakeTorque?: number;
2823
+ readonly handbrakeTorque?: number;
2824
+ readonly longitudinal?: CurveTable;
2825
+ readonly lateral?: CurveTable;
2826
+ readonly grip?: number;
2827
+ readonly axle?: number;
2828
+ readonly side?: number;
2829
+ readonly width?: number;
2830
+ }
2831
+ interface EngineCurveDesc {
2832
+ readonly torque: CurveTable;
2833
+ readonly idleRpm: number;
2834
+ readonly maxRpm: number;
2835
+ readonly engineBraking?: number;
2836
+ readonly inertia?: number;
2837
+ }
2838
+ interface GearboxDesc {
2839
+ readonly ratios: readonly number[];
2840
+ readonly reverse: number;
2841
+ readonly finalDrive: number;
2842
+ readonly efficiency?: number;
2843
+ readonly shiftUpRpm: number;
2844
+ readonly shiftDownRpm: number;
2845
+ readonly shiftSeconds?: number;
2846
+ }
2847
+ interface LeanDesc {
2848
+ readonly maxAngle: number;
2849
+ readonly stiffness: number;
2850
+ readonly damping: number;
2851
+ readonly fullSpeed?: number;
2852
+ }
2853
+ interface VehicleDesc {
2854
+ readonly wheels: readonly WheelDesc[];
2855
+ readonly engine: EngineCurveDesc;
2856
+ readonly gearbox: GearboxDesc;
2857
+ readonly maxSteerRadians: number;
2858
+ readonly steerRate?: number;
2859
+ readonly antiRoll?: number;
2860
+ readonly downforce?: number;
2861
+ readonly drag?: number;
2862
+ readonly rollingResistance?: number;
2863
+ readonly handbrakeGrip?: number;
2864
+ readonly differentialLock?: number;
2865
+ readonly centerLock?: number;
2866
+ readonly skidTorque?: number;
2867
+ readonly forceHeight?: number;
2868
+ readonly ackermann?: number;
2869
+ readonly lean?: LeanDesc;
2870
+ }
2871
+ declare function encodeVehicleDesc(desc: VehicleDesc, out?: Float32Array): Float32Array;
2872
+ interface VehiclePort {
2873
+ createVehicle(body: number, desc: Float32Array): number;
2874
+ destroyVehicle(vehicle: number): void;
2875
+ vehicleInputs(): Float32Array;
2876
+ vehicleStates(): Float32Array;
2877
+ }
2878
+ declare class Vehicle {
2879
+ readonly id: number;
2880
+ readonly entity: number;
2881
+ readonly wheelCount: number;
2882
+ private readonly port;
2883
+ private inputs;
2884
+ private states;
2885
+ private readonly input;
2886
+ private readonly state;
2887
+ constructor(port: VehiclePort, id: number, entity: number, wheelCount: number);
2888
+ refresh(): void;
2889
+ drive(throttle: number, brake: number, steer: number, handbrake?: number, gear?: number): void;
2890
+ driveFrom(source: Float64Array | Float32Array, at: number): void;
2891
+ get speed(): number;
2892
+ get rpm(): number;
2893
+ get gear(): number;
2894
+ get steer(): number;
2895
+ get groundedWheels(): number;
2896
+ get shifting(): boolean;
2897
+ wheel(index: number, field: number): number;
2898
+ get stateView(): Float32Array;
2899
+ get stateOffset(): number;
2900
+ }
2901
+
2902
+ declare const MAX_COLLIDER_CLASSES = 16;
2903
+ declare const DEFAULT_COLLIDER_CLASS = 0;
2904
+ interface ContactRuleDesc {
2905
+ readonly ignore?: boolean;
2906
+ readonly friction?: number;
2907
+ readonly restitution?: number;
2908
+ readonly oneWay?: readonly [number, number, number];
2909
+ }
2910
+ declare const NO_CONTACT_RULE: ContactRuleDesc;
2911
+ declare class ContactRuleTable {
2912
+ readonly flags: Uint8Array<ArrayBuffer>;
2913
+ readonly friction: Float32Array<ArrayBuffer>;
2914
+ readonly restitution: Float32Array<ArrayBuffer>;
2915
+ readonly normal: Float32Array<ArrayBuffer>;
2916
+ private active;
2917
+ get count(): number;
2918
+ set(platform: number, other: number, rule: ContactRuleDesc): void;
2919
+ index(a: number, b: number): number;
2920
+ private write;
2921
+ }
2922
+
2923
+ type SeaState = "mirror" | "lake" | "calm" | "moderate" | "rough" | "storm";
2924
+ declare const SEA_STATES: readonly SeaState[];
2925
+ interface WaveDesc {
2926
+ readonly direction: readonly [number, number];
2927
+ readonly wavelength: number;
2928
+ readonly amplitude: number;
2929
+ readonly steepness: number;
2930
+ readonly phase: number;
2931
+ }
2932
+ interface WaterDesc {
2933
+ readonly level?: number;
2934
+ readonly depth?: number;
2935
+ readonly gravity?: number;
2936
+ readonly density?: number;
2937
+ readonly current?: readonly [number, number];
2938
+ readonly wind?: readonly [number, number];
2939
+ readonly gust?: number;
2940
+ readonly gustPeriod?: number;
2941
+ readonly iterations?: number;
2942
+ readonly waves?: readonly WaveDesc[];
2943
+ }
2944
+ declare class WaterSample {
2945
+ height: number;
2946
+ normalX: number;
2947
+ normalY: number;
2948
+ normalZ: number;
2949
+ velocityX: number;
2950
+ velocityY: number;
2951
+ velocityZ: number;
2952
+ }
2953
+ declare function seaDesc(state: SeaState, windRadians: number, seed: number): WaterDesc;
2954
+ declare class Water {
2955
+ private readonly kx;
2956
+ private readonly kz;
2957
+ private readonly phase;
2958
+ private readonly amplitude;
2959
+ private readonly qax;
2960
+ private readonly qaz;
2961
+ private readonly kax;
2962
+ private readonly kaz;
2963
+ private readonly kqa;
2964
+ private readonly wqax;
2965
+ private readonly wqaz;
2966
+ private readonly wa;
2967
+ private readonly omega;
2968
+ private readonly sc;
2969
+ private readonly seconds;
2970
+ private count;
2971
+ private iterations;
2972
+ private currentX;
2973
+ private currentZ;
2974
+ private windX;
2975
+ private windZ;
2976
+ private gust;
2977
+ private gustOmega;
2978
+ private gustPhase;
2979
+ private time;
2980
+ level: number;
2981
+ density: number;
2982
+ gravity: number;
2983
+ constructor(desc?: WaterDesc);
2984
+ configure(desc: WaterDesc): void;
2985
+ setWind(x: number, z: number, gust?: number, gustPeriod?: number): void;
2986
+ setCurrent(x: number, z: number): void;
2987
+ crest(): number;
2988
+ get elapsed(): number;
2989
+ advance(dt: number): void;
2990
+ advanceFrom(values: Float64Array, at: number): void;
2991
+ windInto(out: Float64Array, at?: number): Float64Array;
2992
+ height(x: number, z: number): number;
2993
+ sample(x: number, z: number, out: WaterSample): WaterSample;
2994
+ sampleBatch(points: Float32Array, count: number, out: Float32Array): void;
2995
+ private readonly batchSample;
2996
+ private px;
2997
+ private pz;
2998
+ private theta;
2999
+ private undisplace;
3000
+ }
3001
+
3002
+ interface WaterFlow {
3003
+ readonly level: number;
3004
+ readonly current: readonly [number, number];
3005
+ readonly wind: readonly [number, number];
3006
+ readonly gust: number;
3007
+ readonly gustPeriod: number;
3008
+ }
3009
+ interface OceanDesc {
3010
+ readonly size?: number;
3011
+ readonly patch?: number;
3012
+ readonly wind?: readonly [number, number];
3013
+ readonly amplitude?: number;
3014
+ readonly choppiness?: number;
3015
+ readonly smallWave?: number;
3016
+ readonly seed?: number;
3017
+ readonly updateEvery?: number;
3018
+ }
3019
+ /** Ripples and wakes over the water: a window of `size` cells (a power of two, 16 to 256) of
3020
+ * `cell` metres that follows the camera or a boat, whose waves run at `speed` m/s. */
3021
+ interface RippleOptions {
3022
+ readonly size?: number;
3023
+ readonly cell?: number;
3024
+ readonly speed?: number;
3025
+ }
3026
+ /** The FFT ocean, drawn and floated on as one: a JONSWAP spectrum over up to four cascades
3027
+ * of `size` texels, the coarsest `patches[0]` metres across. */
3028
+ interface OceanCascades {
3029
+ readonly size?: number;
3030
+ readonly count?: number;
3031
+ readonly patches?: readonly [number, number, number, number];
3032
+ readonly windSpeed?: number;
3033
+ readonly windDirection?: number;
3034
+ readonly fetch?: number;
3035
+ readonly peakEnhancement?: number;
3036
+ readonly swell?: number;
3037
+ readonly depth?: number;
3038
+ readonly shortWaves?: number;
3039
+ readonly scale?: number;
3040
+ readonly choppiness?: number;
3041
+ readonly foam?: {
3042
+ readonly threshold?: number;
3043
+ readonly gain?: number;
3044
+ readonly decaySeconds?: number;
3045
+ };
3046
+ readonly gravity?: number;
3047
+ readonly seed?: number;
3048
+ /** The CPU instance hulls float on: the same waves at this size, 64 by default. */
3049
+ readonly physicsSize?: number;
3050
+ }
3051
+ /** Puddles and streams: `width` by `height` cells of `cell` metres from world `origin`
3052
+ * (x, z), deep enough for `maxDepth` metres. */
3053
+ interface PuddleOptions {
3054
+ readonly origin: readonly [number, number];
3055
+ readonly cell: number;
3056
+ readonly width: number;
3057
+ readonly height: number;
3058
+ readonly maxDepth?: number;
3059
+ }
3060
+ interface CraftPort {
3061
+ setOcean(desc: OceanDesc | null): void;
3062
+ setCascades?(desc: OceanCascades | null): void;
3063
+ setPuddles?(desc: PuddleOptions | null): void;
3064
+ setPuddleBed?(heights: Float32Array): void;
3065
+ pourPuddles?(x: number, z: number, volume: number): void;
3066
+ puddleWeather?(rain: number, evaporation: number): void;
3067
+ setRipples?(desc: RippleOptions | null): void;
3068
+ followRipples?(x: number, z: number): void;
3069
+ pushRipples?(x: number, z: number, amount: number): void;
3070
+ bindRender?(source: () => number): void;
3071
+ readonly name: string;
3072
+ readonly capacity: number;
3073
+ configureWater(desc: WaterDesc): void;
3074
+ sea(state: SeaState, windRadians: number, seed: number): void;
3075
+ setFlow(flow: WaterFlow): void;
3076
+ createCraft(entity: number, body: number, collider: number, words: Float32Array, running: boolean): number;
3077
+ removeCraft(craft: number): void;
3078
+ controls(): Float32Array;
3079
+ telemetry(): Float32Array;
3080
+ step(): void;
3081
+ sampleWater(points: Float32Array, count: number, out: Float32Array): void;
3082
+ crumple?(craft: number, vertices: Float32Array, desc: Float32Array | null): void;
3083
+ impact?(craft: number, point: readonly [number, number, number], severity: readonly [number, number, number]): boolean;
3084
+ damage?(craft: number): number;
3085
+ presentCrumple?(craft: number, geometry: number): number;
3086
+ dispose(): void;
3087
+ }
3088
+
3089
+ declare const JOINT_AXES: {
3090
+ readonly linX: 0;
3091
+ readonly linY: 1;
3092
+ readonly linZ: 2;
3093
+ readonly angX: 3;
3094
+ readonly angY: 4;
3095
+ readonly angZ: 5;
3096
+ };
3097
+ type JointAxisName = keyof typeof JOINT_AXES;
3098
+ declare const POSE_STRIDE = 10;
3099
+ interface JointDrive {
3100
+ readonly targetPosition?: number;
3101
+ readonly targetVelocity?: number;
3102
+ readonly stiffness: number;
3103
+ readonly damping: number;
3104
+ readonly maxForce?: number;
3105
+ }
3106
+ interface JointLoad {
3107
+ force: number;
3108
+ torque: number;
3109
+ }
3110
+ interface RagdollBoneDesc {
3111
+ readonly joint: number;
3112
+ readonly axis?: readonly [number, number, number];
3113
+ readonly length: number;
3114
+ readonly radius: number;
3115
+ readonly density?: number;
3116
+ readonly swing?: number;
3117
+ readonly twist?: readonly [number, number];
3118
+ readonly entity?: number;
3119
+ }
3120
+ interface RagdollRoot {
3121
+ readonly position?: readonly [number, number, number];
3122
+ readonly rotation?: readonly [number, number, number, number];
3123
+ readonly scale?: readonly [number, number, number];
3124
+ }
3125
+ interface RagdollDesc {
3126
+ readonly parents: readonly number[];
3127
+ readonly pose: Float32Array;
3128
+ readonly bones: readonly RagdollBoneDesc[];
3129
+ readonly root?: RagdollRoot;
3130
+ readonly linearDamping?: number;
3131
+ readonly angularDamping?: number;
3132
+ readonly friction?: number;
3133
+ }
3134
+ interface RagdollDrive {
3135
+ readonly stiffness: number;
3136
+ readonly damping: number;
3137
+ readonly maxTorque: number;
3138
+ }
3139
+ interface Ragdoll {
3140
+ readonly id: number;
3141
+ readonly pose: Float32Array;
3142
+ readonly bodies: Uint32Array;
3143
+ drive(drive: RagdollDrive): void;
3144
+ place(): void;
3145
+ read(): Float32Array;
3146
+ setRoot(root: RagdollRoot): void;
3147
+ destroy(): void;
3148
+ }
3149
+ interface JointPort {
3150
+ setDrive(joint: number, axis: JointAxisName, drive: JointDrive): void;
3151
+ clearDrive(joint: number, axis: JointAxisName): void;
3152
+ setTarget(joint: number, rotation: readonly [number, number, number, number], drive: RagdollDrive): void;
3153
+ setBreakable(joint: number, force: number, torque: number): void;
3154
+ setEnabled(joint: number, enabled: boolean): void;
3155
+ setContacts(joint: number, enabled: boolean): void;
3156
+ broken(joint: number): boolean;
3157
+ load(joint: number, out: JointLoad): void;
3158
+ breaks(): Uint32Array;
3159
+ createRagdoll(desc: RagdollDesc): Ragdoll;
3160
+ }
3161
+
3162
+ declare const AI_EVENT_WORDS = 5;
3163
+ declare const AI_NONE = 4294967295;
3164
+ declare const AI_MAX_GAME_SLOTS = 16;
3165
+ declare const BUILTIN_INPUTS: readonly ["focus_distance", "focus_visible", "focus_since_seen", "focus_confidence", "focus_threat", "hostiles_known", "allies_near", "attack_token_free", "action_seconds", "goal_distance", "lateness", "best_object"];
3166
+ type BuiltinInput = (typeof BUILTIN_INPUTS)[number];
3167
+ declare const PHASE_IDLE = 0;
3168
+ declare const PHASE_WINDUP = 1;
3169
+ declare const PHASE_STRIKE = 2;
3170
+ declare const PHASE_RECOVER = 3;
3171
+ declare const AiEventKind: {
3172
+ readonly actionChanged: 1;
3173
+ readonly focusAcquired: 2;
3174
+ readonly focusLost: 3;
3175
+ readonly heard: 4;
3176
+ readonly arrived: 5;
3177
+ readonly attackWindup: 6;
3178
+ readonly attackStrike: 7;
3179
+ readonly attackDone: 8;
3180
+ readonly bark: 9;
3181
+ readonly objectUsed: 10;
3182
+ readonly coverTaken: 11;
3183
+ };
3184
+ type AiEventKindCode = (typeof AiEventKind)[keyof typeof AiEventKind];
3185
+ type CurveDecl = {
3186
+ readonly kind: "linear";
3187
+ readonly slope: number;
3188
+ readonly offset: number;
3189
+ } | {
3190
+ readonly kind: "polynomial";
3191
+ readonly exponent: number;
3192
+ readonly slope: number;
3193
+ readonly offset: number;
3194
+ } | {
3195
+ readonly kind: "logistic";
3196
+ readonly steepness: number;
3197
+ readonly midpoint: number;
3198
+ } | {
3199
+ readonly kind: "step";
3200
+ readonly threshold: number;
3201
+ readonly below: number;
3202
+ readonly above: number;
3203
+ } | {
3204
+ readonly kind: "points";
3205
+ readonly x: readonly number[];
3206
+ readonly y: readonly number[];
3207
+ };
3208
+ type InputSourceDecl = {
3209
+ readonly kind: "builtin";
3210
+ readonly input: BuiltinInput;
3211
+ } | {
3212
+ readonly kind: "game";
3213
+ readonly slot: number;
3214
+ } | {
3215
+ readonly kind: "need";
3216
+ readonly need: number;
3217
+ };
3218
+ interface InputDecl {
3219
+ readonly source: InputSourceDecl;
3220
+ readonly min: number;
3221
+ readonly max: number;
3222
+ }
3223
+ interface ConsiderationDecl {
3224
+ readonly input: string;
3225
+ readonly curve: CurveDecl;
3226
+ }
3227
+ type BehaviourDecl = {
3228
+ readonly kind: "idle";
3229
+ } | {
3230
+ readonly kind: "move_to_focus";
3231
+ readonly arriveRadius: number;
3232
+ } | {
3233
+ readonly kind: "pursue";
3234
+ readonly leadSeconds: number;
3235
+ readonly arriveRadius: number;
3236
+ } | {
3237
+ readonly kind: "flee";
3238
+ readonly safeDistance: number;
3239
+ } | {
3240
+ readonly kind: "keep_distance";
3241
+ readonly min: number;
3242
+ readonly max: number;
3243
+ } | {
3244
+ readonly kind: "search";
3245
+ readonly arriveRadius: number;
3246
+ } | {
3247
+ readonly kind: "wander";
3248
+ } | {
3249
+ readonly kind: "move_to_goal";
3250
+ readonly arriveRadius: number;
3251
+ } | {
3252
+ readonly kind: "attack";
3253
+ readonly range: number;
3254
+ readonly windupTicks: number;
3255
+ readonly strikeTicks: number;
3256
+ readonly recoverTicks: number;
3257
+ } | {
3258
+ readonly kind: "take_cover";
3259
+ readonly maxDistance: number;
3260
+ } | {
3261
+ readonly kind: "hold_formation";
3262
+ readonly arriveRadius: number;
3263
+ } | {
3264
+ readonly kind: "use_object";
3265
+ readonly kinds: readonly number[];
3266
+ readonly maxDistance: number;
3267
+ } | {
3268
+ readonly kind: "follow_schedule";
3269
+ readonly arriveRadius: number;
3270
+ } | {
3271
+ readonly kind: "bark";
3272
+ readonly lineSet: number;
3273
+ } | {
3274
+ readonly kind: "game";
3275
+ readonly code: number;
3276
+ };
3277
+ interface ActionDecl {
3278
+ readonly name: string;
3279
+ readonly base: number;
3280
+ readonly momentum: number;
3281
+ readonly cooldownTicks: number;
3282
+ readonly speed: number;
3283
+ readonly considerations: readonly ConsiderationDecl[];
3284
+ readonly behaviour: BehaviourDecl;
3285
+ }
3286
+ interface SightDecl {
3287
+ readonly range: number;
3288
+ readonly fovCos: number;
3289
+ readonly peripheralRange: number;
3290
+ readonly peripheralCos: number;
3291
+ readonly eyeHeight: number;
3292
+ readonly lineOfSight: boolean;
3293
+ }
3294
+ interface SteeringDecl {
3295
+ readonly maxSpeed: number;
3296
+ readonly maxAcceleration: number;
3297
+ readonly radius: number;
3298
+ readonly separationWeight: number;
3299
+ readonly separationRadius: number;
3300
+ readonly motion: "kinematic" | "external" | "crowd";
3301
+ }
3302
+ type SkillPair = readonly [atSkill0: number, atSkill1: number];
3303
+ interface SkillDecl {
3304
+ readonly reactionSeconds: SkillPair;
3305
+ readonly aimSigma: SkillPair;
3306
+ readonly perceptionScale: SkillPair;
3307
+ readonly tolerance: SkillPair;
3308
+ readonly mistakeChance: SkillPair;
3309
+ }
3310
+ interface NeedDecl {
3311
+ readonly name: string;
3312
+ readonly decayPerMinute: number;
3313
+ readonly initial: number;
3314
+ readonly urgency: CurveDecl;
3315
+ }
3316
+ interface ScheduleBlockDecl {
3317
+ readonly startMinute: number;
3318
+ readonly endMinute: number;
3319
+ readonly activity: number;
3320
+ readonly place: readonly [number, number, number];
3321
+ readonly radius: number;
3322
+ }
3323
+ interface ArchetypeDecl {
3324
+ readonly name: string;
3325
+ readonly thinkEveryTicks: number;
3326
+ readonly senseEveryTicks: number;
3327
+ readonly inputs: Readonly<Record<string, InputDecl>>;
3328
+ readonly actions: readonly ActionDecl[];
3329
+ readonly sight: SightDecl | null;
3330
+ readonly hearing: {
3331
+ readonly sensitivity: number;
3332
+ } | null;
3333
+ readonly memorySeconds: number;
3334
+ readonly awarenessRadius: number;
3335
+ readonly steering: SteeringDecl;
3336
+ readonly skill: SkillDecl;
3337
+ readonly needs: readonly NeedDecl[];
3338
+ readonly schedule: readonly ScheduleBlockDecl[];
3339
+ readonly scheduleJitterMinutes: number;
3340
+ }
3341
+ interface AiWorldOptions {
3342
+ readonly maxAgents: number;
3343
+ readonly maxTargets?: number;
3344
+ readonly maxSquads?: number;
3345
+ readonly maxObjects?: number;
3346
+ readonly maxCover?: number;
3347
+ readonly memorySlots?: number;
3348
+ readonly sightRaysPerTick?: number;
3349
+ readonly eventCapacity?: number;
3350
+ readonly tickHz?: number;
3351
+ readonly seed?: number;
3352
+ readonly attackTokens?: number;
3353
+ readonly gridCell?: number;
3354
+ readonly minutesPerTick?: number;
3355
+ readonly startMinute?: number;
3356
+ }
3357
+ declare const ENGINE_AI_EXPORT_NAMES: readonly ["engine_ai_create", "engine_ai_destroy", "engine_ai_registers", "engine_ai_view", "engine_ai_slots", "engine_ai_archetype", "engine_ai_spawn", "engine_ai_despawn", "engine_ai_target_add", "engine_ai_target_remove", "engine_ai_target_move", "engine_ai_target_threat", "engine_ai_agent_target", "engine_ai_noise", "engine_ai_goal", "engine_ai_focus", "engine_ai_skill", "engine_ai_need", "engine_ai_speed", "engine_ai_place", "engine_ai_step", "engine_ai_events", "engine_ai_doing", "engine_ai_aim", "engine_ai_digest", "engine_ai_squad", "engine_ai_join", "engine_ai_leave", "engine_ai_object_add", "engine_ai_object_remove", "engine_ai_cover_add", "engine_ai_cover_remove"];
3358
+ type AiExportName = (typeof ENGINE_AI_EXPORT_NAMES)[number];
3359
+ type AiExports = Readonly<Record<AiExportName, (...args: number[]) => number>>;
3360
+ interface AiPort {
3361
+ readonly name: string;
3362
+ readonly exports: AiExports;
3363
+ step(ai: number): number;
3364
+ buffer(): ArrayBufferLike;
3365
+ alloc(bytes: number, align: number): number;
3366
+ free(pointer: number, bytes: number, align: number): void;
3367
+ }
3368
+
3369
+ declare const FLUID_CAP_SIMULATION = 1;
3370
+ declare const FLUID_CAP_SURFACE = 2;
3371
+ /** A signed distance volume a fluid holds, baked from a mesh; kind 3 colliders name it. */
3372
+ interface FluidVolume {
3373
+ readonly index: number;
3374
+ /** Where the volume's centre sits in the mesh's own frame. */
3375
+ readonly centre: readonly [number, number, number];
3376
+ readonly half: readonly [number, number, number];
3377
+ }
3378
+ interface FluidPort {
3379
+ readonly caps: number;
3380
+ create(desc: Float32Array, surface: Float32Array): number;
3381
+ destroy(fluid: number): void;
3382
+ parameters(fluid: number, desc: Float32Array): void;
3383
+ surface(fluid: number, surface: Float32Array): void;
3384
+ emitter(fluid: number, index: number, emitter: Float32Array): void;
3385
+ colliders(fluid: number, colliders: Float32Array, count: number): void;
3386
+ step(fluid: number, seconds: number): void;
3387
+ pause(fluid: number, paused: boolean): void;
3388
+ clear(fluid: number): void;
3389
+ count(fluid: number): number;
3390
+ forces(fluid: number, out: Float32Array): void;
3391
+ volume(fluid: number, positions: Float32Array, indices: Uint32Array, resolution: number, padding: number): FluidVolume;
3392
+ clearVolumes(fluid: number): void;
3393
+ }
3394
+
3395
+ interface FractureMesh {
3396
+ readonly positions: Float32Array;
3397
+ readonly normals?: Float32Array;
3398
+ readonly uvs?: Float32Array;
3399
+ readonly indices: Uint32Array;
3400
+ }
3401
+ interface FractureOptions {
3402
+ readonly pieces: number;
3403
+ readonly seed?: number;
3404
+ readonly impact?: readonly [number, number, number];
3405
+ readonly focus?: number;
3406
+ readonly interiorUvScale?: number;
3407
+ readonly anchorHeight?: number;
3408
+ }
3409
+ interface FracturePiece {
3410
+ readonly centroid: readonly [number, number, number];
3411
+ readonly positions: Float32Array;
3412
+ readonly normals: Float32Array;
3413
+ readonly uvs: Float32Array;
3414
+ readonly indices: Uint32Array;
3415
+ readonly interiorStart: number;
3416
+ }
3417
+ interface FractureResult {
3418
+ readonly asset: Uint8Array;
3419
+ readonly model: Uint8Array;
3420
+ readonly pieces: readonly FracturePiece[];
3421
+ }
3422
+
3423
+ interface DestructionEvents {
3424
+ readonly words: Uint32Array;
3425
+ readonly floats: Float32Array;
3426
+ readonly offset: number;
3427
+ readonly count: number;
3428
+ }
3429
+ interface StructureDesc {
3430
+ readonly bondStrength: number;
3431
+ readonly propagation?: number;
3432
+ readonly stress?: boolean;
3433
+ readonly clusters?: boolean;
3434
+ readonly levels?: number;
3435
+ readonly levelStrength?: number;
3436
+ }
3437
+ interface DestructionPort {
3438
+ create(asset: Uint8Array, entities: Uint32Array, intact: number, desc: Float32Array): number;
3439
+ destroy(destructible: number): void;
3440
+ damage(destructible: number, x: number, y: number, z: number, radius: number, amount: number): number;
3441
+ configure?(destructible: number, structure: StructureDesc): void;
3442
+ attached(destructible: number): number;
3443
+ update(seconds: number): DestructionEvents;
3444
+ fracture?(mesh: FractureMesh, options: FractureOptions): FractureResult;
3445
+ dispose(): void;
3446
+ }
3447
+
3448
+ declare const SOFT_BODY_FEATURE = "soft_body_1";
3449
+ interface SoftBodyInfo {
3450
+ readonly id: number;
3451
+ readonly particles: number;
3452
+ readonly skinned: number;
3453
+ readonly tets: number;
3454
+ readonly colours: number;
3455
+ }
3456
+ interface SoftLattice {
3457
+ readonly cells: readonly [number, number, number];
3458
+ readonly size: readonly [number, number, number];
3459
+ readonly origin: readonly [number, number, number];
3460
+ readonly density: number;
3461
+ }
3462
+ interface SoftBodyPort {
3463
+ readonly registers: Uint32Array;
3464
+ readonly floats: Float32Array;
3465
+ prepare(): Float32Array;
3466
+ lattice(lattice: SoftLattice, vertices: Float32Array | null): SoftBodyInfo;
3467
+ rope(points: Float32Array, mass: number, pinFirst: boolean): SoftBodyInfo;
3468
+ asset(bytes: Uint8Array): SoftBodyInfo;
3469
+ remove(id: number): void;
3470
+ params(id: number): void;
3471
+ colliders(words: Float32Array, count: number): void;
3472
+ anchors(id: number, anchors: Float32Array): void;
3473
+ activate(id: number, activation: number): void;
3474
+ move(id: number, offset: readonly [number, number, number], velocity: readonly [number, number, number]): void;
3475
+ step(seconds: number): void;
3476
+ positions(id: number, count: number): Float32Array;
3477
+ digest(): bigint;
3478
+ present(id: number, geometry: number): number;
3479
+ couple?(collider: number): number;
3480
+ uncouple?(slot: number): void;
3481
+ dispose(): void;
3482
+ }
3483
+
3484
+ declare const mediumBrand: unique symbol;
3485
+ type MediumId = number & {
3486
+ readonly [mediumBrand]: true;
3487
+ };
3488
+ interface MediumDesc {
3489
+ readonly origin: Vec3Like;
3490
+ readonly extent: Vec3Like;
3491
+ readonly size: readonly [number, number, number];
3492
+ readonly emission?: number;
3493
+ readonly extinction?: number;
3494
+ readonly albedo?: readonly [number, number, number];
3495
+ }
3496
+ interface MediumPort {
3497
+ createMedium?(desc: MediumDesc): MediumId;
3498
+ setMedium?(medium: MediumId, desc: MediumDesc): void;
3499
+ mediumTexels?(medium: MediumId): Uint32Array;
3500
+ markMedium?(medium: MediumId): void;
3501
+ destroyMedium?(medium: MediumId): void;
3502
+ }
3503
+ declare const MEDIUM_DEFAULTS: {
3504
+ readonly emission: 1;
3505
+ readonly extinction: 1;
3506
+ readonly albedo: readonly [0.5, 0.5, 0.5];
3507
+ };
3508
+ declare const MEDIUM_MAX = 16;
3509
+ declare const MEDIUM_MAX_EDGE = 64;
3510
+ declare function mediumTexel(r: number, g: number, b: number, a: number): number;
3511
+ declare function mediumTexelCount(size: readonly [number, number, number]): number;
3512
+ declare function mediumIndex(size: readonly [number, number, number], x: number, y: number, z: number): number;
3513
+ declare class MediumVolume {
3514
+ private readonly port;
3515
+ readonly id: MediumId;
3516
+ private desc;
3517
+ private disposed;
3518
+ constructor(port: Required<MediumPort>, id: MediumId, desc: MediumDesc);
3519
+ get size(): readonly [number, number, number];
3520
+ get texels(): Uint32Array;
3521
+ index(x: number, y: number, z: number): number;
3522
+ set(desc: MediumDesc): void;
3523
+ mark(): void;
3524
+ dispose(): void;
3525
+ }
3526
+
3527
+ declare const REACTIVE_FEATURE = "reactive_fluid_1";
3528
+ interface ReactivePort {
3529
+ open(chemistry: number, fluid: Float32Array, desc: Uint32Array): number;
3530
+ registers(reactive: number): Uint32Array;
3531
+ hob(reactive: number, desc: Uint32Array): void;
3532
+ lit(reactive: number, on: boolean): void;
3533
+ emitter(reactive: number, index: number, emitter: Float32Array): void;
3534
+ preheat(reactive: number, targetK: number, maxTicks: number): number;
3535
+ step(reactive: number, seconds: number, tick: boolean): void;
3536
+ media(reactive: number, medium: number): number;
3537
+ texels(reactive: number, count: number): Uint32Array;
3538
+ positions(reactive: number, count: number): Float32Array;
3539
+ digest(reactive: number): bigint;
3540
+ close(reactive: number): void;
3541
+ }
3542
+
3543
+ declare const CLOTH_FEATURE = "cloth_1";
3544
+ interface ClothInfo {
3545
+ readonly id: number;
3546
+ readonly particles: number;
3547
+ readonly triangles: number;
3548
+ readonly pins: number;
3549
+ readonly colours: number;
3550
+ }
3551
+ interface ClothPort {
3552
+ readonly engineHost?: number;
3553
+ readonly registers: Uint32Array;
3554
+ readonly floats: Float32Array;
3555
+ prepare(): Float32Array;
3556
+ grid(pins: Uint32Array | null): ClothInfo;
3557
+ mesh(positions: Float32Array, triangles: Uint32Array, pins: Uint32Array | null): ClothInfo;
3558
+ remove(id: number): void;
3559
+ params(id: number): void;
3560
+ colliders(words: Float32Array, count: number): void;
3561
+ anchors(id: number, anchors: Float32Array): void;
3562
+ step(seconds: number): void;
3563
+ positions(id: number, count: number): Float32Array;
3564
+ digest(): bigint;
3565
+ present(id: number, geometry: number): number;
3566
+ couple?(collider: number): number;
3567
+ uncouple?(slot: number): void;
3568
+ dispose(): void;
3569
+ }
3570
+
3571
+ interface SmokePort {
3572
+ create(desc: Float32Array, medium: number): number;
3573
+ emitters(smoke: number, floats: Float32Array, count: number): void;
3574
+ follow?(smoke: number, x: number, y: number, z: number): void;
3575
+ step(smoke: number, seconds: number): number;
3576
+ destroy(smoke: number): void;
3577
+ }
3578
+
3579
+ interface StoryPort {
3580
+ create(program: Uint8Array): number;
3581
+ destroy(story: number): void;
3582
+ start(story: number): void;
3583
+ step(story: number, inputs: Uint32Array, count: number): void;
3584
+ seek(story: number, tick: number): void;
3585
+ available(story: number, choice: number): boolean;
3586
+ variable(story: number, variable: number): number;
3587
+ get(story: number, variable: number): number;
3588
+ set(story: number, variable: number, value: number): void;
3589
+ setText(story: number, variable: number, text: string): void;
3590
+ variableText(story: number, variable: number): string;
3591
+ programText(story: number, index: number): string;
3592
+ textIndex(story: number, text: string): number;
3593
+ textOf(story: number, what: number, index: number, key: number): number;
3594
+ idOf(story: number, what: number, index: number): string | null;
3595
+ buffer(): ArrayBufferLike;
3596
+ views(story: number): StoryViews;
3597
+ }
3598
+ interface StoryViews {
3599
+ readonly registers: Uint32Array;
3600
+ readonly events: Uint32Array;
3601
+ readonly samples: Float64Array;
3602
+ }
3603
+
3604
+ interface GraphicsPort extends MediumPort {
3605
+ readonly capabilities: GraphicsCapabilities;
3606
+ readonly gpu: RawGpu | null;
3607
+ attach(surface: GameSurface | null): Promise<void>;
3608
+ resize(width: number, height: number, pixelRatio: number): void;
3609
+ createGeometry(desc: GeometryDesc): GeometryId;
3610
+ geometryAttribute(geometry: GeometryId, name: string): VertexData;
3611
+ markGeometryDirty(geometry: GeometryId, name: string, start: number, count: number): void;
3612
+ setDrawRange(geometry: GeometryId, start: number, count: number): void;
3613
+ destroyGeometry(geometry: GeometryId): void;
3614
+ createTexture(desc: TextureDesc): TextureId;
3615
+ loadTexture(source: AssetSource): Promise<TextureId>;
3616
+ upgradeTexture?(texture: TextureId, source: AssetSource): Promise<TextureUpgrade>;
3617
+ markTextureDirty(texture: TextureId, region?: TextureRegion): void;
3618
+ pushVideoFrame?(texture: TextureId, frame: VideoFrameSource, width: number, height: number): boolean;
3619
+ readRenderTarget?(target: RenderTargetId, rect: readonly [number, number, number, number], slice?: number): Promise<Uint8Array>;
3620
+ destroyTexture(texture: TextureId): void;
3621
+ createMaterial(desc: MaterialDesc): MaterialId;
3622
+ setMaterialColor(material: MaterialId, r: number, g: number, b: number): void;
3623
+ setMaterialOpacity(material: MaterialId, opacity: number): void;
3624
+ setMaterialTexture(material: MaterialId, slot: MaterialTextureSlot, texture: TextureId | null): void;
3625
+ setMaterialScalar(material: MaterialId, uniform: string, value: number): void;
3626
+ setMaterialVector(material: MaterialId, uniform: string, value: Float32Array): void;
3627
+ setMaterialUniformTexture(material: MaterialId, uniform: string, texture: TextureId): void;
3628
+ setMaterialState(material: MaterialId, state: MaterialStateDesc): void;
3629
+ destroyMaterial(material: MaterialId): void;
3630
+ createEmitter(desc: EmitterDesc): EmitterId;
3631
+ emit(emitter: EmitterId, count: number): void;
3632
+ setEmitterRate(emitter: EmitterId, rate: number): void;
3633
+ clearEmitter(emitter: EmitterId): void;
3634
+ destroyEmitter(emitter: EmitterId): void;
3635
+ setRenderOrder(node: NodeId, order: number): void;
3636
+ setShadow(light: NodeId, shadow: ShadowParamsDesc): void;
3637
+ setLod(node: NodeId, near: number, far: number, hysteresis: number): void;
3638
+ setSprite(node: NodeId, rotation: number, centerX: number, centerY: number): void;
3639
+ setProbeCoefficients(light: NodeId, sh: Float32Array): void;
3640
+ setProjectionMatrix(camera: NodeId, matrix: Float32Array | null, near: number, far: number): void;
3641
+ setViewOffset(camera: NodeId, offset: ViewOffset | null): void;
3642
+ gpuStats(out: GpuStats): boolean;
3643
+ batchBuffers(node: NodeId): BatchBuffers | null;
3644
+ markBatch(node: NodeId): void;
3645
+ createNode(desc: NodeDesc): NodeId;
3646
+ destroyNode(node: NodeId): void;
3647
+ setNodeVisible(node: NodeId, visible: boolean): void;
3648
+ setNodeLayers(node: NodeId, mask: number): void;
3649
+ setNodeMaterial(node: NodeId, material: MaterialId): void;
3650
+ setNodeText(node: NodeId, text: string): void;
3651
+ loadFont(source: FontSource, family?: string): Promise<FontId>;
3652
+ setTextStyle(node: NodeId, style: TextStyleDesc): void;
3653
+ textBounds(node: NodeId, out: Float32Array): void;
3654
+ raycast(origin: ArrayLike<number>, direction: ArrayLike<number>, far: number, layers: number, out: PickHit): boolean;
3655
+ batchHandle?(): number;
3656
+ governorPressure?(): number;
3657
+ forceQualityTier?(tier: number | null): boolean;
3658
+ qualityTier?(): number;
3659
+ writeNodeMatrices(nodes: Uint32Array, matrices: Float32Array, rows: Int32Array, count: number): void;
3660
+ readNodeMatrix(node: NodeId, out: Float32Array, offset: number): void;
3661
+ instanceMatrices(node: NodeId): Float32Array;
3662
+ instanceColors(node: NodeId): Float32Array | null;
3663
+ setInstanceCount(node: NodeId, count: number): void;
3664
+ markInstancesDirty(node: NodeId): void;
3665
+ setInstanceFeed?(node: NodeId, table: number, columns: readonly number[], hostReads: boolean, pose?: readonly number[]): boolean;
3666
+ setInstancePalette?(node: NodeId, model: ModelId, skin: number, firstClip: number, clips: number, frames: number): boolean;
3667
+ clearInstanceFeed?(node: NodeId): void;
3668
+ morphWeights(node: NodeId): Float32Array;
3669
+ markMorphWeightsDirty(node: NodeId): void;
3670
+ skeletonPose(node: NodeId): Float32Array;
3671
+ markSkeletonDirty(node: NodeId): void;
3672
+ setCameraPerspective(node: NodeId, fovDegrees: number, near: number, far: number): void;
3673
+ setCameraPerspectiveFrom(node: NodeId, values: Float32Array | Float64Array, offset: number): void;
3674
+ setCameraOrthographic(node: NodeId, height: number, near: number, far: number): void;
3675
+ setActiveCamera(node: NodeId): void;
3676
+ setLight(node: NodeId, color: number, intensity: number): void;
3677
+ setEnvironment(desc: EnvironmentDesc): void;
3678
+ createRenderTarget(desc: RenderTargetDesc): RenderTargetId;
3679
+ renderTargetTexture(target: RenderTargetId): TextureId;
3680
+ renderTargetDepthTexture?(target: RenderTargetId): TextureId;
3681
+ renderTargetAttachment?(target: RenderTargetId, attachment: number): TextureId;
3682
+ resizeRenderTarget(target: RenderTargetId, width: number, height: number): void;
3683
+ destroyRenderTarget(target: RenderTargetId): void;
3684
+ createPostChain(desc: PostChainDesc): PostChainId;
3685
+ setPostScalar(chain: PostChainId, effect: number, uniform: string, value: number): void;
3686
+ setPostChain(chain: PostChainId | null): void;
3687
+ setWeather(state: WeatherState): void;
3688
+ setTimeOfDay(hours: number, latitude?: number, dayOfYear?: number): void;
3689
+ destroyPostChain(chain: PostChainId): void;
3690
+ createRenderPass(desc: RenderPassDesc): RenderPassId;
3691
+ setRenderPassEnabled(pass: RenderPassId, enabled: boolean): void;
3692
+ destroyRenderPass(pass: RenderPassId): void;
3693
+ loadModel(source: AssetSource): Promise<ModelInfo>;
3694
+ upgradeModel?(model: ModelId, source: AssetSource): Promise<ModelUpgrade>;
3695
+ loadClips?(root: NodeId, source: AssetSource, options?: {
3696
+ readonly rate?: number;
3697
+ }): Promise<readonly string[]>;
3698
+ setTint?(node: NodeId, tint: KitTint | null): void;
3699
+ instantiateModel(model: ModelId): NodeId;
3700
+ findNode(root: NodeId, name: string): NodeId | null;
3701
+ playClip(root: NodeId, clip: string, loop: boolean, fadeSeconds: number, speed: number): ClipActionId;
3702
+ playClipIndex?(root: NodeId, clip: number, loop: boolean, fadeSeconds: number, speed: number): ClipActionId;
3703
+ clipIndex?(root: NodeId, clip: string): number;
3704
+ setClipWeight(action: ClipActionId, weight: number): void;
3705
+ stopClip(action: ClipActionId, fadeSeconds: number): void;
3706
+ readonly clips?: ClipAnimationPort;
3707
+ readonly vectorSurfaces?: VectorSurfacePort | null;
3708
+ advanceAnimations(time: FrameTime): void;
3709
+ render(time: FrameTime): void;
3710
+ stats(out: GraphicsStats): void;
3711
+ dispose(): void;
3712
+ }
3713
+ interface TransformColumns {
3714
+ readonly capacity: number;
3715
+ readonly position: Float32Array;
3716
+ readonly rotation: Float32Array;
3717
+ readonly scale: Float32Array;
3718
+ readonly previousPosition: Float32Array;
3719
+ readonly previousRotation: Float32Array;
3720
+ readonly previousScale: Float32Array;
3721
+ readonly parent: Uint32Array;
3722
+ readonly render: Float32Array;
3723
+ readonly entities: Uint32Array;
3724
+ readonly sparse: Int32Array;
3725
+ }
3726
+ interface TransformPort {
3727
+ bind(columns: TransformColumns): void;
3728
+ snapshot(count: number): void;
3729
+ computeRender(count: number, time: FrameTime, version: number): void;
3730
+ }
3731
+ interface PhysicsPort {
3732
+ readonly name: string;
3733
+ readonly rollback?: WorldSnapshots | null;
3734
+ bindTransforms(columns: TransformColumns): void;
3735
+ init(desc: PhysicsWorldDesc): Promise<void>;
3736
+ setGravity(gravity: Vec3Like): void;
3737
+ createBody(entity: number, desc: BodyDesc): number;
3738
+ destroyBody(body: number): void;
3739
+ createCollider(body: number, desc: ColliderDesc): number;
3740
+ destroyCollider(collider: number): void;
3741
+ setColliderEnabled(collider: number, enabled: boolean): void;
3742
+ createJoint(bodyA: number, bodyB: number, desc: JointDesc): number;
3743
+ setJointMotor(joint: number, targetVelocity: number, maxForce: number): void;
3744
+ destroyJoint(joint: number): void;
3745
+ step(): void;
3746
+ setBodyPose(body: number, positions: Float32Array, positionOffset: number, rotations: Float32Array, rotationOffset: number): void;
3747
+ linearVelocity(body: number, out: Vec3Like): void;
3748
+ angularVelocity(body: number, out: Vec3Like): void;
3749
+ setLinearVelocity(body: number, velocity: Vec3Like): void;
3750
+ setAngularVelocity(body: number, velocity: Vec3Like): void;
3751
+ applyImpulse(body: number, impulse: Vec3Like): void;
3752
+ applyTorqueImpulse(body: number, impulse: Vec3Like): void;
3753
+ addForce(body: number, force: Vec3Like): void;
3754
+ resetForces(body: number): void;
3755
+ isSleeping(body: number): boolean;
3756
+ wake(body: number): void;
3757
+ raycast(ray: RayQuery, out: RayHit): boolean;
3758
+ batchHandle?(): number;
3759
+ contactCount(): number;
3760
+ contactColliderA(index: number): number;
3761
+ contactColliderB(index: number): number;
3762
+ contactStarted(index: number): boolean;
3763
+ createCharacterController(desc: CharacterControllerDesc): number;
3764
+ moveCharacter(controller: number, collider: number, desired: Vec3Like, out: CharacterMove): void;
3765
+ destroyCharacterController(controller: number): void;
3766
+ applyImpulseAtPoint(body: number, impulse: Vec3Like, point: Vec3Like): void;
3767
+ addForceAtPoint(body: number, force: Vec3Like, point: Vec3Like): void;
3768
+ addTorque(body: number, torque: Vec3Like): void;
3769
+ velocityAtPoint(body: number, point: Vec3Like, out: Vec3Like): void;
3770
+ setJointMotorPosition(joint: number, target: number, stiffness: number, damping: number): void;
3771
+ castShape(query: ShapeCastQuery, out: RayHit): boolean;
3772
+ overlapSphere?(x: number, y: number, z: number, radius: number, includeSensors: boolean, out: SphereOverlap): void;
3773
+ setColliderClass(collider: number, colliderClass: number): void;
3774
+ setContactRule(platform: number, other: number, rule: ContactRuleDesc): void;
3775
+ setCollisionGroups(collider: number, membership: number, filter: number): void;
3776
+ setSolver?(iterations: number, pgsIterations: number, ccdSubsteps: number): void;
3777
+ setSoftCcd?(body: number, distance: number): void;
3778
+ setSleepThresholds?(body: number, linear: number, angular: number, seconds: number): void;
3779
+ readonly vehicles?: VehiclePort | null;
3780
+ readonly craft?: CraftPort | null;
3781
+ readonly jointPort?: JointPort | null;
3782
+ dispose(): void;
3783
+ }
3784
+ interface AudioPort {
3785
+ readonly name: string;
3786
+ readonly unlocked: boolean;
3787
+ unlock(): void;
3788
+ decode(source: AssetSource): Promise<number>;
3789
+ createBus(name: string, parent: number): number;
3790
+ setBusGain(bus: number, gain: number, rampSeconds: number): void;
3791
+ play(sound: number, bus: number, gain: number, rate: number, loop: boolean, spatial: boolean, priority?: number): number;
3792
+ setSoundLimit?(sound: number, voices: number, steal: number): void;
3793
+ setVoiceBudget?(voices: number): void;
3794
+ setVoiceFilter?(voice: number, kind: number, frequency: number, q: number, gainDb: number): void;
3795
+ setLimiter?(enabled: boolean, ceilingDb: number, releaseSeconds: number): void;
3796
+ nowFrame?(): number;
3797
+ playOn?(sound: number, bus: number, gain: number, rate: number, loop: boolean, spatial: boolean, priority: number, frame: number): number;
3798
+ stopOn?(voice: number, frame: number, fadeSeconds: number): void;
3799
+ setVoiceBinaural?(voice: number, binaural: boolean): void;
3800
+ setVoiceOcclusion?(voice: number, params: Float32Array | null): void;
3801
+ musicTempo?(bpm: number, beatsPerBar: number, quantize: number): number;
3802
+ musicPlay?(sounds: Int32Array, gains: Float32Array, bars: number, bus: number, quantize: number, fadeSeconds: number): number;
3803
+ musicLayer?(layer: number, gain: number, rampSeconds: number): void;
3804
+ musicStinger?(sound: number, bus: number, gain: number, quantize: number): number;
3805
+ musicStop?(quantize: number, fadeSeconds: number): number;
3806
+ musicPosition?(out: Float64Array): boolean;
3807
+ stop(voice: number, fadeSeconds: number): void;
3808
+ isPlaying(voice: number): boolean;
3809
+ setVoicePosition(voice: number, matrix: Float32Array, offset: number): void;
3810
+ setListener(matrix: Float32Array, offset: number): void;
3811
+ commit?(frame: Float64Array, at: number): void;
3812
+ suspend(): void;
3813
+ resume(): void;
3814
+ dispose(): void;
3815
+ readonly capabilities: AudioCapabilities;
3816
+ readonly sampleRate: number;
3817
+ createSound(samples: Float32Array, channels: number, sampleRate: number): number;
3818
+ setVoiceGain(voice: number, gain: number, rampSeconds: number): void;
3819
+ setVoiceRate(voice: number, rate: number, detuneCents: number): void;
3820
+ setVoiceSpatial(voice: number, params: Float32Array): void;
3821
+ setVoiceLoop(voice: number, loop: boolean, startSeconds: number, endSeconds: number): void;
3822
+ setBusFilter(bus: number, kind: number, frequency: number, q: number, gainDb: number): void;
3823
+ meter(bus: number, out: Float32Array): void;
3824
+ createAnalyser(bus: number, settings: AnalyserSettings): number;
3825
+ readAnalyser(analyser: number, mode: number, out: Float32Array | Uint8Array): void;
3826
+ createReverb(parent: number, impulse: number): number;
3827
+ setBusSend(bus: number, target: number, gain: number): void;
3828
+ openStream(source: AssetSource, bus: number): Promise<number>;
3829
+ playStream(stream: number, gain: number, loop: boolean): void;
3830
+ pauseStream(stream: number): void;
3831
+ seekStream(stream: number, seconds: number): void;
3832
+ streamTime(stream: number): number;
3833
+ streamDuration(stream: number): number;
3834
+ closeStream(stream: number): void;
3835
+ lockstep?(step: number, stepsPerSecond: number): void;
3836
+ flush?(): void;
3837
+ createEmitters?(sound: number, bus: number, capacity: number, params: Float32Array | null): number;
3838
+ feedEmitters?(bank: number, table: number, columns: Uint32Array): number;
3839
+ releaseEmitters?(bank: number): void;
3840
+ }
3841
+ interface GameBackend {
3842
+ readonly name: string;
3843
+ readonly version: string;
3844
+ readonly memory: ComponentMemory;
3845
+ readonly transforms: TransformPort;
3846
+ readonly graphics: GraphicsPort;
3847
+ readonly physics: PhysicsPort;
3848
+ readonly audio: AudioPort;
3849
+ readonly nav?: NavPort | null;
3850
+ readonly ai?: AiPort | null;
3851
+ readonly streaming?: WorldStreamingPort | null;
3852
+ readonly terrain?: TerrainPort | null;
3853
+ readonly scenery?: SceneryPort | null;
3854
+ readonly soa?: SoaEngine | null;
3855
+ readonly kernels?: KernelEngine | null;
3856
+ readonly chemistry?: ChemistryEngine | null;
3857
+ readonly fluids?: FluidPort | null;
3858
+ readonly destruction?: DestructionPort | null;
3859
+ readonly softBodies?: SoftBodyPort | null;
3860
+ readonly reactive?: ReactivePort | null;
3861
+ readonly cloths?: ClothPort | null;
3862
+ readonly smoke?: SmokePort | null;
3863
+ readonly story?: StoryPort | null;
3864
+ }
3865
+
3866
+ export { type MaterialTextureSlot as $, type AudioPort as A, type BrushOp as B, type CompoundPartDesc as C, type DeviceTier as D, type EmitterDesc as E, FrameTime as F, type GameBackend as G, type VideoFrameSource as H, type RenderTargetId as I, type VectorAssetId as J, type VectorSurfaceDesc as K, type LimiterDesc as L, type MusicQuantize as M, type NodeId as N, type OcclusionDesc as O, type PannerDesc as P, type VectorSurfaceId as Q, type RawGpu as R, type SoundLimitDesc as S, type TerrainPort as T, type VectorSurfacePlay as U, Vec3 as V, type VectorSurfaceSeek as W, type VectorSurfacePhase as X, type VectorSurfaceEvent as Y, type VectorSurfaceStats as Z, type VectorSurfaceTier as _, FixedStepLoop as a, type TransformPort as a$, type MaterialStateDesc as a0, type EmitterId as a1, type ShadowParamsDesc as a2, type ViewOffset as a3, type GpuStats as a4, type NodeDesc as a5, type FontSource as a6, type FontId as a7, type TextStyleDesc as a8, type PickHit as a9, type ChemistryEngine as aA, type ReactivePort as aB, type SmokePort as aC, type StoryPort as aD, type DestructionPort as aE, type StructureDesc as aF, type LoopOptions as aG, type FractureMesh as aH, type FractureOptions as aI, GPU_PASS_NAMES as aJ, createPickHit as aK, type NavPort as aL, type NavDesc as aM, type OffMeshLinkDesc as aN, type AgentDesc as aO, type RoadGraphDesc as aP, type DriverDesc as aQ, RayQuery as aR, RayHit as aS, type SoaEngine as aT, type SoaBulkExports as aU, ShapeCastQuery as aV, type RollbackState as aW, type Scalar as aX, type ArrayFor as aY, type ComponentMemory as aZ, type TransformColumns as a_, type EnvironmentDesc as aa, type RenderTargetDesc as ab, type RenderPassId as ac, type PostChainDesc as ad, type PostChainId as ae, type WeatherState as af, type MediumDesc as ag, MediumVolume as ah, type RenderPassDesc as ai, type ModelInfo as aj, type KitTint as ak, type ClipActionId as al, type ClipAnimationPort as am, type GraphicsStats as an, type FluidPort as ao, type IkChainId as ap, type ClipEvent as aq, type BlendSpaceId as ar, type BoneSetId as as, type RootMotionId as at, type VehicleDesc as au, Vehicle as av, Quat as aw, type AiPort as ax, type AiWorldOptions as ay, type ArchetypeDecl as az, type AssetSource as b, type ScheduleBlockDecl as b$, type CurveTable as b0, type SoftBodyPort as b1, type SoftBodyInfo as b2, type CraftPort as b3, type WaterDesc as b4, type SeaState as b5, type OceanDesc as b6, type OceanCascades as b7, type PuddleOptions as b8, type RippleOptions as b9, CHEMISTRY_REFUSED as bA, CHEMISTRY_SLOTS as bB, CHEMISTRY_SPECIES_WORDS as bC, CHEMISTRY_STATS_WORDS as bD, CHEMISTRY_TQ as bE, CHEMISTRY_UNSET as bF, CHEMISTRY_VACUUM as bG, CHEMISTRY_VESSEL_SLOTS as bH, CHEMISTRY_VESSEL_WORDS as bI, type ChemistryExportName as bJ, type ChemistryExports as bK, bindChemistryEngine as bL, type ClipLoop as bM, type LightKind as bN, type TypedArray as bO, type PhysicsWorldDesc as bP, Vec2 as bQ, type ShapeDesc as bR, type VehiclePort as bS, type BehaviourDecl as bT, type ConsiderationDecl as bU, type InputDecl as bV, type ActionDecl as bW, type SightDecl as bX, type SteeringDecl as bY, type SkillDecl as bZ, type NeedDecl as b_, WaterSample as ba, type ColliderDesc as bb, type PhysicsPort as bc, type WorldRollbackDesc as bd, type SolverSettings as be, type SleepThresholds as bf, WorldSnapshots as bg, type BodyDesc as bh, type JointPort as bi, type RagdollDesc as bj, type Ragdoll as bk, type JointDesc as bl, type ContactRuleDesc as bm, type CharacterControllerDesc as bn, CharacterMove as bo, type WorldStreamingPort as bp, type KernelEngine as bq, CHEMISTRY_ATMOSPHERE as br, CHEMISTRY_BOX_WORDS as bs, CHEMISTRY_COLUMNS as bt, CHEMISTRY_EVENT_HEADER as bu, CHEMISTRY_EVENT_WORDS as bv, CHEMISTRY_EXPORT_NAMES as bw, CHEMISTRY_NATURE_WORDS as bx, CHEMISTRY_PROBE_WORDS as by, CHEMISTRY_REACTION_WORDS as bz, type AudioCapabilities as c, GEAR_AUTO as c$, type CurveDecl as c0, type BuiltinInput as c1, AI_EVENT_WORDS as c2, AI_MAX_GAME_SLOTS as c3, AI_NONE as c4, AiEventKind as c5, type AiEventKindCode as c6, BUILTIN_INPUTS as c7, PHASE_IDLE as c8, PHASE_RECOVER as c9, CLOTH_FEATURE as cA, type CastShapeKind as cB, type CloudDesc as cC, type ColorSpace as cD, type CompareFunction as cE, ContactRuleTable as cF, type CurvePoint as cG, DEFAULT_COLLIDER_CLASS as cH, DEFAULT_PANNER as cI, DISTANCE_MODELS as cJ, type DistanceModel as cK, type EmitterCollision as cL, type EmitterShape as cM, type EngineCurveDesc as cN, FILTER_KINDS as cO, FLUID_CAP_SIMULATION as cP, FLUID_CAP_SURFACE as cQ, FRAME_ALPHA_SLOT as cR, FRAME_NOW_MS_SLOT as cS, FRAME_SECONDS_SLOT as cT, FRAME_STEP_SECONDS_SLOT as cU, FRAME_TICK_SLOT as cV, FftAnalyser as cW, type FilterKind as cX, type FogDesc as cY, type FracturePiece as cZ, type FractureResult as c_, PHASE_STRIKE as ca, PHASE_WINDUP as cb, type ToneMapping as cc, type PostEffectDesc as cd, type SceneryBodyPort as ce, type KeyframeDesc as cf, type KeyframeStats as cg, AGENT_ARRIVED as ch, AGENT_IDLE as ci, AGENT_LOST as cj, AGENT_MOVING as ck, AGENT_ON_LINK as cl, AGENT_REQUESTING as cm, AGENT_STRIDE as cn, AGENT_X as co, AUDIO_PREVIEW_SUFFIX as cp, AssetPriority as cq, type AtmosphereDesc as cr, type AxisMotion as cs, BRUSH as ct, type BatchBuffers as cu, type BlendDesc as cv, type BlendEquation as cw, type BlendFactor as cx, type Blending as cy, type BodyKind as cz, type FilterDesc as d, POSE_LANE as d$, GEAR_NEUTRAL as d0, GEAR_REVERSE as d1, type GearboxDesc as d2, type GeometryGroup as d3, type GlobalIlluminationDesc as d4, type GlobalIlluminationMode as d5, type GlslSource as d6, type GpuBindGroupId as d7, type GpuBindingDesc as d8, type GpuBlend as d9, type JointAxisName as dA, type JointDrive as dB, type JointLoad as dC, type LaneSpec as dD, type LeanDesc as dE, type LinesMaterialDesc as dF, type LodRange as dG, MAX_CCD_SUBSTEPS as dH, MAX_COLLIDER_CLASSES as dI, MAX_PGS_ITERATIONS as dJ, MAX_SOLVER_ITERATIONS as dK, MEDIUM_DEFAULTS as dL, MEDIUM_MAX as dM, MEDIUM_MAX_EDGE as dN, type MatcapMaterialDesc as dO, type MaterialCommon as dP, type MaterialTint as dQ, type MediumId as dR, type MediumPort as dS, type MorphTargetDesc as dT, NOISE as dU, NO_CONTACT_RULE as dV, NO_LINK as dW, type NodeCommon as dX, type NodeKindDesc as dY, POSE_DIR_X as dZ, POSE_DIR_Z as d_, type GpuBlendComponent as da, type GpuBlendFactor as db, type GpuBufferDesc as dc, type GpuBufferId as dd, type GpuBufferUsage as de, type GpuComputePipelineDesc as df, type GpuDispatchOptions as dg, type GpuDrawOptions as dh, type GpuHook as di, type GpuPipelineId as dj, type GpuRect as dk, type GpuRenderPipelineDesc as dl, type GpuSamplerDesc as dm, type GpuSamplerId as dn, type GpuSceneResource as dp, type GpuSceneTexture as dq, type GpuShaderId as dr, type GpuTextureCopy as ds, type GpuTextureDesc as dt, type GpuTextureFormat as du, type GpuTextureId as dv, type GpuTextureUsage as dw, type GpuTopology as dx, type Interpolation as dy, JOINT_AXES as dz, type AnalyserDesc as e, type VolumetricFogDesc as e$, POSE_SPEED as e0, POSE_STRIDE$1 as e1, POSE_X as e2, POSE_Z as e3, type PhysicalMaterialDesc as e4, type PointsMaterialDesc as e5, type PolygonOffsetDesc as e6, type PrimitiveShapeDesc as e7, POSE_STRIDE as e8, REACTIVE_FEATURE as e9, type StencilDesc as eA, type StencilOperation as eB, TERRAIN_REGISTER as eC, TIME_SCALE_SLOT as eD, type TexelData as eE, type TexelFormat as eF, type TextAlign as eG, type TextDirection as eH, type TextureEncode as eI, type TextureFilter as eJ, type TextureKind as eK, type TextureSource as eL, type TextureTransform as eM, type TextureWrap as eN, type ToonMaterialDesc as eO, type Transparency as eP, type UniformDesc as eQ, type UniformType as eR, type UnlitMaterialDesc as eS, VECTOR_SURFACE_CAPS as eT, VECTOR_SURFACE_EDGES as eU, VECTOR_SURFACE_TIERS as eV, type Vec3Tuple as eW, Vec4 as eX, type VectorSurfacePort as eY, type VertexAttributeDesc as eZ, type VolumetricCloudsDesc as e_, type RagdollBoneDesc as ea, type RagdollDrive as eb, type RagdollRoot as ec, type RenderTargetFormat as ed, SCENERY_REGISTER as ee, SCENERY_REGISTER_WORDS as ef, SCENERY_REQUEST_SLOTS as eg, SEA_STATES as eh, SH_COEFFICIENT_FLOATS as ei, SIGNAL_AMBER as ej, SIGNAL_GREEN as ek, SIGNAL_RED as el, SOA_EXPORT_NAMES as em, SOFT_BODY_FEATURE as en, type ShaderMaterialDesc as eo, type ShaderSource as ep, type ShadowDesc as eq, type ShadowType as er, type Side as es, type SignalSpec as et, type SkeletonDesc as eu, type SkyDesc as ev, type SoaExports as ew, type SphereOverlap as ex, type SpriteMaterialDesc as ey, type StandardMaterialDesc as ez, type Vec3Like as f, type VolumetricsDesc as f0, WHEEL_CENTER as f1, WHEEL_FORCE_LAT as f2, WHEEL_FORCE_LONG as f3, WHEEL_GROUND as f4, WHEEL_LENGTH as f5, WHEEL_LOAD as f6, WHEEL_OMEGA as f7, WHEEL_POINT as f8, WHEEL_SLIP as f9, WHEEL_SLIP_ANGLE as fa, WHEEL_SPIN as fb, WHEEL_STEER as fc, Water as fd, type WaterFlow as fe, type WaveDesc as ff, type WgslSource as fg, type WheelDesc as fh, analyserSettings as fi, bindKernelEngine as fj, bindSoaEngine as fk, createGpuStats as fl, createVectorSurfaceStats as fm, detuneRate as fn, encodeVehicleDesc as fo, isa as fp, materialTint as fq, mediumIndex as fr, mediumTexel as fs, mediumTexelCount as ft, peakCurve as fu, sampleCurve as fv, seaDesc as fw, type NoiseKind as g, type Plane as h, type GeometryId as i, type MaterialId as j, type MaterialDesc as k, type AnalyserSettings as l, type ClothPort as m, type ClothInfo as n, type SceneryPort as o, type GraphicsPort as p, type GraphicsCapabilities as q, type GameSurface as r, type GeometryDesc as s, type VertexData as t, type TextureDesc as u, type TextureId as v, type TextureUpgrade as w, type ModelId as x, type ModelUpgrade as y, type TextureRegion as z };