@volter/game-editor 0.5.125 → 0.5.126
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.
- package/BUNDLED_NOTICES +45 -45
- package/catalog/entries/blender.json +2 -2
- package/catalog/entries/music.json +2 -2
- package/dist/.vite/manifest.json +2280 -2279
- package/dist/assets/{AssetBudgetPanel-BSgP_Ly5.js → AssetBudgetPanel-Dw0mwjRj.js} +3 -3
- package/dist/assets/{AudioViewer-B88kBiQH.js → AudioViewer-g6DZTip3.js} +1 -1
- package/dist/assets/{CanvasBoardDocument-BmyDdzzT.js → CanvasBoardDocument-CYfvZZhs.js} +1 -1
- package/dist/assets/{CanvasSceneViewport-DN9DYpjz.js → CanvasSceneViewport-_ujBC0Hb.js} +1 -1
- package/dist/assets/{ColorInput-D6i_QXM-.js → ColorInput-Dbt7qyP_.js} +1 -1
- package/dist/assets/{ColorPicker-VBKN9sk0.js → ColorPicker-BQqtP05Z.js} +1 -1
- package/dist/assets/{EntityModelDocument-Bbp4eSk-.js → EntityModelDocument-Bd5HLKGv.js} +1 -1
- package/dist/assets/{EnvironmentAssetDocument-CHl6PCV6.js → EnvironmentAssetDocument-CbN5978S.js} +1 -1
- package/dist/assets/{Fbo-BwAOPGSM.js → Fbo-Biv6Lrhl.js} +1 -1
- package/dist/assets/{GameplaySessionTimeline-DSCmUHiz.js → GameplaySessionTimeline-CYTcpGtI.js} +1 -1
- package/dist/assets/{Gltf-GjdUJfpn.js → Gltf-CRUmmFxv.js} +1 -1
- package/dist/assets/{ImageViewer-RDOE-ikb.js → ImageViewer-ZP-vqYrn.js} +1 -1
- package/dist/assets/InspectorObjectPreview-C9LL7i9-.js +1 -0
- package/dist/assets/{JsonAssetDocument-y-ihqubn.js → JsonAssetDocument-mYrrRpaO.js} +1 -1
- package/dist/assets/{LiveModuleDocument-BRKWZS4J.js → LiveModuleDocument-cKhhscAn.js} +1 -1
- package/dist/assets/{LutAssetDocument-D6redjUn.js → LutAssetDocument-D8NoS7X3.js} +1 -1
- package/dist/assets/{ModelAssetDocument-DXcUg5-F.js → ModelAssetDocument-D1DSC4Iu.js} +1 -1
- package/dist/assets/{NonThreeAuthoringBootstrap-CpZS3Gow.js → NonThreeAuthoringBootstrap-B16sst3N.js} +1 -1
- package/dist/assets/{Object3DDocumentToolbar-C7g33hHW.js → Object3DDocumentToolbar-HpLpBnxB.js} +1 -1
- package/dist/assets/Object3DDocumentViewport-Dutf8dw1.js +2 -0
- package/dist/assets/{Object3DPreview-CWZeky9X.js → Object3DPreview-BDcnPwtN.js} +1 -1
- package/dist/assets/{OnlineAssetDetail-Wm_N9tmK.js → OnlineAssetDetail-CmsuIyHO.js} +1 -1
- package/dist/assets/{OrbitControls-DqeA2OK1.js → OrbitControls-C6LQ4Pxi.js} +1 -1
- package/dist/assets/{OrthographicCamera-QGDXU8-_.js → OrthographicCamera-Bv8_A2mi.js} +1 -1
- package/dist/assets/{PerspectiveCamera-CzyDwUe8.js → PerspectiveCamera-D3r6Hnc8.js} +1 -1
- package/dist/assets/{PlayBar-BSCkbbWm.js → PlayBar-B-wzdW50.js} +1 -1
- package/dist/assets/{QuarksAssetDocument-C2d8g6QR.js → QuarksAssetDocument-BdQ1jC4o.js} +1 -1
- package/dist/assets/{ReactCanvasControls-DZZEWbJH.js → ReactCanvasControls-ktCc-GId.js} +1 -1
- package/dist/assets/{RootSelectionOverlay-BlDdfAyN.js → RootSelectionOverlay-FbwqJC6K.js} +1 -1
- package/dist/assets/{ShaderAssetDocument-BMIhoIDU.js → ShaderAssetDocument-BhlIcpVE.js} +1 -1
- package/dist/assets/{ShadowEditor-DJfc5awF.js → ShadowEditor-B7VnLK5D.js} +1 -1
- package/dist/assets/{SourceAssetViewer-CSS85AGm.js → SourceAssetViewer-CIy0LlGq.js} +1 -1
- package/dist/assets/{StageHost-BHQB10fP.js → StageHost-BnK5_8Ju.js} +2 -2
- package/dist/assets/{StoryPreviewMount-DtOeByMH.js → StoryPreviewMount-BT3EF_bY.js} +1 -1
- package/dist/assets/{ThreeBoardDocument-CU7hSmxx.js → ThreeBoardDocument-C6MAwwMT.js} +2 -2
- package/dist/assets/{ThreeIsolationSceneContent-CZFEUx5D.js → ThreeIsolationSceneContent-Jb-BiqBy.js} +1 -1
- package/dist/assets/{ToolObject3DPreview-BZ-bqJjM.js → ToolObject3DPreview-CWoW5Ykt.js} +1 -1
- package/dist/assets/{Toolbar-bpjNJw1o.js → Toolbar-DQehpz2z.js} +1 -1
- package/dist/assets/{TransientHint-Cs1xJsTR.js → TransientHint-I9gc0jbe.js} +1 -1
- package/dist/assets/{VideoViewer-DNcS3fPO.js → VideoViewer-DnhtA-uQ.js} +1 -1
- package/dist/assets/{ViewportShadingMenu-BGdf_ugP.js → ViewportShadingMenu-DhHBsvZ2.js} +1 -1
- package/dist/assets/{active-ingest-Ddr-rqpl.js → active-ingest-BX03j5HF.js} +2 -2
- package/dist/assets/{animation-clock-BBk2Uf4j.js → animation-clock-B_14wv8o.js} +1 -1
- package/dist/assets/{animation-mixers.service-q4aIDhxx.js → animation-mixers.service-YA_zc7aC.js} +1 -1
- package/dist/assets/{animation-timeline.utility-D6rFf4EX.js → animation-timeline.utility-BaheZJ4K.js} +1 -1
- package/dist/assets/{asset-budget-asset.menu-DEuaaKC5.js → asset-budget-asset.menu-7kNgi_NN.js} +1 -1
- package/dist/assets/{asset-budget.action-v70qmoCd.js → asset-budget.action-CHnj-0Hk.js} +1 -1
- package/dist/assets/{asset-budget.document-BeuS8SRM.js → asset-budget.document-BX2-n5L5.js} +1 -1
- package/dist/assets/{asset-budget.menu-bK7bDVj7.js → asset-budget.menu-5kkY86aK.js} +1 -1
- package/dist/assets/{asset-editor-persistence-C8kiK_is.js → asset-editor-persistence-Bd6-j3nh.js} +1 -1
- package/dist/assets/{asset-loaders-CZ_1eTic.js → asset-loaders-BX593_Lm.js} +1 -1
- package/dist/assets/{asset-preview-Cck2dsj4.js → asset-preview-BRUzjkTl.js} +1 -1
- package/dist/assets/{audio-unlock.service-DzW-k8nv.js → audio-unlock.service-DUHq3Djy.js} +1 -1
- package/dist/assets/{audio.utility-CZfoTgEQ.js → audio.utility-NVAVahkr.js} +1 -1
- package/dist/assets/autoplay.service-DFxFVLHJ.js +1 -0
- package/dist/assets/{babylon-authoring-adapter-B1-f9m-3.js → babylon-authoring-adapter-DPAz8ZAn.js} +1 -1
- package/dist/assets/binding-resolver-rLWZKbdA.js +2 -0
- package/dist/assets/{blender-node-editor.document-gGXQ4eC4.js → blender-node-editor.document-AOzDk-zF.js} +1 -1
- package/dist/assets/{blender-properties-tab-_2HlBre8.js → blender-properties-tab-htkOP2E1.js} +1 -1
- package/dist/assets/{blender-runtime-host-B3OHRnyq.js → blender-runtime-host-Djtuf_84.js} +1 -1
- package/dist/assets/{blender-runtime-skin-V9L1oa_d.js → blender-runtime-skin-DAOfR9wP.js} +1 -1
- package/dist/assets/{blender-runtime.document-YfVgb0xw.js → blender-runtime.document-CLPXAqOY.js} +1 -1
- package/dist/assets/{blender-screenshot.menu-DJW5wTB1.js → blender-screenshot.menu-D-Wh9nrx.js} +1 -1
- package/dist/assets/{blender-timeline.document-nci9H4b6.js → blender-timeline.document-D92ZF7GS.js} +1 -1
- package/dist/assets/{blender-uv-editor.document-hAy3fFV_.js → blender-uv-editor.document-RIzCN8r6.js} +1 -1
- package/dist/assets/{blender-version.status-IBwLAxXR.js → blender-version.status-DHM5-hy2.js} +1 -1
- package/dist/assets/{blender.command-B_7KUtv7.js → blender.command-BrxSr8fh.js} +1 -1
- package/dist/assets/{board-guides-CLF_VLvL.js → board-guides-DM_vAo0C.js} +1 -1
- package/dist/assets/{bridge.command-DgsgKZa4.js → bridge.command-Cf8O6nG3.js} +3 -3
- package/dist/assets/{browserAll-DnBssp_8.js → browserAll-Bk80CK14.js} +1 -1
- package/dist/assets/{build-player.document-ue8n3WPX.js → build-player.document-jcpog-l6.js} +1 -1
- package/dist/assets/{build-profiles.document-BoxCYqFz.js → build-profiles.document-DOJRDJTc.js} +1 -1
- package/dist/assets/{build-progress.status-DIVFq_Wm.js → build-progress.status-DIseL3Fj.js} +1 -1
- package/dist/assets/{build-session-LR4kIgAX.js → build-session-DZ4UD5Tu.js} +1 -1
- package/dist/assets/{build.action-B1Tw-IoK.js → build.action-DlevnO2E.js} +1 -1
- package/dist/assets/{build.command-CtmztNo9.js → build.command-BDNgR4X1.js} +1 -1
- package/dist/assets/{build.header-DDLkcelu.js → build.header-CwUIPMW3.js} +1 -1
- package/dist/assets/{build.menu-BAwLd2ek.js → build.menu-Cdi2l3SN.js} +1 -1
- package/dist/assets/{build.service-B-FnDXxN.js → build.service-xdhMVVqg.js} +1 -1
- package/dist/assets/{camera-DuP48tI_.js → camera-GR-fO2IE.js} +1 -1
- package/dist/assets/{camera-runtime.inspector-CziDqZQb.js → camera-runtime.inspector-RPVKn6vT.js} +1 -1
- package/dist/assets/{canvas-design-mount-BABOs-lh.js → canvas-design-mount-B3FNDE7x.js} +3 -3
- package/dist/assets/{canvas-entry-runtime-Dcf218s2.js → canvas-entry-runtime-Cux0NSyO.js} +2 -2
- package/dist/assets/{canvas-preview-frames-DNGxYzHV.js → canvas-preview-frames-CmraLAxc.js} +1 -1
- package/dist/assets/{canvas-story-capture.service-BJpDDwVH.js → canvas-story-capture.service-5ZvfS8si.js} +2 -2
- package/dist/assets/{capability-coverage-6PwUP4oX.js → capability-coverage-9jbjkC7w.js} +1 -1
- package/dist/assets/{collaboration-presence-BNBw47jA.js → collaboration-presence-CTV15flX.js} +1 -1
- package/dist/assets/{collider-DAF9Z2X4.js → collider-Di0qr3hq.js} +1 -1
- package/dist/assets/{component-board.service-khBXmwDQ.js → component-board.service-CEq7FpJ7.js} +2 -2
- package/dist/assets/{component-board.service-ihMRMzy3.js → component-board.service-CbNgdTIL.js} +2 -2
- package/dist/assets/{component-board.service-Dv4HPrwH.js → component-board.service-CkPxbdFE.js} +2 -2
- package/dist/assets/{component-contracts.service-CwplNZn-.js → component-contracts.service-BLE-me7t.js} +1 -1
- package/dist/assets/{component-instance-root-9er-zSAY.js → component-instance-root-6vlZ9amU.js} +1 -1
- package/dist/assets/{component-verbs.command-z-I0Ro4a.js → component-verbs.command-DJ9tpbm_.js} +1 -1
- package/dist/assets/{component-verbs.service-DwLwoLTJ.js → component-verbs.service-DOO6ltFy.js} +1 -1
- package/dist/assets/{config-DQzlvYVI.js → config-SpOmE1ZF.js} +2 -2
- package/dist/assets/{configurations-oKsIhTb-.js → configurations-v9B1hzPx.js} +1 -1
- package/dist/assets/{connection.status-BqYA7Z5e.js → connection.status-D273cCfw.js} +1 -1
- package/dist/assets/{constraints.inspector-CVyV22tC.js → constraints.inspector-CTDm_yw6.js} +1 -1
- package/dist/assets/{content-bounds-DuSmUtY1.js → content-bounds-SMMmDnR9.js} +1 -1
- package/dist/assets/{contract-system-adapters-C66CNkAk.js → contract-system-adapters-Dx3-ZI4N.js} +1 -1
- package/dist/assets/{coverage.service-DwFCo4w8.js → coverage.service-QEYdDNJf.js} +1 -1
- package/dist/assets/{create-runtime-B2p75b5q.js → create-runtime-S5Je5FVD.js} +1 -1
- package/dist/assets/{curve-Dw4divzX.js → curve-Dna3Q4Rl.js} +1 -1
- package/dist/assets/{data-asset-BSxK3Y_h.js → data-asset-Do7MzBwx.js} +1 -1
- package/dist/assets/{data-ref-BUs2PbaF.js → data-ref-Dbulgqez.js} +1 -1
- package/dist/assets/{debug-bridge-BdoOc1Jv.js → debug-bridge-B1HF0efX.js} +1 -1
- package/dist/assets/{debug-registry-BosYnV_Z.js → debug-registry-CurxbdJb.js} +1 -1
- package/dist/assets/{deferred-ingest-play-BOUu0VgE.js → deferred-ingest-play-04UYeDFI.js} +2 -2
- package/dist/assets/{design-time-canvas-mount-Ds-zq4CU.js → design-time-canvas-mount-CcBiI7BU.js} +2 -2
- package/dist/assets/{design-time-layers-B0DteFiV.js → design-time-layers-DHbs4Bar.js} +1 -1
- package/dist/assets/{design-time-mount.service-CfOBd_-9.js → design-time-mount.service-BTJtrJB4.js} +2 -2
- package/dist/assets/{design-time-mount.service-CrQoKi6N.js → design-time-mount.service-DxQYWBtW.js} +2 -2
- package/dist/assets/{design-time-react-mount-B6BJiTeO.js → design-time-react-mount-CaMPhDB5.js} +1 -1
- package/dist/assets/{document-preview-three-4FxFY9Cx.js → document-preview-three-BE-UtLOm.js} +1 -1
- package/dist/assets/{dom-authoring-adapter-vourOD4d.js → dom-authoring-adapter-BCJi5KPk.js} +1 -1
- package/dist/assets/{draco3d-Bk4s3p1H.js → draco3d-D-9gDYvZ.js} +1 -1
- package/dist/assets/{edit-mode-audio.service-DRpU_FFF.js → edit-mode-audio.service-aYQF0kbI.js} +1 -1
- package/dist/assets/{edit-mode-authoring-z2Uu4CrX.js → edit-mode-authoring-Bm31X1cT.js} +1 -1
- package/dist/assets/{edit-mode-networking.service-DhwnIn2o.js → edit-mode-networking.service-DII_DaVN.js} +1 -1
- package/dist/assets/{editor-api-hojxsk8T.js → editor-api-Dae4rOeq.js} +1 -1
- package/dist/assets/{editor-layers-CSl6S15k.js → editor-layers-DvKAawE7.js} +1 -1
- package/dist/assets/{editor-shell-store-DTfKHHYD.js → editor-shell-store-sESsCCic.js} +1 -1
- package/dist/assets/{entity-object-BO1_Qmt8.js → entity-object-CR7fCzb1.js} +1 -1
- package/dist/assets/{events-156d8d12.esm-CYeuVCYr.js → events-156d8d12.esm-DmeaOP4r.js} +1 -1
- package/dist/assets/{extend-BedwRP5_.js → extend-BeHPp0pO.js} +1 -1
- package/dist/assets/{fork-menu-BWmJjb_A.js → fork-menu-BLV4klro.js} +1 -1
- package/dist/assets/{frame-debugger-store-Gu32HGGD.js → frame-debugger-store-CzfMAFm8.js} +1 -1
- package/dist/assets/{game-contract-seams-DQGwjObL.js → game-contract-seams-FFGgxMOq.js} +1 -1
- package/dist/assets/{game-css-scope-transform-DYa5L1dk.js → game-css-scope-transform-CpH5gRrU.js} +1 -1
- package/dist/assets/{game-document.service-CG1egqq7.js → game-document.service-BaWJoY3b.js} +1 -1
- package/dist/assets/{game-eval.command-D9LYcy3m.js → game-eval.command-DimBNXZh.js} +1 -1
- package/dist/assets/{game-module-access-DfYSoZjk.js → game-module-access-INT7uWVq.js} +1 -1
- package/dist/assets/{game-network-BZdvwJ0a.js → game-network-D6iKU3Wc.js} +3 -3
- package/dist/assets/{gameplay-export-BVH9PKaE.js → gameplay-export-CA8Cj_Ya.js} +1 -1
- package/dist/assets/{gameplay-replay-BLLppt8C.js → gameplay-replay-BaOK1PHn.js} +1 -1
- package/dist/assets/{gameplay.command-Djp-Aok2.js → gameplay.command-CNZVmVoY.js} +1 -1
- package/dist/assets/{generation-jobs-CsXRg1Tq.js → generation-jobs-CrR2awmo.js} +1 -1
- package/dist/assets/{generation.service-Cn7nGBEo.js → generation.service-DYXXqp6a.js} +1 -1
- package/dist/assets/{generations-BqPU1fPO.js → generations-BmTovCQz.js} +1 -1
- package/dist/assets/{generations.status-CJUE5vVY.js → generations.status-CPANXPOQ.js} +1 -1
- package/dist/assets/{hierarchy-marks-B4XzZe8e.js → hierarchy-marks-QDNP7a91.js} +1 -1
- package/dist/assets/{hosted-asset-materialization-iHAqPmZ-.js → hosted-asset-materialization-DAbhyLRe.js} +1 -1
- package/dist/assets/{index-CvVYuIWr.js → index-2lrANwoO.js} +1 -1
- package/dist/assets/{index-C9f8SWpp.js → index-B3jjiaMn.js} +1 -1
- package/dist/assets/{index-CRj7mn0r.js → index-BMYvLvi0.js} +1 -1
- package/dist/assets/{index-C1mcZ_qc.js → index-BStQTwLR.js} +2 -2
- package/dist/assets/{index-By0elT7x.js → index-BTQxFFqF.js} +1 -1
- package/dist/assets/{index-r-FuctN5.js → index-C7p_QQ7P.js} +7 -7
- package/dist/assets/{index-X7FPqr0y.js → index-DSGUQ614.js} +1 -1
- package/dist/assets/{index-COorqncb.js → index-DTBK2UM6.js} +1 -1
- package/dist/assets/{index-F91ICQ72.js → index-DWoS4rs9.js} +1 -1
- package/dist/assets/index-DzuOGwVB.js +1 -0
- package/dist/assets/{inference-diagnostics-D4Iu86es.js → inference-diagnostics-C6_Z4_8a.js} +1 -1
- package/dist/assets/{ingest-boot-viewport-DdHb1LeO.js → ingest-boot-viewport-V0jgUOLv.js} +1 -1
- package/dist/assets/{ingest-siblings-Cf-McyY_.js → ingest-siblings-CilJDzwT.js} +1 -1
- package/dist/assets/{ingest-source-persistence-BwINDLYc.js → ingest-source-persistence-CsqPDVx6.js} +1 -1
- package/dist/assets/{ingest.service-B8hV6YT4.js → ingest.service-2Lk_9rjD.js} +1 -1
- package/dist/assets/{inspect-sYciyXgK.js → inspect-B4sqdFaU.js} +1 -1
- package/dist/assets/instances.command-mIr5Ujz9.js +1 -0
- package/dist/assets/{json-history-resource-DuT7scib.js → json-history-resource-QtpzKzwO.js} +1 -1
- package/dist/assets/{layered-pick-1v6rbWkT.js → layered-pick-BDMgzWjy.js} +1 -1
- package/dist/assets/{light-B3S378yT.js → light-18unOAF2.js} +1 -1
- package/dist/assets/{live-project-verbs-BnaccVli.js → live-project-verbs-CgDrfITj.js} +1 -1
- package/dist/assets/{machine.document-BG1voYon.js → machine.document-zxyIZAJ0.js} +1 -1
- package/dist/assets/{machines.finder-G0u80stL.js → machines.finder-DIvktqio.js} +1 -1
- package/dist/assets/{material-BCw5pv20.js → material-D8WYnLCY.js} +1 -1
- package/dist/assets/{material-factory-zynl18MK.js → material-factory-4rh5Wqux.js} +1 -1
- package/dist/assets/{mesh-q9baasmD.js → mesh-_D58fKg5.js} +1 -1
- package/dist/assets/{model-asset-sections.service-DL_H2GfH.js → model-asset-sections.service--50j12QT.js} +1 -1
- package/dist/assets/{model-inspection-BbRgz6bo.js → model-inspection-CJLzpxRV.js} +1 -1
- package/dist/assets/{model-thumbnail-DSDxaYgd.js → model-thumbnail-Cj3_XSnl.js} +1 -1
- package/dist/assets/{models.finder-Dy-J43qR.js → models.finder-BrngxQWo.js} +1 -1
- package/dist/assets/{module-mode-DNU-E0nG.js → module-mode-DPX0apH8.js} +2 -2
- package/dist/assets/{mount-canvas-ingest-root-CQ4W-gUR.js → mount-canvas-ingest-root-BgMvNvBB.js} +2 -2
- package/dist/assets/{mount-dom-ingest-root-COjIeP_R.js → mount-dom-ingest-root-DjdlRVDm.js} +2 -2
- package/dist/assets/{mount-ingest-root-CWdNrIZI.js → mount-ingest-root-CjOWFsbq.js} +2 -2
- package/dist/assets/{mount-manifest-qdcv5b_0.js → mount-manifest-BKLx3Qv1.js} +1 -1
- package/dist/assets/{mount-three-ingest-root-DztDwD1p.js → mount-three-ingest-root-CpEBMdDE.js} +1 -1
- package/dist/assets/{mounted-authoring-DKn1UEnI.js → mounted-authoring-BAll64vX.js} +1 -1
- package/dist/assets/{mounted-story-viewport-source-Dj51da9b.js → mounted-story-viewport-source-lYU11-92.js} +1 -1
- package/dist/assets/{native-debug-module-C5xRtrQJ.js → native-debug-module-_hzBkCZ7.js} +1 -1
- package/dist/assets/{navigation-6i4sFL2e.js → navigation-DOw2VRQ4.js} +1 -1
- package/dist/assets/{navmesh.menu-BeWFiE7d.js → navmesh.menu-CHyJEJcS.js} +1 -1
- package/dist/assets/{navmesh.service-y9zoEU38.js → navmesh.service-DBlMQ-d7.js} +1 -1
- package/dist/assets/network-observer.service-C7vOkn3z.js +1 -0
- package/dist/assets/{network.utility-D_HsH5qj.js → network.utility-B3ULXw0c.js} +1 -1
- package/dist/assets/{object3d-document-session-registry-BGuY8anX.js → object3d-document-session-registry-DHi4wjTF.js} +2 -2
- package/dist/assets/{oid-transform-wqjngb9T.js → oid-transform-Cb40tUcA.js} +1 -1
- package/dist/assets/{particles-Cjg6XQEP.js → particles-CJYPIK4T.js} +1 -1
- package/dist/assets/{pixi-authoring-adapter-CMpVEOut.js → pixi-authoring-adapter-zLm6t32A.js} +1 -1
- package/dist/assets/{pixi-live-write-target-714CPh5C.js → pixi-live-write-target-gqB1Bns4.js} +1 -1
- package/dist/assets/{play.command-CIcot8mf.js → play.command-BX18gQb-.js} +2 -2
- package/dist/assets/{presentation-DUidVzGI.js → presentation-DN_Gulux.js} +1 -1
- package/dist/assets/{product-emJUqslE.js → product-BNmDRhyK.js} +1 -1
- package/dist/assets/{profiler.action-Tb9vn81X.js → profiler.action-BcXQPser.js} +1 -1
- package/dist/assets/{profiler.menu-D2hXzK6K.js → profiler.menu-DLSKDlYC.js} +1 -1
- package/dist/assets/{profiler.utility-go2J_Rus.js → profiler.utility-XfyJ4Ybb.js} +1 -1
- package/dist/assets/{project-authoring-session-BvXLxd7m.js → project-authoring-session-CV-InH5U.js} +2 -2
- package/dist/assets/{properties-bone-constraints.inspector-BZ_l2-st.js → properties-bone-constraints.inspector-DjtLF07E.js} +1 -1
- package/dist/assets/{properties-bone.inspector-BZB51VMV.js → properties-bone.inspector-BTrLviuO.js} +1 -1
- package/dist/assets/{properties-collection.inspector-C84oF9Qk.js → properties-collection.inspector-4pRJXdHP.js} +1 -1
- package/dist/assets/{properties-constraints.inspector-BZ5gjhkK.js → properties-constraints.inspector-CGMjJ9yI.js} +1 -1
- package/dist/assets/{properties-data.inspector-BFRP4RBX.js → properties-data.inspector-BYWXnz6t.js} +1 -1
- package/dist/assets/{properties-material.inspector-Z0poViuH.js → properties-material.inspector-DW3L9_Nu.js} +1 -1
- package/dist/assets/{properties-modifiers.inspector-e-sflJxR.js → properties-modifiers.inspector-CIGm19LV.js} +1 -1
- package/dist/assets/{properties-object.inspector-B2MUPsKe.js → properties-object.inspector-C-D5tyP4.js} +1 -1
- package/dist/assets/{properties-output.inspector-Cl8ANiOA.js → properties-output.inspector-BFNleHzM.js} +1 -1
- package/dist/assets/{properties-particles.inspector-g8R7Qtlh.js → properties-particles.inspector-DUhLpScH.js} +1 -1
- package/dist/assets/{properties-physics.inspector-BN1ScnFc.js → properties-physics.inspector-BFz_SKxd.js} +1 -1
- package/dist/assets/{properties-render.inspector-BWmwuLsA.js → properties-render.inspector-DYyK4VAO.js} +1 -1
- package/dist/assets/{properties-scene.inspector-lBiqvysz.js → properties-scene.inspector-BOJ7o61b.js} +1 -1
- package/dist/assets/{properties-texture.inspector-CkIJP_1b.js → properties-texture.inspector-BV23RX7J.js} +1 -1
- package/dist/assets/{properties-view-layer.inspector-bWpA77BN.js → properties-view-layer.inspector-DYVpXCR8.js} +1 -1
- package/dist/assets/{properties-world.inspector-C1GaZ5qr.js → properties-world.inspector-DpihGfpS.js} +1 -1
- package/dist/assets/{r3f-design-session-DbA50oqd.js → r3f-design-session--1XRftri.js} +2 -2
- package/dist/assets/{r3f-physics-binding-yDE4SctS.js → r3f-physics-binding-D7H8JaW0.js} +1 -1
- package/dist/assets/{r3f-source-authoring-adapter-BCy1GWt8.js → r3f-source-authoring-adapter-zqECAe05.js} +1 -1
- package/dist/assets/{react-canvas-navigation-S-IbbVDw.js → react-canvas-navigation-DVpD_2D0.js} +1 -1
- package/dist/assets/{react-inspector.service-Brsft7TJ.js → react-inspector.service-Bv1vBrOj.js} +1 -1
- package/dist/assets/{react-story-board-B-wnwU1y.js → react-story-board-rd1U6EAp.js} +1 -1
- package/dist/assets/{react-three-fiber.esm-BrmmnfPq.js → react-three-fiber.esm-Z3njhfMT.js} +1 -1
- package/dist/assets/{react-three-rapier.esm-ChxOJQrA.js → react-three-rapier.esm-DsRg66Ch.js} +1 -1
- package/dist/assets/{react-world-authoring-adapter-CwnR93ZA.js → react-world-authoring-adapter-D7x1fQ49.js} +1 -1
- package/dist/assets/{realm-services-CsCNzgGK.js → realm-services-CN-61eEJ.js} +1 -1
- package/dist/assets/{reflection-probe-capture.inspector-DGhpuOM-.js → reflection-probe-capture.inspector-BVMieLLF.js} +1 -1
- package/dist/assets/{registry-DVdPAH9u.js → registry-CyI6Aq11.js} +1 -1
- package/dist/assets/{relative-import-specifier-DGpgcbeS.js → relative-import-specifier-DcxN-Zbr.js} +1 -1
- package/dist/assets/{render-env-Dy3Kf2gg.js → render-env-h5HERQrH.js} +1 -1
- package/dist/assets/{render-features-BjJcszQ2.js → render-features-Cfvq_SBW.js} +1 -1
- package/dist/assets/{render-settings-CergIZPU.js → render-settings-hwYf1wv5.js} +1 -1
- package/dist/assets/{resolve-three-l_1-CXHl.js → resolve-three-CJkvlUWq.js} +3 -3
- package/dist/assets/{root-seam-contract-9QibVtGc.js → root-seam-contract-MifQoZQ4.js} +1 -1
- package/dist/assets/{run-selection-DOsR8mOQ.js → run-selection-C1AZsBxI.js} +1 -1
- package/dist/assets/{scene-capture-CrqaUEgL.js → scene-capture-DfdNSDuT.js} +1 -1
- package/dist/assets/{scene-document.service-WItYUlyc.js → scene-document.service-COEvhB25.js} +2 -2
- package/dist/assets/{scene-framing-BxVkSlg3.js → scene-framing-BFUJz9EH.js} +1 -1
- package/dist/assets/{seeded-random-BTqVP8Ii.js → seeded-random-CT60Vm0v.js} +1 -1
- package/dist/assets/{setup-renderer-B2da1u8k.js → setup-renderer-FkSOtbK8.js} +1 -1
- package/dist/assets/{source-object3d-authoring-adapter-BKZ8oj3D.js → source-object3d-authoring-adapter-D_g43IL2.js} +1 -1
- package/dist/assets/{source-persistence-backend-Con5sRZv.js → source-persistence-backend-DXhXbcHd.js} +1 -1
- package/dist/assets/{stage-keyboard-DGE-4Jpn.js → stage-keyboard-BavlReN0.js} +1 -1
- package/dist/assets/{stage-overlay-set-CKtVcxiT.js → stage-overlay-set-DaSD-kEP.js} +1 -1
- package/dist/assets/{stage-presence-markers-tb8yyWjE.js → stage-presence-markers-DABeYLFZ.js} +1 -1
- package/dist/assets/{stage-transform-tools-DdbkruEz.js → stage-transform-tools-CVwbVaHl.js} +1 -1
- package/dist/assets/{standard-viewport-dressing-BmMrgEAi.js → standard-viewport-dressing-CcvhGvJG.js} +1 -1
- package/dist/assets/{state-watch.action-BaJIFmyr.js → state-watch.action-DfpZv7d7.js} +1 -1
- package/dist/assets/{state-watch.menu-ByA3Z9q-.js → state-watch.menu-SvJhuJTF.js} +1 -1
- package/dist/assets/{state-watch.utility-C2Sugdxe.js → state-watch.utility-DKnGsJtm.js} +1 -1
- package/dist/assets/{story-capture-D1xcKwr0.js → story-capture-BFK_ID-Q.js} +1 -1
- package/dist/assets/{story-documents-z4AFSTsH.js → story-documents-B6VxM549.js} +1 -1
- package/dist/assets/{story-documents.service-BNFBCFet.js → story-documents.service-0yUb4nhf.js} +1 -1
- package/dist/assets/{story-documents.service-gHigvC0Y.js → story-documents.service-BfIRLgjz.js} +1 -1
- package/dist/assets/{story-media-presence-Ctf8e6_2.js → story-media-presence-CFQCHxFo.js} +1 -1
- package/dist/assets/{story-pixi-preview-B64Fbglp.js → story-pixi-preview-CATuprki.js} +1 -1
- package/dist/assets/{story-presentation-CioG0A_4.js → story-presentation-BRdH0ChD.js} +1 -1
- package/dist/assets/{story-three-preview-9zj9LGo3.js → story-three-preview-D4pZqkMA.js} +2 -2
- package/dist/assets/{studio-environment-CLaX3ria.js → studio-environment-CRvNlLp8.js} +1 -1
- package/dist/assets/{surface-state-CB3HOhtC.js → surface-state-B9DGFy51.js} +1 -1
- package/dist/assets/{syntactic-prop-specs-Ce1hcg_C.js → syntactic-prop-specs-DBT6-vHl.js} +1 -1
- package/dist/assets/{team-playtest.service-D9-q_kQm.js → team-playtest.service-Duj1NZFc.js} +1 -1
- package/dist/assets/{three-BGqB-uVq.js → three-BJsmD65U.js} +1 -1
- package/dist/assets/{three-authoring-adapter-BO7jI7-8.js → three-authoring-adapter-Cz8KDuKR.js} +1 -1
- package/dist/assets/three-authoring.service-CZVY51US.js +2 -0
- package/dist/assets/{three-ingest-runtime-CzLs2nNM.js → three-ingest-runtime-CAdElDuH.js} +1 -1
- package/dist/assets/{three-integration-qc8Reb1Y.js → three-integration-CFjtFUU-.js} +2 -2
- package/dist/assets/three-integration.service-7jqoQp_l.js +1 -0
- package/dist/assets/{three-projection-core-CFyOC4Fp.js → three-projection-core-EmUNeP2k.js} +1 -1
- package/dist/assets/{three-state-z8gBcifl.js → three-state-Cs7Th7ur.js} +1 -1
- package/dist/assets/{three-story-capture.service-c2yjqEby.js → three-story-capture.service-CTBiiaXF.js} +2 -2
- package/dist/assets/{three-story-model-St9GMyHp.js → three-story-model-D0gr0vkG.js} +1 -1
- package/dist/assets/{three-viewport-presentation-BjXL1Zjv.js → three-viewport-presentation-CzDAAyFp.js} +1 -1
- package/dist/assets/{transform-mode-request-C7qEF7HB.js → transform-mode-request-B9w1y_hg.js} +1 -1
- package/dist/assets/{transport-strip-e122YmzD.js → transport-strip-DfMRjRNy.js} +1 -1
- package/dist/assets/transport.header-utCIDL4y.js +1 -0
- package/dist/assets/{tuples-BUz9vxL7.js → tuples-Bzhmrl2c.js} +1 -1
- package/dist/assets/{ui-board-document-DEqHspRN.js → ui-board-document-CNL8bnU7.js} +2 -2
- package/dist/assets/{user-data-CPxKRceo.js → user-data-UxjaQvdx.js} +1 -1
- package/dist/assets/{utility-view-state-B-gZQZIN.js → utility-view-state-CLA8-L1t.js} +1 -1
- package/dist/assets/{viewport-door-K-5DUW7m.js → viewport-door-BN90Ep9y.js} +1 -1
- package/dist/assets/{viewport-root-presentation-PTTfkoRf.js → viewport-root-presentation-jsbbPD59.js} +1 -1
- package/dist/assets/{viewport-surface-status-BTqSVzg2.js → viewport-surface-status-DdHGQbHo.js} +1 -1
- package/dist/assets/{webworkerAll-DhL2BYVu.js → webworkerAll-BZ2bj2zd.js} +1 -1
- package/dist/assets/{workspace-arrangement-BOOvdRY-.js → workspace-arrangement-Bf-W4FYD.js} +1 -1
- package/dist/assets/{world-documents-FtLCiCQe.js → world-documents-DnzG3hVS.js} +1 -1
- package/dist/assets/{world-root-stage-binding-FTlof7qc.js → world-root-stage-binding-M6fr2Vev.js} +1 -1
- package/dist/assets/{xstate-animation-binding-C06bUoKl.js → xstate-animation-binding-Jeid46sG.js} +1 -1
- package/dist/assets/{xstate-animation-meta-h_xoeBCJ.js → xstate-animation-meta-aAafJ1M9.js} +1 -1
- package/dist-node/cli.js +16 -16
- package/package.json +16 -16
- package/template/vite.config.ts +1 -1
- package/dist/assets/InspectorObjectPreview-CkyqYsEo.js +0 -1
- package/dist/assets/Object3DDocumentViewport-CTE6_O8m.js +0 -2
- package/dist/assets/autoplay.service-Bd6xIgdv.js +0 -1
- package/dist/assets/binding-resolver-BcV7It57.js +0 -2
- package/dist/assets/index-bQE2NA0D.js +0 -1
- package/dist/assets/instances.command-Dj-9DRxh.js +0 -1
- package/dist/assets/network-observer.service-rq9XQOmV.js +0 -1
- package/dist/assets/three-authoring.service-CIJV-GMf.js +0 -2
- package/dist/assets/three-integration.service-DTYLz684.js +0 -1
- package/dist/assets/transport.header-C9_a76-g.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as t}from"./jsx-runtime-DPjLkJKQ.js";import{a as y}from"./three-contract-Dkt6PmWY.js";import{i as x}from"./component-instance-root-
|
|
1
|
+
import{a as t}from"./jsx-runtime-DPjLkJKQ.js";import{a as y}from"./three-contract-Dkt6PmWY.js";import{i as x}from"./component-instance-root-6vlZ9amU.js";import{al as j,aL as i,bQ as v,fe as k,ff as c,a6 as h,eX as S}from"./index-C7p_QQ7P.js";import{constraintsOf as C}from"./constraint-Bp1l8hY-.js";import"./index-nmcBqr7Y.js";import"./index-CtzuWnCS.js";import{u as F}from"./three-state-Cs7Th7ur.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./user-data-UxjaQvdx.js";import"./workspace-arrangement-Bf-W4FYD.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";import"./user-data-CODoGZqA.js";import"./object-marks-BnvSuCTt.js";import"./editor-shell-store-sESsCCic.js";import"./output-pass-HurwNl0G.js";import"./three.module-BLhyNg0e.js";import"./three.core-3arARmh6.js";import"./Pass-D1MRT672.js";import"./editor-layers-DvKAawE7.js";import"./entity-object-CR7fCzb1.js";function g(r,n){return n?y(r.hierarchy,n):null}function b(r){if(!r)return[];const n=x(r),u=new Set,m=a=>{const l=x(a);if(!(a!==r&&n!==void 0&&l!==void 0&&l!==n)){for(const o of C(a))u.add(o);for(const o of a.children)m(o)}};return m(r),[...u]}function w(r,n){return b(g(n,r?.id??null)).length>0}const O={ready:"Ready",disabled:"Disabled",unresolved:"Unresolved",error:"Error"};function D(r){return r==="two-bone-ik"?"Two Bone IK":r==="ccd-ik"?"CCD IK":r==="aim"?"Aim":r==="rotation"?"Rotation":r}function T({adapter:r,nodeId:n}){const u=F(),m=n?u.objectMap.get(n)??g(r,n)??null:null,a=b(m).sort((o,s)=>o.config.order-s.config.order),l=o=>{if(!o)return;const s=r.hierarchy.idForObject3D?.(o);s&&(S(r,[s],{intent:"exact"})||u.shell.select(s))};return t.jsx("div",{style:{display:"grid",gap:10},children:a.map((o,s)=>{const d=o.config,e=o.getSnapshot(),p=d.type==="two-bone-ik"||d.type==="ccd-ik";return t.jsxs("div",{style:{border:`1px solid ${j.boundary.default}`,borderRadius:6,overflow:"hidden"},children:[t.jsxs("div",{style:{alignItems:"center",background:j.surface.raised,display:"flex",gap:8,justifyContent:"space-between",padding:"6px 8px"},children:[t.jsx(i,{children:`${s+1}. ${d.label}`}),t.jsx(i,{tone:"muted",children:D(d.type)})]}),e.message&&(e.status==="error"||e.status==="unresolved")?t.jsx(v,{tone:"error",children:e.message}):null,t.jsxs(k,{children:[t.jsx(c,{label:"Status",children:t.jsx(i,{tone:e.status==="error"||e.status==="unresolved"?"danger":e.status==="ready"?"success":"muted",children:O[e.status]})}),t.jsx(c,{label:"Weight",children:t.jsx(i,{tone:"muted",children:`${Math.round(d.weight*100)}%`})}),p?t.jsx(c,{label:"Chain",children:t.jsx(i,{tone:"muted",children:e.chain.map(f=>f.name||f.type).join(" → ")||"Unresolved"})}):t.jsx(c,{label:"Constrained",children:e.constrained&&r.hierarchy.idForObject3D?.(e.constrained)?t.jsx(h,{size:"compact",onClick:()=>l(e.constrained),children:e.constrained.name||"Select object"}):t.jsx(i,{tone:"muted",children:e.constrained?.name||"Unresolved"})}),e.error!==null?t.jsx(c,{label:e.error.unit==="degrees"?"Angular error":"Solve error",children:t.jsx(i,{tone:"muted",children:e.error.unit==="degrees"?`${e.error.value.toFixed(2)}°`:`${e.error.value.toFixed(3)} m`})}):null,t.jsx(c,{label:"Target",children:e.target&&r.hierarchy.idForObject3D?.(e.target)?t.jsx(h,{size:"compact",onClick:()=>l(e.target),children:e.target.name||"Select target"}):t.jsx(i,{tone:"muted",children:e.target?.name||"Dynamic target"})}),p?t.jsx(c,{label:"Pole",children:e.pole&&r.hierarchy.idForObject3D?.(e.pole)?t.jsx(h,{size:"compact",onClick:()=>l(e.pole),children:e.pole.name||"Select pole"}):t.jsx(i,{tone:"muted",children:e.pole?.name||"None"})}):null]})]},d.id)})})}const ee="selection.inspector",re="Constraints",te="link",ne=450;function oe(r,n){return w(r,n)}function ie({adapter:r,nodeId:n}){return t.jsx(T,{adapter:r,nodeId:n})}export{ie as default,te as icon,oe as match,ne as order,ee as point,re as title};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as B}from"./hierarchy-marks-
|
|
1
|
+
import{i as B}from"./hierarchy-marks-QDNP7a91.js";import{I as o,J as y,cm as p,B as b}from"./three.core-3arARmh6.js";function c(t,n){n(t);for(const e of t.children)B(e)||c(e,n)}const s=new o,f=new p;function d(t){return Number.isFinite(t.min.x)&&Number.isFinite(t.min.y)&&Number.isFinite(t.min.z)&&Number.isFinite(t.max.x)&&Number.isFinite(t.max.y)&&Number.isFinite(t.max.z)}const u=new p,l=new o;function M(t,n,e,i){for(let r=0;r<n.count;r++)n.getMatrixAt(r,u),u.premultiply(n.matrixWorld),i&&u.premultiply(i),l.copy(e).applyMatrix4(u),d(l)&&t.union(l)}function x(t,n,e=null){const i=n.geometry;if(!i)return;const r=h(n,i);if(r){if(n.isInstancedMesh){M(t,n,r,e);return}e?(f.multiplyMatrices(e,n.matrixWorld),s.copy(r).applyMatrix4(f)):s.copy(r).applyMatrix4(n.matrixWorld),d(s)&&t.union(s)}}function h(t,n){const e=t;return t.isSkinnedMesh?(n.boundingBox===null&&n.computeBoundingBox(),n.boundingBox):e.boundingBox!==void 0&&!t.isInstancedMesh?(e.boundingBox===null&&e.computeBoundingBox?.(),e.boundingBox??null):(n.boundingBox===null&&n.computeBoundingBox(),n.boundingBox)}function N(t,n){return c(n,e=>{e.updateWorldMatrix(!1,!1),x(t,e)}),t}const a=new o;function m(t){const n=t.material;return n?Array.isArray(n)?n:[n]:[]}function w(t){const n=m(t);return n.length>0&&n.every(e=>e.depthWrite===!1)}function F(t){const n=m(t);return n.length>0&&n.every(e=>e.side===b)}function I(t,n=[]){return c(t,e=>{e.updateWorldMatrix(!1,!1),a.makeEmpty(),x(a,e),!a.isEmpty()&&n.push({box:a.clone(),overlay:w(e),enclosure:F(e)})}),n}function k(t,n=[]){for(const e of I(t))n.push(e.box);return n}function W(t,n=new o){return n.makeEmpty(),N(n,t)}function v(t,n,e=new o){return e.makeEmpty(),c(t,i=>{i.updateWorldMatrix(!1,!1),x(e,i,n)}),e}class E extends y{entityObject;constructor(n,e){super(new o,e),this.entityObject=n,this.update()}update(){W(this.entityObject,this.box)}}export{E as C,W as a,v as b,I as c,k as d,N as e};
|
package/dist/assets/{contract-system-adapters-C66CNkAk.js → contract-system-adapters-Dx3-ZI4N.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{GAME_SYSTEM_ADAPTERS_SHAPE as a}from"./game-contract-seams-
|
|
1
|
+
import{GAME_SYSTEM_ADAPTERS_SHAPE as a}from"./game-contract-seams-FFGgxMOq.js";import{R as c,C as m,A as f,N as l,d as p,e as u}from"./index-C7p_QQ7P.js";const A={physics:u,networking:p,navigation:l,audio:f,camera:m,renderDebug:c},E={three:"node-id",canvas:"display",dom:null},y=Object.keys(a),S={bound:{},empty:[],malformed:[]};function _(r){return r.present===!1}function h(r,e){const n=[];for(const[t,s]of Object.entries(A[r]))s.optional||typeof e[t]!="function"&&n.push(t);return n}function P(r,e){const n=e?E[e]:null;if(n===null)return null;const t=r.keyedBy==="display"?"display":"node-id";return t===n?null:`declared a ${t}-keyed physics carrier on the ${e} surface, whose gizmo path addresses bodies by ${n} — the four members are all present but nothing on this lane can call them with values they accept (a ${e}-surface carrier declares \`keyedBy: '${n}'\`)`}function b(r,e,n){if(e==null)return{kind:"skip"};if(typeof e!="object")return{kind:"malformed",reason:`declared as ${typeof e}; expected an adapter object or { present: false, evidence }`};if(_(e)){const i=e.evidence;return typeof i!="string"||i.trim()===""?{kind:"malformed",reason:"declared `present: false` with no `evidence` string to back the absence"}:{kind:"empty",evidence:i}}const t=h(r,e);if(t.length>0)return{kind:"malformed",reason:`declared an adapter missing required member(s): ${t.join(", ")}`};const s=r==="physics"?P(e,n):null;return s!==null?{kind:"malformed",reason:s}:{kind:"bound"}}function R(r,e){const n=r?.systemAdapters;if(!n)return S;const t={},s=[],i=[];for(const o of y){const d=b(o,n[o],e);d.kind==="bound"?t[o]=n[o]:d.kind==="empty"?s.push({slot:o,evidence:d.evidence}):d.kind==="malformed"&&i.push({slot:o,reason:d.reason})}return{bound:t,empty:s,malformed:i}}export{y as C,R as p};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{L as C,eL as k,jL as I,aP as E,aQ as A,aC as p,jM as L,jN as R,jO as f,ab as N,jx as x,jP as M,Z as P,r as F}from"./index-
|
|
1
|
+
import{L as C,eL as k,jL as I,aP as E,aQ as A,aC as p,jM as L,jN as R,jO as f,ab as N,jx as x,jP as M,Z as P,r as F}from"./index-C7p_QQ7P.js";import{d as w,S as _,a as D,f as O,u as B}from"./capability-coverage-9jbjkC7w.js";import{p as T,a as S,i as W}from"./live-project-verbs-CgDrfITj.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./game-contract-seams-FFGgxMOq.js";function j(){const t=C();return!t||!k()?null:w({worldId:p()?.config.name??"project",authoringSurface:I(t.scenes,A().map(e=>e.descriptor.id),E().map(e=>e.descriptor.id))})}const V={physics:["@react-three/rapier","@dimforge/rapier3d-compat","@dimforge/rapier2d-compat"],networking:["@colyseus/sdk","colyseus.js"],navigation:["recast-navigation","@recast-navigation/core"],audio:["tone","howler"]};function G(t,e){if(e.dependencies===null)return[];const s=V[t];return s?s.filter(r=>e.dependencies?.includes(r)):[]}function K(t,e){return`this project depends on ${e.join(" + ")}, so "nothing built a ${t} world" is not a settled answer. Reach a terminal state either way: BIND it — declare the game's own ${t} adapter in the root entry's \`systems\` table — or DECLARE the absence with \`absent(reason)\` in that same table. The reason must NAME the dependency and say why it is there while the subsystem is not (a transitive pull, a leftover, a build-only use); a declared absence blind to the shipped dependency grades malformed, not terminal.`}function Y(t,e){const s=e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");if(/^[a-z0-9]+$/i.test(e)){if(new RegExp(`\\b${s}\\b`,"i").test(t))return!0}else if(t.toLowerCase().includes(e.toLowerCase()))return!0;const r=new Set(["compat","core","client","server","node","react","three","libs","api","sdk","util","utils","plugin","plugins","tools","types","browser"]),o=c=>c.toLowerCase().split(/[.\-_/]+/).filter(v=>v.length>=4&&!r.has(v)),[a,d]=e.toLowerCase().startsWith("@")?[e.slice(1,e.indexOf("/")),e.slice(e.indexOf("/")+1)]:["",e];let n=o(d);n.length===0&&(n=o(a));const i=n.map(c=>c.replace(/\d+d?$/,"")).filter(c=>c.length>=4);return[...new Set([...n,...i])].some(c=>new RegExp(`\\b${c.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}\\b`,"i").test(t))}const z="this project's volter.project.json declares no `server` block, so there is no room for a NetworkingAdapter to describe",H={physics:"no mounted root built a physics world — the engine seeds this slot from the root that creates one (a `setup` root, or an R3F tree using the Rapier bridge), so nothing in this game simulates bodies",navigation:"no mounted root registered a navigation adapter — the engine seeds this slot from a world's own NavMeshManager registration, so this game has no navmesh",audio:"no mounted root built an audio context — the engine seeds this slot from the root that creates one, so there is no audio graph for the host to mute, meter or graph",camera:"no mounted root registered a camera-ownership system — the engine ships `createCameraOwnershipSystem` for a game that takes camera control (a cutscene rig), so this game's camera is gameplay-owned throughout",renderDebug:"no mounted root captured a real WebGL2 render context to derive one from — the engine seeds this slot only where the root owns the capture wiring (`adapter/setup-three-root-adapter.ts`), so the Frame debugger and the render-memory view have nothing to show for this game"};function b(t,e){return t==="networking"?"register a NetworkingAdapter from the game's own code (`ctx.registerSystemAdapter('networking', …)`) — this project declares a `server` block, so the editor's Network panel is dark for a game that IS networked":`register a ${t} adapter from the game's own code (\`ctx.registerSystemAdapter('${t}', …)\`), or build the subsystem the engine seeds it from`}function Q(t,e){const s=new Map(e.declaredAbsences.map(r=>[r.slot,r]));return _.map(r=>{const o=s.get(r);if(t[r]!=null)return o?{slot:r,state:"malformed",evidence:`root "${o.rootId}" declares this slot absent — "${o.reason}" — but a ${r} adapter is bound on the live mount. One of the two is wrong: either the declaration is stale (delete the \`absent()\` marker) or something registers an adapter the game does not mean to have.`}:{slot:r,state:"bound",proof:L({slot:r,adapter:t[r],subject:"game"})};const a=G(r,e);if(o){const n=a.filter(c=>!Y(o.reason,c));if(n.length>0)return{slot:r,state:"malformed",evidence:`root "${o.rootId}" declares this slot absent — "${o.reason}" — but this project depends on ${n.join(" + ")} and the reason does not mention it. Either the absence is stale, or it holds and the reason should say why that dependency is present without the subsystem (naming it).`};const i=e.absencesFromLastMount?" — the declaration read at this session’s last play mount; play to re-read it live":"";return{slot:r,state:"empty",attestedBy:"game",evidence:a.length>0?`declared absent by root "${o.rootId}": ${o.reason} (the project does depend on ${a.join(" + ")}; the reason engages with that)${i}`:`declared absent by root "${o.rootId}": ${o.reason}${i}`}}if(r==="networking"&&a.length>0)return{slot:r,state:"empty",attestedBy:"host",evidence:`this project ships ${a.join(" + ")}; the editor observes its room sockets from Play, and nothing is connected while editing`};if(a.length>0)return{slot:r,state:"unanswered",fix:K(r,a)};if(r==="networking")return e.declaresServer?{slot:r,state:"unanswered",fix:b(r)}:{slot:r,state:"empty",attestedBy:"host",evidence:z};const d=H[r];return d?{slot:r,state:"empty",attestedBy:"host",evidence:d}:{slot:r,state:"unanswered",fix:b(r)}})}function U(){const t=x()?.game,e=p()?.rootPath??null;return t?(e!==null&&(l={projectPath:e,absences:t.declaredSystemAbsences??[]}),{absences:t.declaredSystemAbsences??[],fromLastMount:!1}):l!==null&&l.projectPath===e?{absences:l.absences,fromLastMount:!0}:{absences:[],fromLastMount:!1}}let l=null;function $(){if(R()!==null)return null;const t=p();if(!t)return null;const e=f();if(e.length===0||e.every(r=>r.adapter.provenance?.source==="foreign"))return null;const s=U();return w({worldId:t.config.name,systemAdapters:Q(N(),{declaresServer:(t.config.configurations??[]).some(r=>r.kind==="process"&&typeof r.port=="number"),declaredAbsences:s.absences,absencesFromLastMount:s.fromLastMount,dependencies:T()})})}function Z(t){const e=w({worldId:t.worldId,reach:D(t.adapter,t.worldId),surface:t.surface,reachMechanism:null});return{worldId:t.worldId,surface:t.surface,report:e}}function g(){return f().map(Z)}function q(t=g()){const e=t.map(a=>({label:a.worldId,report:a.report})),s=$();s&&e.push({label:null,report:s});const r=S();r&&e.push({label:null,report:r});const o=j();return o&&e.push({label:null,report:o}),e}function J(t){const e=q(t??g());return e.length===0?null:B(p()?.config.name??"session",e)}const y=new Set;let h=null,m=0;function u(){h=null,m=0}function X(){if(M()){u();return}const t=g(),e=J(t);if(!e||e.summary.gaps===0){u();return}const s=f();if(s.length===0){u();return}const r=C()?.regions??[];if(r.length>1){const n=new Set(s.map(i=>i.worldId));if(r.some(i=>!n.has(i.id))){u();return}}if(t.some(n=>n.report.rows.find(i=>i.seam==="editor.capture")?.status!=="ok")){u();return}const o=`session coverage "${e.summary.worldId}"`,a=O(e,o).filter(n=>n.level==="warn"),d=a.map(n=>n.message).join(`
|
|
2
2
|
---
|
|
3
3
|
`);if(h===d?m++:(h=d,m=1),!(m<2))for(const n of a)y.has(n.message)||(y.add(n.message),P.warn(n.message,"coverage"))}const ge="workspace.service",ee=["rootCoverage","systemCoverage","projectCoverage","authoringCoverage"];function te(t){if(t)return{rootCoverage:t.rootCoverage??[],systemCoverage:t.systemCoverage??null,projectCoverage:t.projectCoverage??null,authoringCoverage:t.authoringCoverage??null};const e=$(),s=S(),r=j();return{rootCoverage:g().map(o=>({worldId:o.worldId,surface:o.surface,summary:o.report.summary,rows:o.report.rows.map(a=>({...a}))})),systemCoverage:e?{summary:e.summary,rows:e.rows.map(o=>({...o}))}:null,projectCoverage:s?{summary:s.summary,rows:s.rows.map(o=>({...o}))}:null,authoringCoverage:r?{summary:r.summary,rows:r.rows.map(o=>({...o}))}:null}}function he(){const t=F().session,e=t.reportFacet(te,{reusableKeys:ee}),s=t.onSample(X),r=t.onCommandDispatched(o=>{o==="restart"&&W()});return()=>{e(),s(),r()}}export{ge as point,he as start};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{assertNever as le}from"./adapter-surface-Y37Nzcyw.js";import{createRootBinding as ue}from"./binding-Bmxqznjk.js";import{stackOrder as B,resolveClaimingRoot as V}from"./root-stacking-BEd9ZvxC.js";import{createAssetCache as fe}from"./assets-BcrMQHRv.js";import{createHostRenderer as me}from"./setup-renderer-
|
|
1
|
+
import{assertNever as le}from"./adapter-surface-Y37Nzcyw.js";import{createRootBinding as ue}from"./binding-Bmxqznjk.js";import{stackOrder as B,resolveClaimingRoot as V}from"./root-stacking-BEd9ZvxC.js";import{createAssetCache as fe}from"./assets-BcrMQHRv.js";import{createHostRenderer as me}from"./setup-renderer-FkSOtbK8.js";import{T as pe}from"./three.module-BLhyNg0e.js";import{T as K,c as he,p as ge,r as we,a as ye,D as be,b as ve}from"./seeded-random-CT60Vm0v.js";import{c as ee,a as Re,r as Ee,D as ke,g as Se}from"./debug-registry-CurxbdJb.js";import{formatLoopGateMessage as $e,formatAudioGateMessage as Pe}from"./loop-gate-report-N52EWFGD.js";import{bindScopedSystem as Ae}from"./system-slot-E2mEdiih.js";import{hasUserData as Oe}from"./user-data-CODoGZqA.js";import{dY as F,kI as I}from"./index-C7p_QQ7P.js";import{c as De}from"./performance-profiler-CMbwGBuk.js";const xe=1e3;function Fe(e){const t=e.fixedTimestep??.016666666666666666,n=e.maxSubSteps??8,s=e.externalDrive??!1;let l=0,d=0,f=!1,w=0,g=1,b=!1,r=!1;function o(){s||!r||typeof document>"u"||(document.hidden?f&&(f=!1,cancelAnimationFrame(w),b=!0):b&&(b=!1,f=!0,d=performance.now(),l=0,w=requestAnimationFrame(p)))}function i(){o()}function p(E){if(!f)return;w=requestAnimationFrame(p);const v=(E-d)/1e3;d=E;const $=ge(l,v,g,{fixedDt:t,maxSubSteps:n});l=$.accumulator;for(let A=0;A<$.steps;A++)e.update(t);e.render?.($.alpha,$.displayDt)}return{start(){if(!f&&(f=!0,b=!1,d=performance.now(),l=0,!s)){if(!r&&typeof document<"u"&&(document.addEventListener("visibilitychange",i),r=!0),typeof document<"u"&&document.hidden){f=!1,b=!0;return}w=requestAnimationFrame(p)}},stop(){f=!1,b=!1,cancelAnimationFrame(w),r&&typeof document<"u"&&(document.removeEventListener("visibilitychange",i),r=!1)},get isRunning(){return o(),f},get liveness(){return o(),b||f&&!s&&performance.now()-d>xe?"loop-starved":f?"running":"stopped"},set timeScale(E){const v=he(E);v!==E&&console.warn(`[game-loop] timeScale ${E} is out of range [${K.min}, ${K.max}]; clamped to ${v}.`),g=v},get timeScale(){return g},get fixedDt(){return t}}}const Te={cancel(){}};function j(e){return new DOMException(e,"AbortError")}function H(e,t){if(!Number.isFinite(t)||t<0)throw new RangeError(`SimClock.${e}: seconds must be a finite, non-negative number, got ${t}`)}function Ce(e){const t=e.dispose;let n=0,s=0,l=0,d=!1;const f=new Set,w=new Set;function g(r){r.cancelled||(r.cancelled=!0,f.delete(r),r.detachAbort?.(),r.detachAbort=null)}function b(r,o,i){H("after",r);const p=i?.signal;if(d||p?.aborted)return Te;const E={dueAt:n+r,seq:l++,fn:o,cancelled:!1,detachAbort:null};if(f.add(E),p){const v=()=>g(E);p.addEventListener("abort",v,{once:!0}),E.detachAbort=()=>p.removeEventListener("abort",v)}return{cancel(){g(E)}}}return{now:()=>n,tickNow:()=>s,after:b,delay(r,o){H("delay",r);const i=o?.signal;return i?.aborted?Promise.reject(j("SimClock.delay: aborted before it was scheduled")):d?Promise.reject(j("SimClock.delay: the sim clock is disposed")):new Promise((p,E)=>{let v=null,$=null,A=!1;const D=()=>{A=!0,w.delete(T),$?.(),$=null};function T(C){A||(D(),v?.cancel(),E(j(C)))}if(v=b(r,()=>{A||(D(),p())}),w.add(T),i){const C=()=>T("SimClock.delay: aborted");i.addEventListener("abort",C,{once:!0}),$=()=>i.removeEventListener("abort",C)}})},disposeAfter(r,o){return H("disposeAfter",o),b(o,()=>t(r))},flush(r){if(d||(n=r,s++,f.size===0))return;const o=[];for(const i of f)!i.cancelled&&i.dueAt<=n&&o.push(i);if(o.length!==0){o.sort((i,p)=>i.dueAt-p.dueAt||i.seq-p.seq);for(const i of o)if(!i.cancelled){g(i);try{i.fn()}catch(p){console.error("[sim-clock] timer callback threw:",p)}}}},dispose(){if(d)return;d=!0;for(const o of f)o.detachAbort?.(),o.detachAbort=null,o.cancelled=!0;f.clear();const r=[...w];w.clear();for(const o of r)o("SimClock: disposed while a delay was pending")}}}const Me=ee("sim-clock");function Le(e,t){Me.set(e,t)}function Ie(e,t="world"){const n=new Map,s=[],l=new Map;let d=0;for(const r of F)n.set(r,[]);let f=!1;const w=new Map;for(const r of F)w.set(r,new Set);const g=new Set;function b(r,o,i){const p=l.get(r)??r.name??`anonymous-${++d}`;l.set(r,p),e?.beginSystem(t,o,p);try{r(i)}catch(E){const v=r.name?`"${r.name}"`:"(anonymous)";console.error(`[system-runner] system ${v} in phase "${o}" threw:`,E)}finally{e?.endSystem(t,o,p)}}return{add(r,o,i){const p=n.get(r);if(!p)throw new Error(`Unknown phase: ${r}. Valid phases: ${F.join(", ")}`);p.push(o),l.set(o,i?.name??o.name??`anonymous-${++d}`)},remove(r,o){const i=n.get(r);if(!i)return;const p=i.indexOf(o);p!==-1&&i.splice(p,1),w.get(r)?.delete(o)},register(r){const o=n.get(r.phase);if(!o)throw new Error(`Unknown phase: ${r.phase}. Valid phases: ${F.join(", ")}`);o.push(r.update),l.set(r.update,r.name??r.update.name??`anonymous-${++d}`),s.push(r)},unregister(r){const o=n.get(r.phase);if(o){const p=o.indexOf(r.update);p!==-1&&o.splice(p,1)}w.get(r.phase)?.delete(r.update);const i=s.indexOf(r);i!==-1&&s.splice(i,1),g.delete(r),r.dispose?.()},runInit(){const r=[...s].sort((o,i)=>F.indexOf(o.phase)-F.indexOf(i.phase));for(const o of r)o.init?.()},runDispose(){for(const r of s){const o=n.get(r.phase);if(o){const i=o.indexOf(r.update);i!==-1&&o.splice(i,1)}r.dispose?.()}s.length=0},runPhase(r,o){const i=n.get(r);if(!i)throw new Error(`Unknown phase: ${r}. Valid phases: ${F.join(", ")}`);const p=w.get(r),E=[];for(const v of i)f&&!p.has(v)?E.push(v):b(v,r,o);for(const v of E)b(v,r,o)},run(r){for(const o of F)this.runPhase(o,r)},markEngineBoundary(){for(const r of F){const o=w.get(r);for(const i of n.get(r))o.add(i)}for(const r of s)g.add(r);f=!0},removeAllNonEngine(){if(!f)return;const r=s.filter(i=>g.has(i)),o=s.filter(i=>!g.has(i));s.length=0,s.push(...r);for(const i of o)i.dispose?.();for(const i of F){const p=n.get(i),E=w.get(i),v=p.filter($=>E.has($));p.length=0,p.push(...v)}},count(r){if(r)return n.get(r)?.length??0;let o=0;for(const i of n.values())o+=i.length;return o}}}function _e(e){if(!e)return"<unknown call site — no stack captured>";const t=e.split(`
|
|
2
2
|
`);return(t[2]??t[1]??t[0]??"<unknown call site>").trim()}function Ge(e=t=>{console.warn(t)}){const t=new Set;let n;function s(){const l=_e(new Error().stack);return t.has(l)||(t.add(l),e(`[determinism] the global Math.random generator was drawn from during a gameplay frame while this project declares determinism.seededRandom — use ctx.random() / ctx.random.stream(name) instead. Call site:
|
|
3
3
|
${l}`)),n()}return{enable(){n=Math.random,Math.random=s},disable(){Math.random===s&&n&&(Math.random=n,n=void 0)}}}const te=ee("gameplay-rng-trap");function Ne(e,t){te.set(e,t)}function At(e){return te.get(e)??null}const ze=F.filter(e=>e===I.PRE_RENDER||e===I.RENDER);function U(e){const{id:t,kind:n,pausable:s=!0,adapter:l,mounted:d,scene:f,canvasRoot:w,container:g,physics:b,collisions:r,physics2d:o,camera:i,frame:p,binding:E=null}=e;if(n==="three"&&!f)throw new Error(`RootInstance "${t}" (kind: three): a three world requires a scene — pass \`scene\` in RootInstanceInit.`);if(n==="canvas"&&w==null)throw new Error(`RootInstance "${t}" (kind: canvas): a canvas world requires a native substrate root — pass \`canvasRoot\` in RootInstanceInit.`);if(n==="dom"&&!g)throw new Error(`RootInstance "${t}" (kind: react): a react world requires a container — pass \`container\` in RootInstanceInit.`);let v=!1;const $=d.dispose.bind(d);return d.dispose=()=>{v=!0,$()},{id:t,kind:n,pausable:s,adapter:l,mounted:d,physics:b,collisions:r,physics2d:o,camera:i,frame:p?{runPhase(D,T){v||p.runPhase(D,T)},endFrame(){v||p.endFrame?.()}}:void 0,binding:E,get disposed(){return v},threeScene(){if(n!=="three"||!f)throw new Error(`RootInstance "${t}" (kind: ${n}): threeScene() requested but this world is not a three world`);return f},canvasRoot(){if(n!=="canvas"||w===void 0||w===null)throw new Error(`RootInstance "${t}" (kind: ${n}): canvasRoot() requested but this world is not a canvas world`);return w},reactRoot(){if(n!=="dom"||!g)throw new Error(`RootInstance "${t}" (kind: ${n}): reactRoot() requested but this world is not a react world`);return g}}}function qe(e){const{physics:t,rapierWorld:n}=e;return!t||!n?null:{physics:t,rapierWorld:n}}function je(e,t){const n=[];e.traverse(s=>n.push(s));for(const s of t){const l=qe(s);if(l)for(const d of n){const f=l.physics.get(d);f&&(l.rapierWorld.removeRigidBody(f.body),l.physics.remove(d))}}e.removeFromParent();for(const s of n){const l=s;Oe(s,"__sharedGeometry")||l.geometry?.dispose();const d=l.material;if(Array.isArray(d))for(const f of d)f.dispose();else d?.dispose()}}function He(e){return[]}function Be(e){const t=[],n=De(),s=Ie(n.systemObserver,"game"),l=ye(e.seed??be),d=Ge();let f=!1;const w={setEnabled(a){f=a},get enabled(){return f}};let g=0,b=0,r=0;const o=new Set,i=Ce({dispose:a=>je(a,t.flatMap(He))}),p=Re({getTick:()=>g,getSimT:()=>b,getFixedDt:()=>e.loop.fixedDt,getDefaultRootId:()=>t.length>0?v().id:null,getLoopLiveness:()=>e.loop.liveness});let E=!1;function v(){if(t.length===0)throw new Error("Game.defaultRoot: no roots registered yet");return t.find(a=>a.kind==="three")??t[0]}const $=new Set,A=new Set,D=new Map,T=new Map;function C(){const a={debug:p.adapter},h=new Map([["debug","(game)"]]),k=(y,c,R)=>{for(const u of Object.keys(c)){if(c[u]===void 0)continue;const m=h.get(u);if(m!==void 0){if(a[u]===c[u]||R?.has(u))continue;$.has(u)||($.add(u),console.warn(`[game] systemAdapters: "${u}" is registered by both ${m} and ${y} — the FIRST registration (${m}) wins; the later one is shadowed (game-scoped system adapters).`));continue}a[u]=c[u],h.set(u,y)}};for(const y of t){const c=D.get(y.id);c&&k(`world "${y.id}" (declared systems export)`,c);const R=y.mounted.systems;R&&k(`world "${y.id}"`,R,c?new Set(Object.keys(c)):void 0)}return a}let P=!1;const x=new Set;function _(a,h,k){const y=`${a}:${h}`;if(x.has(y))return;x.add(y);const c=a==="loop"?$e({worldId:h,reason:k}):Pe({worldId:h,reason:k});console.warn(c)}const L=new WeakMap;function z(a){for(const h of t){if(h.disposed||!h.pausable)continue;h.mounted.drivesOwnLoop&&(h.mounted.setPaused?h.mounted.setPaused(a):a&&_("loop",h.id,"self-driven world, adapter declares no setPaused capability"));const k=D.get(h.id)?.audio??h.mounted.systems?.audio;k?a?(L.has(k)||L.set(k,k.isMuted()),k.setMuted(!0)):L.has(k)&&(k.setMuted(L.get(k)),L.delete(k)):a&&!T.get(h.id)?.some(y=>y.slot==="audio")&&_("audio",h.id,"no SystemAdapters.audio on this world")}}function G(a,h){f&&d.enable(),n.beginFrame();const k=h?.skipRenderPhases??!1,y=h?.onlyFrozen??!1,c=t.length;E=!1;for(let u=0;u<c;u++){const m=t[u];if(!m.disposed){if(y){if(P&&m.pausable&&!m.mounted.drivesOwnLoop){E=!0;break}}else if(m.mounted.drivesOwnLoop?!P||!m.pausable||!m.mounted.setPaused:!P||!m.pausable){E=!0;break}}}let R=!1;if(!y)for(let u=0;u<c;u++){const m=t[u];if(!m.disposed&&m.mounted.drivesOwnLoop&&(!P||!m.pausable||!m.mounted.setPaused)){R=!0;break}}if(y){for(const u of F){n.beginPhase(),E&&s.runPhase(u,a);for(let m=0;m<c;m++){const S=t[m];if(!S.disposed&&!S.mounted.drivesOwnLoop&&P&&S.pausable)try{S.frame?.runPhase(u,a)}catch(O){console.error(`[game] world "${S.id}" (kind: ${S.kind}) runPhase("${u}") threw (step()):`,O)}}n.endPhase(u)}for(let u=0;u<c;u++){const m=t[u];if(!m.disposed&&!m.mounted.drivesOwnLoop&&P&&m.pausable)if(R=!0,m.frame)try{m.frame.endFrame?.()}catch(S){console.error(`[game] world "${m.id}" (kind: ${m.kind}) endFrame() threw (step()):`,S)}else try{m.mounted.update?.(a)}catch(S){console.error(`[game] world "${m.id}" (kind: ${m.kind}) update() threw (step()):`,S)}}}else{for(const u of F){if(n.beginPhase(),!(k&&(u===I.PRE_RENDER||u===I.RENDER))){s.runPhase(u,a);for(let S=0;S<c;S++){const O=t[S];if(O.disposed||O.mounted.drivesOwnLoop)continue;const W=P&&O.pausable;if(W&&u!==I.RENDER)continue;const de=W?0:a;try{O.frame?.runPhase(u,de)}catch(ce){console.error(`[game] world "${O.id}" (kind: ${O.kind}) runPhase("${u}") threw:`,ce)}}}n.endPhase(u)}for(let u=0;u<c;u++){const m=t[u];if(!(m.disposed||m.mounted.drivesOwnLoop||P&&m.pausable)){if(R=!0,m.frame)try{m.frame.endFrame?.()}catch(O){console.error(`[game] world "${m.id}" (kind: ${m.kind}) endFrame() threw:`,O)}else if(!(k&&m.mounted.updateCadence==="display"))try{m.mounted.update?.(a)}catch(O){console.error(`[game] world "${m.id}" (kind: ${m.kind}) update() threw:`,O)}}}}R&&(g++,b+=a,i.flush(b)),n.endFrame(),f&&d.disable()}function q(a,h){if(r=a,f&&d.enable(),n.beginFrame(),o.size>0)for(const y of[...o])try{y(a,h)}catch(c){console.error("[game] an onRenderStep callback threw:",c)}const k=t.length;for(const y of ze){n.beginPhase(),s.runPhase(y,h);for(let c=0;c<k;c++){const R=t[c];if(R.disposed||R.mounted.drivesOwnLoop)continue;const u=P&&R.pausable;if(!(u&&y!==I.RENDER))try{R.frame?.runPhase(y,u?0:h)}catch(m){console.error(`[game] world "${R.id}" (kind: ${R.kind}) runPhase("${y}") threw (display frame):`,m)}}n.endPhase(y)}for(let y=0;y<k;y++){const c=t[y];if(c.disposed||c.mounted.drivesOwnLoop||c.frame||c.mounted.updateCadence!=="display")continue;const R=P&&c.pausable;try{c.mounted.update?.(R?0:h)}catch(u){console.error(`[game] world "${c.id}" (kind: ${c.kind}) update() threw (display frame):`,u)}}n.endFrame(),f&&d.disable()}const M={loop:e.loop,assets:e.assets,playtest:e.playtest??null,profiler:n,systems:s,get roots(){return t},world(a){return t.find(h=>h.id===a)??null},get defaultRoot(){return v()},get systemAdapters(){return C()},subscribeSystemAdapters(a){return A.add(a),()=>A.delete(a)},notifySystemAdaptersChanged(){for(const a of A)a()},get declaredSystemAbsences(){return[...T.values()].flat()},installDeclaredSystemAdapters(a,h,k=[]){const y=t.find(u=>u.id===a);if(!y)throw new Error(`installDeclaredSystemAdapters: no mounted root is named "${a}" (mounted: ${t.map(u=>`"${u.id}"`).join(", ")||"none"}).`);if(D.has(a))throw new Error(`installDeclaredSystemAdapters: root "${a}" already installed its declared systems — a declaration is static and installs exactly once per mount.`);const c=y.mounted.systemScope??y.mounted,R=Object.fromEntries(Object.entries(h).map(([u,m])=>[u,m===void 0?void 0:Ae(m,c)]));D.set(a,R),T.set(a,k),M.notifySystemAdaptersChanged()},play:{get paused(){return P},pause(){P||(P=!0,z(!0))},resume(){P&&(P=!1,z(!1))},step(a=1/60){if(P)for(const h of t)h.disposed||!h.pausable||!h.mounted.drivesOwnLoop||h.mounted.setPaused&&(h.mounted.step?h.mounted.step():_("loop",h.id,"self-driven world, adapter declares no step capability"));G(a,{onlyFrozen:!0})}},registerRoot(a){if(t.some(h=>h.id===a.id))throw new Error(`Game.registerRoot: duplicate world id "${a.id}"`);if(t.some(h=>h.mounted===a.mounted))throw new Error(`Game.registerRoot: world "${a.id}" shares its \`mounted\` object with an already-registered world ("${t.find(h=>h.mounted===a.mounted).id}") — the same mount cannot be registered twice.`);t.push(a),M.notifySystemAdaptersChanged(),a.mounted.drivesOwnLoop&&a.kind!=="dom"&&!a.mounted.observe&&console.warn(`[game] world "${a.id}" (kind: ${a.kind}, adapter: "${a.adapter.id}"): no state bridge — this mounted game has no \`observe\` (RootStateObserver); the editor's observations cannot subscribe to its state.`)},runFrame(a,h){G(a,h)},runRenderFrame(a,h){q(a,h)},get renderAlpha(){return r},onRenderStep(a,h){const k=h?.signal;if(k?.aborted)return()=>{};o.add(a);let y=null;const c=()=>{o.delete(a),y?.(),y=null};return k&&(k.addEventListener("abort",c,{once:!0}),y=()=>k.removeEventListener("abort",c)),c},runTicks(a,h){if(!Number.isInteger(a)||a<0)throw new RangeError(`Game.runTicks: n must be a non-negative integer, got ${a}`);if(P)throw new ke("RUN_TICKS_PAUSED","Game.runTicks: refused — Game.play.paused is true; stepping the frozen set is Game.play.step()'s contract, not runTicks'");const k=h?.render??"last",y=e.loop.fixedDt;for(let c=0;c<a;c++){const R=c===a-1;G(y,{skipRenderPhases:k==="all"?!1:k==="none"?!0:!R})}},dispose(){i.dispose(),p.strip()}};return Ee(M,p),p.setRunTicksTarget({runTicks:M.runTicks}),we(M,l),Ne(M,w),Le(M,i),M}function Ue(e){B(e).forEach((n,s)=>{n.canvas.style.pointerEvents=s===0?"auto":"none"})}const X=["pointerdown","pointerup","pointermove","click","wheel"];function Ye(e){const t=e,n=["clientX","clientY","screenX","screenY","offsetX","offsetY","button","buttons","ctrlKey","altKey","shiftKey","metaKey","pointerId","pointerType","pressure","isPrimary","deltaX","deltaY","deltaZ","deltaMode"],s={bubbles:!0,cancelable:!0,composed:!0};for(const l of n)l in t&&(s[l]=t[l]);return s}const ne=new WeakSet;function We(e,t){const n=globalThis,s=t.type==="wheel"?n.WheelEvent:t.type.startsWith("pointer")?n.PointerEvent:n.MouseEvent??n.PointerEvent;if(!(!s||typeof e.dispatchEvent!="function"))try{const l=new s(t.type,Ye(t));ne.add(l),e.dispatchEvent(l)}catch{}}function Ve(e,t){Ue(t);const n=new Map(t.map(d=>[d.id,d])),s=B(t)[0]?.id,l=d=>{if(ne.has(d))return;const f=e.getBoundingClientRect?.()??{left:0,top:0},w=d.clientX??0,g=d.clientY??0,b=w-f.left,r=g-f.top,o=V(t,b,r);if(o&&o!==s){const i=n.get(o);i&&(d.stopPropagation(),We(i.canvas,d))}};for(const d of X)e.addEventListener?.(d,l,!0);return{resolveClaim:(d,f)=>V(t,d,f),dispose(){for(const d of X)e.removeEventListener?.(d,l,!0)}}}function re(e){return new URLSearchParams(e.search).get(ve)==="1"}const Ke=[I.PRE_RENDER,I.RENDER];async function Xe(e){const t=Qe(e);for(const n of Ke){e.systems.runPhase(n,0);for(const s of t)s.frame.runPhase(n,0)}await et()}function Qe(e){const t=[];for(const n of e.roots){if(n.mounted.drivesOwnLoop){Q(n.id,"drives its own loop — renderOnce() cannot frame-gate it");continue}if(!n.frame){Q(n.id,`(kind: ${n.kind}) has no phase hooks — renderOnce() cannot drive it (opaque/foreign mount with no frame-gated entry point)`);continue}t.push({id:n.id,frame:n.frame})}return t}function Q(e,t){console.warn(`[render-control] world "${e}" ${t}.`)}function Ze(e){const t=[];for(const n of e.roots){if(n.mounted.drivesOwnLoop){t.push(`world "${n.id}" drives its own loop — cannot be frame-gated for deterministic capture (the policy is to FAIL LOUDLY, or be excluded only by an explicit declared policy).`);continue}n.frame||t.push(`world "${n.id}" (kind: ${n.kind}) has no phase hooks — an opaque/foreign mount with no frame-gated entry point cannot participate in deterministic capture.`)}return t}function Z(e){let t=0,n=0;const s=[...e.children??[]];for(;s.length>0;){const l=s.pop();t++,l.userData?.entityId!==void 0&&n++,l.children&&s.push(...l.children)}return{nodes:t,entities:n}}function Je(e){const t=[];for(const n of e.roots)n.kind==="three"?t.push({id:n.id,kind:n.kind,...Z(n.threeScene())}):n.kind==="canvas"&&n.mounted.kind==="canvas"&&n.mounted.substrate.name==="pixi"&&t.push({id:n.id,kind:n.kind,...Z(n.canvasRoot())});return t}function J(){return new Promise(e=>{requestAnimationFrame(()=>e())})}async function et(){await J(),await J()}async function N(e){if(!e)return{status:"not-applicable"};try{return await e(),{status:"ready"}}catch(t){return{status:"error",detail:t instanceof Error?t.message:String(t)}}}async function tt(){if(typeof document>"u"||!document.fonts)return{status:"not-applicable"};try{return await document.fonts.ready,{status:"ready"}}catch(e){return{status:"error",detail:e instanceof Error?e.message:String(e)}}}async function nt(e){const[t,n,s,l,d,f]=await Promise.all([N(e.assets),N(e.shaders),tt(),N(e.sequences),N(e.tone),N(e.scene)]);return{assets:t,shaders:n,fonts:s,sequences:l,tone:d,scene:f}}function rt(e){const t=e.location??window.location;if(!re(t))return;const{game:n,clock:s,readiness:l={}}=e,d=e.target??window,f=e.frameAdvancers??[],w=e.simulateFixedDt??1/60,g=e.excludedFromDeterminism??[],b={seek(r){s.seek(r)},seekFrame(r,o){s.seekFrame(r,o)},advanceFrame(r){for(const o of f)o(r)},renderOnce(){return Xe(n)},ready(){return nt(l)},simulateSubsteps(r){for(let o=0;o<r;o++)n.runFrame(w)},excludedFromDeterminism(){return[...g,...Ze(n)]},simulateFixedDt(){return w},perfSample(r){const o=n.profiler,i=o.enabled;o.enabled=!0,o.clear();const p=[];try{for(let E=0;E<r;E++){n.runFrame(w);const v=o.getSnapshot(),$=v.frames.at(-1);p.push({cpuMs:$?.cpuMs??0,phases:Object.fromEntries(($?.phases??[]).map(A=>[A.name,A.ms])),render:{...v.render}})}}finally{o.enabled=i}return{frames:p,worlds:Je(n)}}};return d.__volterRender=b,b}function oe(e,t,n,s){const l=s?.pausable??!0,d=U({id:s?.id??"main",kind:"three",pausable:l,adapter:t,mounted:n,scene:n.scene,binding:Y(e,s?.declaration,{surface:"three",adapter:t},n,l)});return e.registerRoot(d),d}function Y(e,t,n,s,l){return t?ue({...t,adapter:n,mounted:s,pausable:l,debugRegistry:Se(e)}):null}function se(e,t,n,s){const l=s?.id??"main",d=s?.pausable??!0,f=U({id:l,kind:"canvas",pausable:d,adapter:t,mounted:n,canvasRoot:n.substrate.root,binding:Y(e,s?.declaration,{surface:"canvas",adapter:t},n,d)});return e.registerRoot(f),f}function ie(e,t,n,s,l){const d=l?.pausable??!0,f=U({id:l?.id??"main",kind:"dom",pausable:d,adapter:t,mounted:n,container:s,binding:Y(e,l?.declaration,{surface:"dom",adapter:t},n,d)});return e.registerRoot(f),f}async function ot(e){return mt(e)}function st(e){return{domElement:e,render(){},setPixelRatio(){},setClearColor(){},setSize(){},dispose(){},forceContextLoss(){}}}function ae(e,t){try{e.mounted.dispose()}finally{e.renderer?.dispose(),e.renderer?.forceContextLoss();try{(e.element.parentNode??t).removeChild(e.element)}catch{}}}async function it(e,t){const{game:n,canvas:s,w:l,h:d,dpr:f,isBottom:w,headless:g,assets:b,antialias:r}=t,o=g?st(s):me(s,l,d,r===void 0?void 0:{antialias:r},{alpha:!w,preserveDrawingBuffer:!0});o.setSize(l,d,!1),s.style.width="100%",s.style.height="100%",o.setPixelRatio(f),w||o.setClearColor(0,0);const i={three:pe,surface:{canvas:s,width:l,height:d},renderer:o,assets:b,headless:g,game:n},p=await e.adapter.mount(i);return oe(n,e.adapter,p,{id:e.id,pausable:e.pausable,declaration:e.declaration}),{mountedEntry:{id:e.id,kind:"three",element:s,mounted:p,renderer:o},routerEntry:{id:e.id,zOrder:e.zOrder??0,canvas:s,hitTest:e.hitTest}}}async function at(e,t){const{game:n,canvas:s,w:l,h:d,dpr:f,headless:w,isBottom:g}=t,b={canvas:s,width:l,height:d,game:n,headless:w,dpr:f,transparent:!g,preserveDrawingBuffer:!0},r=await e.adapter.mount(b);return se(n,e.adapter,r,{id:e.id,pausable:e.pausable,declaration:e.declaration}),{mountedEntry:{id:e.id,kind:"canvas",element:s,mounted:r,renderer:void 0},routerEntry:{id:e.id,zOrder:e.zOrder??0,canvas:s,hitTest:e.hitTest??(r.hitTest?(o,i)=>r.hitTest(o,i):void 0)}}}async function dt(e,t,n){n.style.pointerEvents="none",n.style.width="100%",n.style.height="100%";const s={container:n,game:t},l=await e.adapter.mount(s);return ie(t,e.adapter,l,n,{id:e.id,pausable:e.pausable,declaration:e.declaration}),{mountedEntry:{id:e.id,kind:"dom",element:n,mounted:l,renderer:void 0}}}function ct(e){return()=>{}}async function lt(e,t,n){const{surfacesById:s,container:l,...d}=n,f=[],w=[];try{for(const g of e){const b=g.id===t;if(g.kind==="dom"){const E=s.get(g.id),{mountedEntry:v}=await dt(g,d.game,E);f.push(v);continue}const r=s.get(g.id),o={...d,canvas:r,isBottom:b};let i,p;g.kind==="three"?{mountedEntry:i,routerEntry:p}=await it(g,o):g.kind==="canvas"?{mountedEntry:i,routerEntry:p}=await at(g,o):le(g,"create-runtime mount loop"),f.push(i),w.push(p)}}catch(g){for(let b=f.length-1;b>=0;b--){const r=f[b];try{ae(r,l)}catch(o){console.error(`createGameRuntime: rolling back root "${r.id}" after a mount failure threw:`,o)}}throw g}return{mountedEntries:f,routerEntries:w}}function ut(e,t,n){const s=n??(typeof window<"u"?window:void 0);if(s!==void 0)return rt({game:e,clock:{seek(){},seekFrame(){}},readiness:{scene(){}},location:t,target:s}),()=>{delete s.__volterRender}}function ft(e,t,n){try{e.dispose()}catch(s){console.error("createGameRuntime: disposing the game after a mount failure threw:",s)}for(const s of t)try{(s.parentNode??n).removeChild(s)}catch{}}async function mt(e){const{container:t,roots:n,width:s,height:l,headless:d=!1,seed:f,playtest:w}=e;if(n.length===0)throw new Error("createGameRuntime: `roots` must contain at least one root.");const g=n,b=Math.max(1,s??t.clientWidth??0),r=Math.max(1,l??t.clientHeight??0),o=d?1:Math.min(typeof window<"u"&&window.devicePixelRatio||1,2);t.style.position||(t.style.position="relative");const i=g.map(c=>({id:c.id,zOrder:c.zOrder??0,hitTest:c.hitTest})),p=B(i),E=p[0]?.id,v=new Map(g.map(c=>[c.id,c.kind])),$=new Map;p.forEach((c,R)=>{const u=v.get(c.id)==="dom",m=document.createElement(u?"div":"canvas");if(m.dataset.volterRootSurface="true",m.dataset.volterRootId=c.id,!u){const S=m;S.width=b,S.height=r}m.style.cssText=`position:absolute;top:0;left:0;width:100%;height:100%;z-index:${R+1};contain:layout paint;`,t.appendChild(m),$.set(c.id,m)});const A=fe(),D=e.renderControl?.location??(typeof window<"u"?window.location:void 0),T=D!==void 0&&re(D);let C=!1;const P=Fe({fixedTimestep:1/60,maxSubSteps:8,externalDrive:T,update:c=>{C&&x.runFrame(c,{skipRenderPhases:!0})},render:(c,R)=>{C&&x.runRenderFrame(c,R)}}),x=Be({loop:P,assets:A,seed:f,playtest:w});let _;try{_=await lt(g,E,{game:x,surfacesById:$,container:t,w:b,h:r,dpr:o,headless:d,assets:A,antialias:e.antialias})}catch(c){throw ft(x,$.values(),t),c}const{mountedEntries:L,routerEntries:z}=_,G=Ve(t,z);C=!0,P.start();const q=ct(),M=T&&D!==void 0?ut(x,D,e.renderControl?.target):void 0;let a;const h=new Promise(c=>{a=c});let k=!1;function y(){if(k)return;k=!0;const c=[],R=(u,m)=>{try{m()}catch(S){c.push({step:u,error:S})}};try{R("loop.stop",()=>P.stop()),R("router.dispose",()=>G.dispose());for(const u of L)R(`root "${u.id}"`,()=>ae(u,t));R("game.dispose",()=>x.dispose()),R("dev globals",()=>q()),R("render harness",()=>M?.())}finally{Promise.allSettled(L.map(u=>u.mounted.disposeComplete??Promise.resolve())).then(()=>a())}if(c.length>0)throw new AggregateError(c.map(u=>u.error),`Game session teardown failed in ${c.length} step(s): ${c.map(u=>u.step).join(", ")}. Every other step still ran.`)}return{stop:y,stopComplete:h,pause(){x.play.pause()},resume(){x.play.resume()},step(){x.play.step()},resize(c,R,u){const m=Math.max(1,c),S=Math.max(1,R);for(const O of L)u!==void 0&&O.renderer?.setPixelRatio(u),O.renderer?.setSize(m,S,!1),O.mounted.resize?.(m,S)},game:x}}const Ot=Object.freeze(Object.defineProperty({__proto__:null,createGameRuntime:ot,registerCanvasRoot:se,registerReactRoot:ie,registerThreeRoot:oe},Symbol.toStringTag,{value:"Module"}));export{Be as a,Fe as b,ot as c,oe as d,Ot as e,At as g,se as r};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d$ as f,c6 as d,v as x,c4 as v}from"./index-
|
|
1
|
+
import{d$ as f,c6 as d,v as x,c4 as v}from"./index-C7p_QQ7P.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";const g="x-volter-curve";function p(r,n){return r[n].label??n}function y(r,n,e){const s=r.points;for(let t=0;t<s.length;t++){const o=s[t];for(const c of["x","y"]){const{min:u,max:a}=n[c];(o[c]<u||o[c]>a)&&e.addIssue({code:"custom",path:["points",t,c],message:`${o[c]} is outside this curve's ${p(n,c)} domain [${u}, ${a}] — move the point inside the domain, or widen the axis in the schema (curve({ ${c}: { min, max } })).`})}if(t===0)continue;const i=s[t-1];o.x<=i.x&&e.addIssue({code:"custom",path:["points",t,"x"],message:`${o.x} must be strictly greater than the previous point's x (${i.x}) — curve points run left to right along x, with no duplicate x. Sort the points, or nudge this one.`})}}function K(r){const n=f({x:d().describe(`Position along ${p(r,"x")}.`),y:d().describe(`Value at that position, along ${p(r,"y")}.`)});return f({interpolation:v(["linear","smooth"]).describe('How the value moves between points: "linear" for straight segments, "smooth" for a monotone cubic that never overshoots them.'),points:x(n).min(2,{message:'a curve needs at least two points — add another { "x": …, "y": … } so the value has somewhere to travel between.'}).describe("Keys in increasing x order; the value is clamped outside the first/last x.")}).superRefine((e,s)=>y(e,r,s)).meta({[g]:r})}function M(r){let n=r;for(let e=0;e<5&&n;e++){const t=n.meta?.()?.[g];if(t&&typeof t=="object"&&"x"in t&&"y"in t)return t;n=n.def?.innerType}}function b(r){const n=r.length,e=[];for(let t=0;t<n-1;t++){const o=r[t],i=r[t+1];e.push((i.y-o.y)/(i.x-o.x))}const s=[e[0]];for(let t=1;t<n-1;t++)s.push((e[t-1]+e[t])/2);s.push(e[n-2]);for(let t=0;t<n-1;t++){const o=e[t];if(o===0){s[t]=0,s[t+1]=0;continue}let i=s[t]/o,c=s[t+1]/o;i<0&&(s[t]=0,i=0),c<0&&(s[t+1]=0,c=0);const u=i*i+c*c;if(u>9){const a=3/Math.sqrt(u);s[t]=a*i*o,s[t+1]=a*c*o}}return s}function O(r,n){const e=r.points;if(e.length===0)return 0;const s=e[0],t=e[e.length-1];if(e.length===1||n<=s.x)return s.y;if(n>=t.x)return t.y;let o=0;for(;o<e.length-2&&n>=e[o+1].x;)o++;const i=e[o],c=e[o+1],u=c.x-i.x;if(u<=0)return i.y;const a=(n-i.x)/u;if(r.interpolation==="linear")return i.y+(c.y-i.y)*a;const m=b(e),h=a*a,l=h*a;return(2*l-3*h+1)*i.y+(l-2*h+a)*u*m[o]+(-2*l+3*h)*c.y+(l-h)*u*m[o+1]}export{K as curve,M as curveAxesOf,O as sampleCurve};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{e0 as p}from"./index-
|
|
1
|
+
import{e0 as p}from"./index-C7p_QQ7P.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";function y(o,e,t){let i=c(o,e,t);const s=new Set;return{get:()=>i,sourcePath:t,subscribe(r){return s.add(r),()=>s.delete(r)},hotSwap(r){let n;try{n=c(o,r,t)}catch(a){console.error(`[data] hot edit rejected, keeping previous values.
|
|
2
2
|
${String(a)}`);return}i=n;for(const a of s)a(i)}}}function S(o){const e=p(o,{io:"input"});if(e.type==="object"){const t=e.properties??{};t.$schema??={type:"string"},e.properties=t}return e}function c(o,e,t){const i=e!==null&&typeof e=="object"&&!Array.isArray(e)&&"$schema"in e?Object.fromEntries(Object.entries(e).filter(([r])=>r!=="$schema")):e,s=o.safeParse(i);if(!s.success){const r=s.error.issues.map(n=>` - ${n.path.join(".")||"(root)"}: ${n.message}`).join(`
|
|
3
3
|
`);throw new Error(`Data asset "${t}" failed its schema:
|
|
4
4
|
${r}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{DATA_REF_PATTERN as p}from"./data-check-core-CHqar_E8.js";import{w as l}from"./index-
|
|
1
|
+
import{DATA_REF_PATTERN as p}from"./data-check-core-CHqar_E8.js";import{w as l}from"./index-C7p_QQ7P.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";function g(e){return new RegExp(`^${e}#[A-Za-z0-9_-]+(?:\\.[A-Za-z0-9_-]+)*$`)}function E(e){return l().regex(g(e),{message:`must be a "${e}#<key>" reference — expected the target asset stem "${e}", e.g. "${e}#some-key".`}).meta({"x-volter-ref":e})}function u(e,o){let t=e;for(const r of o){if(t===null||typeof t!="object"||Array.isArray(t)||!(r in t))return r;t=t[r]}return null}function j(e,o){const t=p.exec(o);if(!t)throw new Error(`getRef: "${o}" is not a "file#key" reference — expected a string shaped like "some-file#some-key".`);const r=t[1],m=t[2],n=e.sourcePath?.split("\\").join("/").split("/").pop()?.replace(/\.data\.json$/,"");if(n!==void 0&&n!==r)throw new Error(`getRef: ref "${o}" names target asset "${r}", but the handle passed in is "${n}" (${e.sourcePath}). Pass the handle "${r}#..." actually names — getRef(${r}, ...), not getRef(${n}, ...).`);const i=m.split("."),a=e.get(),f=u(a,i);if(f!==null)throw new Error(`getRef: dangling ref "${o}" — "${f}" does not exist`+(n?` in ${n}.data.json`:"")+'. Fix the key or remove the ref (refs are "file#key" strings).');let s=a;for(const c of i)s=s[c];return s}export{E as dataRef,j as getRef};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{D as v}from"./debug-registry-
|
|
1
|
+
import{D as v}from"./debug-registry-CurxbdJb.js";import{r as _}from"./game-network-D6iKU3Wc.js";const D="volter-debug",T=100,E=50,k=100,P=60,b=2e3,V="the host loop reported liveness 'loop-starved' and this session has no way to drive ticks — no recent rAF progress was observed. Check `volter-game-editor status` for the separate visibility readings; foreground/reload the editor, or start play to wire the run-ticks target, then retry.";async function L(n,s,d){const i=()=>n.state("time"),c=i();let l=c.tick,u=0,g=0;for(;;){const r=i();if(r.simSeconds-c.simSeconds>=s)return{stalled:!1};if(r.loopLiveness==="loop-starved"){if(!d)return{stalled:!0,starvedWithoutDriver:!0};if(g>=b)return{stalled:!0};g+=1;const e=s-(r.simSeconds-c.simSeconds),t=r.fixedDt,o=t!==void 0&&Number.isFinite(t)&&t>0?Math.max(1,Math.ceil(e/t-1e-9)):1;d(Math.min(P,o));const a=i();if(a.tick===r.tick&&a.simSeconds===r.simSeconds)return{stalled:!0};l=a.tick,u=0,await Promise.resolve();continue}if(u=r.tick===l?u+1:0,l=r.tick,u>=k)return{stalled:!0};await new Promise(e=>setTimeout(e,E))}}function h(){return typeof window<"u"}function S(n){return new URLSearchParams(n.search).get(D)==="1"}function A(n){return n.debug?.allowInProduction===!0}function I(n){const{registry:s,manifest:d}=n,i=s.adapter,c=[];function l(e){c.push(e),c.length>T&&c.shift()}const u=e=>{l(e.message||String(e.error))},g=e=>{l(`Unhandled promise rejection: ${String(e.reason)}`)};n.window.addEventListener?.("error",u),n.window.addEventListener?.("unhandledrejection",g);function r(e,t){const o=s.getVirtualInputTarget(t);if(!o)throw new v("DEBUG_INPUT_UNAVAILABLE",`debug bridge: ${e}() has no virtual-input target wired — no root entry exports \`debug.input\` (the game's own input door), or none has mounted yet`);return o}return{version:1,providers:i.providers,state:i.state,stateAll:i.stateAll,commands:i.commands,events:i.events,async invoke(e,t){if(!A(d))throw new v("DEBUG_COMMANDS_UNSUPPORTED",`debug: command "${e}" invocation refused — production build without debug.allowInProduction (D18)`,{name:e});return i.invoke(e,t)},input:{setVirtualAction:(e,t,o)=>r("setVirtualAction",o).setVirtualAction(e,t),tapVirtualAction:(e,t)=>r("tapVirtualAction",t).tapVirtualAction(e),clearVirtualActions:e=>r("clearVirtualActions",e).clearVirtualActions(),scheduleActionAtTick:(e,t,o,a)=>r("scheduleActionAtTick",a).scheduleActionAtTick(e,t,o),startRecording:e=>r("startRecording",e).startInputRecording(),stopRecording:e=>r("stopRecording",e).stopInputRecording(),isRecording:e=>r("isRecording",e).isInputRecording(),injectPointerDelta:(e,t,o)=>r("injectPointerDelta",o).injectPointerDelta(e,t),injectPointerPosition:(e,t,o)=>r("injectPointerPosition",o).injectPointerPosition(e,t)},snapshot(e){return{time:i.state("time"),state:i.stateAll(),events:i.events(e),pageErrors:c.slice()}},runTicks(e,t){const o=s.getRunTicksTarget();if(!o)throw new v("DEBUG_RUN_TICKS_UNAVAILABLE","debug bridge: runTicks() has no run-ticks target wired — no Game has mounted yet");o.runTicks(e,t)},runTicksSettled(e,t){return _(s,e,t)},async holdFor(e,t,o){const a=r("holdFor",o),w=a.setVirtualAction(e,!0);if(!w.delivered)return a.clearVirtualActions(),w.reason!==void 0?{delivered:!1,reason:w.reason}:{delivered:!1};const f=s.getRunTicksTarget(),{stalled:m,starvedWithoutDriver:p}=await L(i,t,f?R=>f.runTicks(R,{render:"last"}):void 0);return a.clearVirtualActions(),m?{delivered:!1,reason:p?V:"play stopped during hold"}:{delivered:!0}},uninstall(){n.window.removeEventListener?.("error",u),n.window.removeEventListener?.("unhandledrejection",g),delete n.window.__volter}}}function U(n){const s=n.url??(h()?window.location:void 0);if(!s||!S(s))return;const d=n.window??(h()?window:void 0);if(!d)return;if(!A(n.manifest)){console.warn("[debug] ?volter-debug=1 ignored: production build without debug.allowInProduction (D18)");return}const i=I({registry:n.registry,manifest:n.manifest,window:d});return d.__volter=i,i}export{V as H,U as m,L as w};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e0 as L}from"./index-
|
|
1
|
+
import{e0 as L}from"./index-C7p_QQ7P.js";function B(o){const s=Symbol.for(`@volter/game-runtime/game-scoped/${o}`);return{set(u,d){Object.defineProperty(u,s,{configurable:!0,enumerable:!1,value:d})},get(u){return u[s]??null}}}class c extends Error{code;data;constructor(s,u,d){super(u),this.name="DebugError",this.code=s,this.data=d}}const T="ctx.debug.registerStateProvider(name, fn) — see the template example component";function P(o){if(o instanceof Error){const s={causeName:o.name,causeMessage:o.message};return o.stack===void 0?s:{...s,causeStack:o.stack}}return{causeName:typeof o,causeMessage:String(o)}}const q=1e4;function y(o,s,u,d){o.has(s)||(o.add(s),console.warn(`[debug] ${u} "${s}" re-registered (world "${d}")`))}function V(o){const s=new Map,u=new Map,d=new Set,S=new Set,m=[],R=500;let p=0,I=!1;const _=new Map,w=new Map,l=new Map;let E=null;const D=new Set;let b=null;const g=new Map;let N=0;function C(e){if(e!==void 0){if(!l.has(e))throw new c("DEBUG_INPUT_WORLD_NOT_FOUND",`debug: no input door wired for world "${e}" — registered: `+(l.size?[...l.keys()].join(", "):"(none)"),{worldId:e,registered:[...l.keys()]});return e}return h(l.keys())}function h(e){const t=[...e];if(t.length===0)return null;const r=o.getDefaultRootId?.()??null;return r!==null&&t.includes(r)?r:t[0]}s.set("time",{fn:()=>({simSeconds:o.getSimT(),tick:o.getTick(),loopLiveness:o.getLoopLiveness?.()??null,...o.getFixedDt===void 0?{}:{fixedDt:o.getFixedDt()}}),tier:"observable",worldId:"__engine__",builtin:!0}),s.set("input.actions",{fn:()=>{const e=h(_.keys());return(e?_.get(e):void 0)?.()??[]},tier:"observable",worldId:"__engine__",builtin:!0}),s.set("input.trace",{fn:()=>{const e=h(w.keys());return(e?w.get(e):void 0)?.()??{version:1,seed:null,fixedDt:null,ticks:[]}},tier:"observable",worldId:"__engine__",builtin:!0});function O(e,t,r,i){const n=s.get(t);if(n?.builtin)throw new c("DEBUG_BUILTIN_RESERVED",`debug: "${t}" is a built-in state provider (registered by "${n.worldId}") — built-in names cannot be registered over from a world`,{name:t,registered:n.worldId});if(n){if(n.worldId!==e)throw new c("DEBUG_NAME_COLLISION",`debug: state provider "${t}" is registered by both world "${n.worldId}" and world "${e}" — each provider name must be unique across live roots`,{name:t,roots:[n.worldId,e]});y(d,t,"provider",e)}s.set(t,{fn:r,tier:i,worldId:e,builtin:!1})}function A(e,t,r,i){if(r.locus===void 0&&I)throw new c("DEBUG_COMMAND_LOCUS_REQUIRED","this project declares a Colyseus room — declare locus: 'client' | 'server' so fixtures mutate authoritative state, not client prediction",{name:t,worldId:e});const n=u.get(t);if(n){if(n.worldId!==e)throw new c("DEBUG_NAME_COLLISION",`debug: command "${t}" is registered by both world "${n.worldId}" and world "${e}" — each command name must be unique across live roots`,{name:t,roots:[n.worldId,e]});y(S,t,"command",e)}u.set(t,{description:r.description,argsSchema:r.args,locus:r.locus,fn:i,worldId:e})}function k(e,t){p+=1,m.push({tick:o.getTick(),simT:o.getSimT(),event:e,detail:t,seq:p}),m.length>R&&m.shift()}function $(e){return e===void 0?m.slice():m.filter(t=>t.seq>e)}function G(e,t){if(!b)throw new c("DEBUG_COMMAND_FAILED",`debug: command "${e}" is locus:'server' but no Colyseus room is attached (call ctx.debug.attachRoom(room) once your game joins its room)`,{reason:"no room connection"});const r=`dbg-${++N}`,i=b;return new Promise((n,a)=>{const f=setTimeout(()=>{g.delete(r),a(new c("DEBUG_COMMAND_FAILED",`debug: command "${e}" (requestId "${r}") timed out waiting for the server`,{reason:"server timeout"}))},q);g.set(r,{resolve:n,reject:a,timer:f}),i.send("__volter:debugCommand",{name:e,args:t,requestId:r})})}let v=null;function U(e){v?.(),b=e;const t=e.onMessage("__volter:debugCommandResult",i=>{const n=i,a=n?.requestId;if(a===void 0)return;const f=g.get(a);f&&(g.delete(a),clearTimeout(f.timer),n?.ok?f.resolve(n.result):f.reject(new c("DEBUG_COMMAND_FAILED",`debug: server command failed: ${String(n?.error)}`,{cause:n?.error})))}),r=()=>{if(v===r){v=null,b===e&&(b=null),typeof t=="function"&&t();for(const[i,n]of g)clearTimeout(n.timer),n.reject(new c("DEBUG_COMMAND_FAILED",`debug: command (requestId "${i}") failed — its room was detached before a reply arrived`,{reason:"no room connection"}));g.clear()}};return v=r,r}return{adapter:{providers(){return[...s.entries()].map(([e,t])=>({name:e,tier:t.tier}))},state(e){const t=s.get(e);if(!t)throw new c("STATE_PROVIDER_NOT_FOUND",`debug: no state provider registered under "${e}"`,{registered:[...s.keys()],registrationHint:T});return t.fn()},stateAll(){const e={};for(const[t,r]of s)try{e[t]=r.fn()}catch(i){e[t]={__error:String(i)}}return e},commands(){return[...u.entries()].map(([e,t])=>({name:e,description:t.description,argsJsonSchema:t.argsSchema?L(t.argsSchema,{unrepresentable:"any"}):void 0,locus:t.locus??"client"}))},async invoke(e,t){const r=u.get(e);if(!r)throw new c("DEBUG_COMMAND_NOT_REGISTERED",`debug: no command registered under "${e}"`,{registered:[...u.keys()],registrationHint:T});let i=t;if(r.argsSchema){const n=r.argsSchema.safeParse(t);if(!n.success)throw new c("DEBUG_COMMAND_ARGS_INVALID",`debug: command "${e}" received invalid args`,{issues:n.error.issues});i=n.data}if((r.locus??"client")==="server")return G(e,i);try{return await r.fn(...i)}catch(n){const a=P(n);throw new c("DEBUG_COMMAND_FAILED",`debug: command "${e}" threw: ${a.causeMessage}`,{cause:n,...a})}},events(e){return $(e)}},forRoot(e){return{registerStateProvider(t,r,i){O(e,t,r,i?.tier??"observable")},registerCommand(t,r,i){A(e,t,r,i)},emit(t,r){k(t,r)},attachRoom(t){return U(t)}}},strip(e){for(const[t,r]of s)r.builtin||e!==void 0&&r.worldId!==e||(s.delete(t),d.delete(t));for(const[t,r]of u)e!==void 0&&r.worldId!==e||(u.delete(t),S.delete(t))},setRoomDeclared(e){I=e},setInputActionsSource(e,t){_.set(e,t)},setInputTraceSource(e,t){w.set(e,t)},setVirtualInputTarget(e,t){l.set(e,t)},getVirtualInputTarget(e){const t=C(e);return t!==null?l.get(t)??null:null},setRunTicksTarget(e){E=e},getRunTicksTarget(){return E},registerWorldSettledProbe(e){return D.add(e),()=>{D.delete(e)}},worldSettled(){for(const e of D)try{if(!e())return!1}catch{return!1}return!0},getGameTick(){return o.getTick()}}}const M=B("debug-registry");function j(o,s){M.set(o,s)}function H(o){return M.get(o)??null}export{c as D,V as a,B as c,H as g,j as r};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/canvas-entry-runtime-
|
|
2
|
-
import{I as u,J as f,_ as i,K as d,L as n,M as m,O as p,Q as g}from"./index-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/canvas-entry-runtime-Cux0NSyO.js","assets/index-C7p_QQ7P.js","assets/index-nmcBqr7Y.js","assets/_commonjsHelpers-D6-XlEtG.js","assets/index-D_NuPfjr.js","assets/jsx-runtime-DPjLkJKQ.js","assets/index-CtzuWnCS.js","assets/index-CinJrH5C.js","assets/index-FUuS4qwW.js","assets/client-DNXj_opT.js","assets/index-CPiRKiDC.css","assets/debug-registry-CurxbdJb.js","assets/mount-ingest-root-CjOWFsbq.js","assets/active-ingest-BX03j5HF.js","assets/game-contract-seams-FFGgxMOq.js","assets/capability-coverage-9jbjkC7w.js","assets/ingest-source-persistence-CsqPDVx6.js","assets/contract-system-adapters-Dx3-ZI4N.js","assets/three-state-Cs7Th7ur.js","assets/editor-shell-store-sESsCCic.js","assets/output-pass-HurwNl0G.js","assets/three.module-BLhyNg0e.js","assets/three.core-3arARmh6.js","assets/Pass-D1MRT672.js","assets/editor-layers-DvKAawE7.js","assets/workspace-arrangement-Bf-W4FYD.js","assets/user-data-UxjaQvdx.js","assets/entity-object-CR7fCzb1.js","assets/three-contract-Dkt6PmWY.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{I as u,J as f,_ as i,K as d,L as n,M as m,O as p,Q as g}from"./index-C7p_QQ7P.js";import{q as v}from"./edit-mode-authoring-Bm31X1cT.js";import{d as P,a as c,b as w,g as y,e as I,c as _}from"./active-ingest-BX03j5HF.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./game-contract-seams-FFGgxMOq.js";import"./capability-coverage-9jbjkC7w.js";import"./ingest-source-persistence-CsqPDVx6.js";import"./contract-system-adapters-Dx3-ZI4N.js";async function h(){const e=await u().catch(()=>null);if(!e)return!1;const t=f(e);if(t.length!==1)return!1;if(t[0].world!==void 0)return!0;const a=await R();return A(a)}const D=4e3;function R(){const e=n();return e?Promise.resolve(e):new Promise(t=>{const a=setTimeout(()=>{s(),t(n())},D),s=m(()=>{const r=n();r&&(clearTimeout(a),s(),t(r))})})}function A(e){return e?p(e.scenes).some(t=>t.plan.kind==="isolation-document"):!1}async function G(e){if(!await h())return!1;const t=await u().catch(()=>null);if((t?f(t).some(r=>r.adapter.surface==="canvas"):!1)&&!c()){const{resolveCanvasPixiForEditor:r}=await i(async()=>{const{resolveCanvasPixiForEditor:l}=await import("./canvas-entry-runtime-Cux0NSyO.js");return{resolveCanvasPixiForEditor:l}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11]));(await r()).Assets.reset()}const{launchIngestRoutes:s}=await i(async()=>{const{launchIngestRoutes:r}=await import("./mount-ingest-root-CjOWFsbq.js").then(o=>o.m);return{launchIngestRoutes:r}},__vite__mapDeps([12,1,2,3,4,5,6,7,8,9,10,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28]));if(await s(e),!c())throw new Error(`Play could not start: this project's ingest root failed to mount — see the mount failure reported above (and in ${d("status")}).`);return w(),g(),y()?.play(),!0}function J(e){return P()?(I(),_(),e.shell.setPlayState("stopped"),v(),!0):!1}export{P as deferredIngestPlayActive,J as exitDeferredIngestPlay,h as ingestMountIsDeferredToPlay,G as mountDeferredIngestForPlay};
|
package/dist/assets/{design-time-canvas-mount-Ds-zq4CU.js → design-time-canvas-mount-CcBiI7BU.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/canvas-design-mount-
|
|
2
|
-
import{_ as u,dI as c,dJ as l}from"./index-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/canvas-design-mount-B3FNDE7x.js","assets/index-C7p_QQ7P.js","assets/index-nmcBqr7Y.js","assets/_commonjsHelpers-D6-XlEtG.js","assets/index-D_NuPfjr.js","assets/jsx-runtime-DPjLkJKQ.js","assets/index-CtzuWnCS.js","assets/index-CinJrH5C.js","assets/index-FUuS4qwW.js","assets/client-DNXj_opT.js","assets/index-CPiRKiDC.css","assets/babylon-authoring-adapter-DPAz8ZAn.js","assets/json-history-resource-QtpzKzwO.js","assets/source-persistence-backend-DXhXbcHd.js","assets/ingest-source-persistence-CsqPDVx6.js","assets/pixi-authoring-adapter-zLm6t32A.js","assets/index-BStQTwLR.js","assets/component-instance-root-6vlZ9amU.js","assets/user-data-UxjaQvdx.js","assets/workspace-arrangement-Bf-W4FYD.js","assets/pixi-transform-channels-P4rvmusc.js","assets/relative-import-specifier-DcxN-Zbr.js","assets/oid-transform-Cb40tUcA.js","assets/writer-tw6EcuVO.js","assets/r3f-physics-binding-D7H8JaW0.js","assets/canvas-preview-frames-CmraLAxc.js","assets/canvas-entry-runtime-Cux0NSyO.js","assets/debug-registry-CurxbdJb.js","assets/realm-services-CN-61eEJ.js","assets/three-ingest-runtime-CAdElDuH.js","assets/three.module-BLhyNg0e.js","assets/three.core-3arARmh6.js","assets/EffectComposer-BEAt0PtQ.js","assets/CopyShader-BzTUYzf6.js","assets/ShaderPass-DTnDQXm0.js","assets/Pass-D1MRT672.js","assets/CSS3DRenderer-BsAqfavI.js","assets/native-debug-module-_hzBkCZ7.js","assets/native-entry-surface-BE8LJNdu.js","assets/contract-system-adapters-Dx3-ZI4N.js","assets/game-contract-seams-FFGgxMOq.js","assets/assets-BcrMQHRv.js","assets/loader-BTUKnX5Q.js","assets/KTX2Loader-CaqVE6nY.js","assets/GLTFLoader-KeoruJgS.js","assets/BufferGeometryUtils-B22h7jo4.js","assets/create-runtime-S5Je5FVD.js","assets/adapter-surface-Y37Nzcyw.js","assets/binding-Bmxqznjk.js","assets/root-stacking-BEd9ZvxC.js","assets/setup-renderer-FkSOtbK8.js","assets/index-DHhMOs_s.js","assets/defaults-DKiBJCPN.js","assets/render-settings-hwYf1wv5.js","assets/render-features-Cfvq_SBW.js","assets/seeded-random-CT60Vm0v.js","assets/loop-gate-report-N52EWFGD.js","assets/system-slot-E2mEdiih.js","assets/user-data-CODoGZqA.js","assets/object-marks-BnvSuCTt.js","assets/performance-profiler-CMbwGBuk.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{_ as u,dI as c,dJ as l}from"./index-C7p_QQ7P.js";import{t as d}from"./three-state-Cs7Th7ur.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./editor-shell-store-sESsCCic.js";import"./output-pass-HurwNl0G.js";import"./three.module-BLhyNg0e.js";import"./three.core-3arARmh6.js";import"./Pass-D1MRT672.js";import"./editor-layers-DvKAawE7.js";import"./workspace-arrangement-Bf-W4FYD.js";import"./user-data-UxjaQvdx.js";import"./entity-object-CR7fCzb1.js";import"./three-contract-Dkt6PmWY.js";async function W(o,t,e){const{mountCanvasDesignLayer:r}=await u(async()=>{const{mountCanvasDesignLayer:p}=await import("./canvas-design-mount-B3FNDE7x.js");return{mountCanvasDesignLayer:p}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60])),{projectRootPath:s,view:a,activationDocumentId:i}=e,n=d();if(!n)throw new Error(`canvas root "${o.worldId}": the editor store is not bound yet.`);const m=await r(o.worldId,o.path,t,s,n,a,i?()=>c(i):void 0);return{adapter:m.adapter,dispose:()=>m.dispose()}}function $(o){let t=null;const e=l(r=>{r!==""&&!/^src\/.+\.(?:[cm]?tsx?|jsx?)$/.test(r)||(t!==null&&clearTimeout(t),t=setTimeout(()=>{t=null,o()},150))});return()=>{t!==null&&clearTimeout(t),t=null,e()}}export{W as mountCanvasDesignTimeLayer,$ as remountWhenSourceIsWritten};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{stackOrder as se}from"./root-stacking-BEd9ZvxC.js";import{dM as ie,dN as de,dO as le,dB as ue,aC as ae,dP as q,bY as fe,Z as P,bX as pe,aH as ce,dQ as we,dE as he,dC as ye}from"./index-
|
|
1
|
+
import{stackOrder as se}from"./root-stacking-BEd9ZvxC.js";import{dM as ie,dN as de,dO as le,dB as ue,aC as ae,dP as q,bY as fe,Z as P,bX as pe,aH as ce,dQ as we,dE as he,dC as ye}from"./index-C7p_QQ7P.js";import{B as S,q as N}from"./edit-mode-authoring-Bm31X1cT.js";import{s as me,d as I,a as ge}from"./design-time-mount-registry-DUpXCg1U.js";import{d as Ie,s as be,g as ve,e as Se}from"./react-story-board-rd1U6EAp.js";import{m as ke}from"./game-surface-defaults-D8S4cRxi.js";const H=new Map;function X(n,r){return`${n}\0${r}`}function De(n,r){return H.get(X(n,r))}function Ve(n,r,t){H.set(X(n,r),t)}const Ce=1;function Y(n){const r=[];for(const{worldId:t,adapter:d}of n.childAdapters()){if(!(d instanceof S))continue;const u=d.inspector.get(t,"kind");if(u!=="dom"&&u!=="canvas"||d.inspector.get(t,"reason")!==void 0)continue;const b=d.inspector.get(t,"adapter");b?.startsWith("ingest")||b?.startsWith("module")||r.push({worldId:t,kind:u,path:d.inspector.get(t,"path"),zOrder:Number(d.inspector.get(t,"zOrder")??0),pausable:d.inspector.get(t,"pausable")!==!1})}return r}function xe(n){return Y(n)}const Oe="ui-components-board";function j(n,r){return n.childAdapters().some(t=>t.worldId===r)}function We(){return{worldId:Oe,kind:"dom",path:void 0,zOrder:0,pausable:!0}}function Z(n,r,t="dom"){const d=ce(r)?"none":"block";n.style.display=d,n.style.pointerEvents=I(t)?.alwaysInteractive||we(r)?"auto":"none";for(const u of Array.from(n.parentElement?.children??[]))u instanceof HTMLElement&&u.dataset.volterStoryBoardChromeFor===r&&(u.style.display=d)}function Re(n,r,t,d){const{worldId:u}=r,s=document.createElement("div");return s.dataset.worldId=u,s.dataset.volterRootSurface="true",d&&(s.dataset.volterCanvasScene="true"),s.style.position="absolute",s.style.top="0",s.style.left="0",s.style.width="100%",s.style.height="100%",s.style.zIndex=String(t),s.style.contain="layout paint",ke(s),Z(s,u,r.kind),D(s),n.appendChild(s),s}function D(n){if(n.dataset.volterCanvasScene==="true"){n.style.transform="",n.style.width="100%",n.style.height="100%";return}if(n.style.transform=he(ye())??"",n.style.transformOrigin="0 0",n.dataset.volterReactStoryBoard==="true")return;const r=ve();n.style.width=r.width===null?"100%":`${r.width}px`,n.style.height=r.height===null?"100%":`${r.height}px`}const E=new Map;function Ae(n,r,t,d,u,s,b){s?s.canvasSceneView.reset():ie(),Se();const k=ae();if(!s&&k?.config.resolution&&Ie(k.config.resolution.width,k.config.resolution.height),t.playState!=="stopped"){let e=!1,o=!1;const i=t.subscribe(()=>{e||o||t.playState!=="stopped"||(o=!0,e||N())});return()=>{e=!0,i()}}const V=k?.rootPath,z=d?[...d]:Y(r);if(z.length===0||!V)return()=>{};const G=V,y=se(z.map(e=>({id:e.worldId,zOrder:e.zOrder}))).map(e=>z.find(o=>o.worldId===e.id)),x=new Map(y.map(e=>[e.worldId,e])),a=new Map,m=new Map,C=new Map,O=new Set,R=new Set,T=new Set;let h=!1,p=!1,W=!1;function A(){for(const e of m.values())try{e()}catch(o){P.error(`[design-time-layers] dispose failed: ${o}`,"authoring")}m.clear();for(const e of a.values())e.remove();a.clear();for(const e of y)u?.(e.worldId,null)}function J(){A();for(const e of O){const o=x.get(e);if(!o)continue;const i={id:o.worldId,kind:o.kind,entryOrScenePath:o.path,zOrder:o.zOrder,pausable:o.pausable};r.replaceChild(e,new S(t,i,"Design-time layer suspended by play mode — Stop restores it."))}O.clear(),t.notifyIngestEdit()}function M(e,o,i){const l=I(e.kind);if(!l){R.add(e.worldId);return}R.delete(e.worldId);const f=(C.get(e.worldId)??0)+1;C.set(e.worldId,f);const c=Re(n,e,Ce+o,!!s);a.set(e.worldId,c);const B={projectRootPath:G,store:t,...s?{view:s.canvasSceneView}:{},...b?{activationDocumentId:b}:{}},L=E.get(e.worldId),$=(async()=>(L&&await L,l.mount(e,c,B)))().then(w=>{if(h||p||C.get(e.worldId)!==f){w.dispose();return}if(w.adapter)j(r,e.worldId)&&(r.replaceChild(e.worldId,w.adapter),O.add(e.worldId)),u?.(e.worldId,w.adapter);else if(w.pick){const v={id:e.worldId,kind:e.kind,entryOrScenePath:e.path,zOrder:e.zOrder,pausable:e.pausable};r.replaceChild(e.worldId,new S(t,v,void 0,w.pick)),O.add(e.worldId)}m.set(e.worldId,w.dispose),q(e.worldId),t.notifyIngestEdit(),i?.()}).catch(w=>{if(C.get(e.worldId)!==f||(i?.(),c.remove(),a.get(e.worldId)===c&&a.delete(e.worldId),h||p))return;const v=fe(w);P.error(`[design-time-layers] world "${e.worldId}" (${e.kind}) failed to mount: ${v}`,"authoring");const ne={id:e.worldId,kind:e.kind,entryOrScenePath:e.path,zOrder:e.zOrder,pausable:e.pausable};u?.(e.worldId,null),j(r,e.worldId)&&r.replaceChild(e.worldId,new S(t,ne,v)),pe({worldId:e.worldId,kind:e.kind,identity:l.identity,message:v}),t.notifyIngestEdit()});E.set(e.worldId,$),$.then(()=>{E.get(e.worldId)===$&&E.delete(e.worldId)})}y.forEach((e,o)=>{M(e,o)});function K(e,o){const i=m.get(e.worldId);m.delete(e.worldId);const l=a.get(e.worldId);a.delete(e.worldId),M(e,o,()=>{const c=a.get(e.worldId);if(c&&(c.style.visibility=""),i)try{i()}catch(B){P.error(`[design-time-layers] re-projection dispose failed: ${B}`,"authoring")}l?.remove()});const f=a.get(e.worldId);f&&f!==l&&(f.style.visibility="hidden")}function Q(e,o){const i=m.get(e.worldId);if(m.delete(e.worldId),i)try{i()}catch(f){P.error(`[design-time-layers] remount dispose failed: ${f}`,"authoring")}const l=a.get(e.worldId);l&&(l.remove(),a.delete(e.worldId)),M(e,o)}const g=new Map;function F(){for(const[e,o]of g)I(e.kind)!==e&&(o(),g.delete(e));for(const e of ge()){if(g.has(e)||I(e.kind)!==e||!y.some(l=>l.kind===e.kind))continue;const o=[],i=l=>()=>{h||p||t.playState!=="stopped"||y.forEach((f,c)=>{f.kind===e.kind&&l(f,c)})};e.remountWhen&&o.push(e.remountWhen(i(Q))),e.reprojectWhen&&o.push(e.reprojectWhen(i(K))),g.set(e,()=>{for(const l of o)l()})}}F();const U=me(()=>{h||p||t.playState!=="stopped"||(y.forEach((e,o)=>{R.has(e.worldId)&&I(e.kind)&&(T.delete(e.worldId),q(e.worldId),M(e,o))}),F())}),_=()=>{if(h||p)return;let e=!1;for(const o of y){if(!R.has(o.worldId)||T.has(o.worldId)||I(o.kind)||(T.add(o.worldId),!j(r,o.worldId)))continue;const i={id:o.worldId,kind:o.kind,entryOrScenePath:o.path,zOrder:o.zOrder,pausable:o.pausable};r.replaceChild(o.worldId,new S(t,i,`No package in this editor registered a design-time mount for a "${o.kind}" world, so there is nothing here to author it with.`)),e=!0}e&&t.notifyIngestEdit()},ee=de(_);le()&&_();const oe=ue(()=>{for(const e of a.values())D(e)}),te=be(()=>{for(const e of a.values())D(e)}),re=t.subscribe(()=>{if(!p&&t.playState!=="stopped"){p=!0,J();return}if(p&&!W&&t.playState==="stopped"&&!h){W=!0,h||N();return}if(!p)for(const[e,o]of a)Z(o,e,x.get(e)?.kind??"dom")});return()=>{h=!0;for(const e of g.values())e();g.clear(),U(),ee(),re(),oe(),te(),A()}}export{Ve as a,xe as d,Ae as m,We as p,De as r};
|
package/dist/assets/{design-time-mount.service-CfOBd_-9.js → design-time-mount.service-BTJtrJB4.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/design-time-canvas-mount-
|
|
2
|
-
import{_ as n}from"./index-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/design-time-canvas-mount-CcBiI7BU.js","assets/index-C7p_QQ7P.js","assets/index-nmcBqr7Y.js","assets/_commonjsHelpers-D6-XlEtG.js","assets/index-D_NuPfjr.js","assets/jsx-runtime-DPjLkJKQ.js","assets/index-CtzuWnCS.js","assets/index-CinJrH5C.js","assets/index-FUuS4qwW.js","assets/client-DNXj_opT.js","assets/index-CPiRKiDC.css","assets/three-state-Cs7Th7ur.js","assets/editor-shell-store-sESsCCic.js","assets/output-pass-HurwNl0G.js","assets/three.module-BLhyNg0e.js","assets/three.core-3arARmh6.js","assets/Pass-D1MRT672.js","assets/editor-layers-DvKAawE7.js","assets/workspace-arrangement-Bf-W4FYD.js","assets/user-data-UxjaQvdx.js","assets/entity-object-CR7fCzb1.js","assets/three-contract-Dkt6PmWY.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{_ as n}from"./index-C7p_QQ7P.js";import{r as a}from"./design-time-mount-registry-DUpXCg1U.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";const g="workspace.service";function y(){return a({kind:"canvas",owner:"@volter/editor-game/canvas/design-time-mount",identity:"default-pixi",alwaysInteractive:!0,mount:async(r,e,t)=>{const{mountCanvasDesignTimeLayer:i}=await n(async()=>{const{mountCanvasDesignTimeLayer:o}=await import("./design-time-canvas-mount-CcBiI7BU.js");return{mountCanvasDesignTimeLayer:o}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21]));return i(r,e,t)},remountWhen:r=>{let e=!1,t=null;return n(()=>import("./design-time-canvas-mount-CcBiI7BU.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21])).then(i=>{e||(t=i.remountWhenSourceIsWritten(r))}),()=>{e=!0,t?.(),t=null}}})}export{g as point,y as start};
|
package/dist/assets/{design-time-mount.service-CrQoKi6N.js → design-time-mount.service-DxQYWBtW.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/design-time-react-mount-
|
|
2
|
-
import{_ as i}from"./index-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/design-time-react-mount-CaMPhDB5.js","assets/design-time-layers-DHbs4Bar.js","assets/root-stacking-BEd9ZvxC.js","assets/index-C7p_QQ7P.js","assets/index-nmcBqr7Y.js","assets/_commonjsHelpers-D6-XlEtG.js","assets/index-D_NuPfjr.js","assets/jsx-runtime-DPjLkJKQ.js","assets/index-CtzuWnCS.js","assets/index-CinJrH5C.js","assets/index-FUuS4qwW.js","assets/client-DNXj_opT.js","assets/index-CPiRKiDC.css","assets/edit-mode-authoring-Bm31X1cT.js","assets/design-time-mount-registry-DUpXCg1U.js","assets/react-story-board-rd1U6EAp.js","assets/game-surface-defaults-D8S4cRxi.js","assets/crash-null-boundary-v3a0uEgw.js","assets/realm-services-CN-61eEJ.js","assets/canvas-entry-runtime-Cux0NSyO.js","assets/debug-registry-CurxbdJb.js","assets/three-ingest-runtime-CAdElDuH.js","assets/three.module-BLhyNg0e.js","assets/three.core-3arARmh6.js","assets/EffectComposer-BEAt0PtQ.js","assets/CopyShader-BzTUYzf6.js","assets/ShaderPass-DTnDQXm0.js","assets/Pass-D1MRT672.js","assets/CSS3DRenderer-BsAqfavI.js","assets/react-root-BHA-cdrW.js","assets/StoryPreviewMount-BT3EF_bY.js","assets/story-presentation-BRdH0ChD.js","assets/three-story-model-D0gr0vkG.js","assets/inspect-B4sqdFaU.js","assets/inference-diagnostics-C6_Z4_8a.js","assets/react-world-authoring-adapter-D7x1fQ49.js","assets/board-guides-DM_vAo0C.js","assets/relative-import-specifier-DcxN-Zbr.js","assets/story-arg-descriptors-Ek86ExX7.js","assets/writer-tw6EcuVO.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{_ as i}from"./index-C7p_QQ7P.js";import{r as m}from"./design-time-mount-registry-DUpXCg1U.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";const v="workspace.service";function y(){return m({kind:"dom",owner:"@volter/editor-game/react/design-time-mount",identity:"default-react",mount:async(r,e,t)=>{const{mountReactDesignLayer:o}=await i(async()=>{const{mountReactDesignLayer:n}=await import("./design-time-react-mount-CaMPhDB5.js");return{mountReactDesignLayer:n}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39]));return o(r,e,t)},reprojectWhen:r=>{let e=!1,t=null;return i(()=>import("./design-time-react-mount-CaMPhDB5.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39])).then(o=>{e||(t=o.reprojectWhenStoriesRepublish(r))}),()=>{e=!0,t?.(),t=null}}})}export{v as point,y as start};
|
package/dist/assets/{design-time-react-mount-B6BJiTeO.js → design-time-react-mount-CaMPhDB5.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as it,a as at}from"./design-time-layers-
|
|
1
|
+
import{r as it,a as at}from"./design-time-layers-DHbs4Bar.js";import{fb as st,ba as lt,gb as ut,gc as dt,Z as E,gd as mt,ge as Y,bY as q,dI as U,as as ct,eL as z,at as $,dw as pt,cP as ft,gf as H}from"./index-C7p_QQ7P.js";import{h as ht,d as gt,g as bt}from"./react-story-board-rd1U6EAp.js";import{C as wt}from"./crash-null-boundary-v3a0uEgw.js";import{r as yt,a as St}from"./realm-services-CN-61eEJ.js";import{r as It}from"./react-root-BHA-cdrW.js";import{m as Pt}from"./StoryPreviewMount-BT3EF_bY.js";import{c as Rt,s as vt}from"./story-presentation-BRdH0ChD.js";import{d as Mt}from"./three-story-model-D0gr0vkG.js";import{c as Ct}from"./inspect-B4sqdFaU.js";import{R as J}from"./react-world-authoring-adapter-D7x1fQ49.js";import"./root-stacking-BEd9ZvxC.js";import"./edit-mode-authoring-Bm31X1cT.js";import"./design-time-mount-registry-DUpXCg1U.js";import"./game-surface-defaults-D8S4cRxi.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./canvas-entry-runtime-Cux0NSyO.js";import"./debug-registry-CurxbdJb.js";import"./three-ingest-runtime-CAdElDuH.js";import"./three.module-BLhyNg0e.js";import"./three.core-3arARmh6.js";import"./EffectComposer-BEAt0PtQ.js";import"./CopyShader-BzTUYzf6.js";import"./ShaderPass-DTnDQXm0.js";import"./Pass-D1MRT672.js";import"./CSS3DRenderer-BsAqfavI.js";import"./inference-diagnostics-C6_Z4_8a.js";import"./board-guides-DM_vAo0C.js";import"./relative-import-specifier-DcxN-Zbr.js";import"./story-arg-descriptors-Ek86ExX7.js";import"./writer-tw6EcuVO.js";function Et(e){const o=e.tagName;if(o==="IMG"||o==="VIDEO"||o==="CANVAS"||o==="svg"||o==="SVG"||o==="PICTURE")return!0;const r=getComputedStyle(e);if(r.visibility==="hidden"||r.display==="none")return!1;if(xt(r.backgroundColor)||r.backgroundImage&&r.backgroundImage!=="none"||r.boxShadow&&r.boxShadow!=="none"||r.borderStyle!=="none"&&r.borderStyle!==""&&(parseFloat(r.borderTopWidth)>0||parseFloat(r.borderRightWidth)>0||parseFloat(r.borderBottomWidth)>0||parseFloat(r.borderLeftWidth)>0))return!0;for(const n of e.childNodes)if(n.nodeType===Node.TEXT_NODE&&(n.textContent??"").trim()!=="")return!0;return!1}function xt(e){if(!e||e==="transparent")return!1;const o=/^rgba\(\s*[\d.]+\s*,\s*[\d.]+\s*,\s*[\d.]+\s*,\s*([\d.]+)\s*\)$/.exec(e);return o?parseFloat(o[1])>0:!0}function Nt(e,o=r=>r.getBoundingClientRect()){const r=o(e),n=e.offsetWidth;if(r.width<=0||n<=0)return null;const s=r.width/n;let d=Number.POSITIVE_INFINITY,c=Number.POSITIVE_INFINITY,i=Number.NEGATIVE_INFINITY,y=Number.NEGATIVE_INFINITY;for(const p of e.querySelectorAll("*")){if(!Et(p))continue;const m=o(p);m.width<=0||m.height<=0||(d=Math.min(d,(m.left-r.left)/s),c=Math.min(c,(m.top-r.top)/s),i=Math.max(i,(m.right-r.left)/s),y=Math.max(y,(m.bottom-r.top)/s))}return i<=d||y<=c?null:{x:d,y:c,width:i-d,height:y-c}}let x=!1;function kt(e,o){if(!e)return;H({adapter:e,seam:"editor.stories.apply",stage:"effect",detail:`the design board applied portable story ${o}`,run:()=>e.stories.apply(o,o)});const r=e.selection;r&&H({adapter:e,seam:"editor.selection.set",stage:"effect",detail:`the design board selected portable story ${o}`,run:()=>r.set([o])})}let X=!1;async function Ft(){if(X)return;X=!0;const e=bt();if(!(e.width!==null||e.height!==null))try{const o=await ft("volter.project.json");if(!o)return;const r=JSON.parse(o),n=r.resolution?.width,s=r.resolution?.height;if(typeof n!="number"||typeof s!="number"||n<64||s<64||n>4096||s>4096)return;gt(n,s)}catch{}}function Tt(e,o){return{id:e,surface:"dom",description:void 0,adapter:{type:"builtin",identity:"dom",surface:"dom"},entry:o,zOrder:0,pausable:!0,loop:"gated"}}async function At(e,o){try{const r=await St(o,pt());return{ok:!0,Entry:await It(e,r)}}catch(r){return{ok:!1,error:r}}}async function we(e,o,r){const{projectRootPath:n,store:s,activationDocumentId:d}=r;x?x=!1:await st({rootPath:n});const c=lt(),i=Mt(c),y=e.path,p=y?await At(Tt(e.worldId,y),n):{ok:!1,error:new Error(`design-time react layer "${e.worldId}": no \`entry\` declared — nothing to mount.`)},m=p.ok?ut(p.Entry):void 0,K=m?dt(m,e.path):null,j=i.find(g=>g.id===K?.id)??null;if(i.length>0){const g=it(n,e.worldId),P=i.find(t=>t.id===g)??j??i[0];e.path&&!j&&E.warn(`[design-time-layers] React root "${e.worldId}" has no story naming its entry component${m?` "${m}"`:""} — the board opens on "${P.label}". Give a *.stories.tsx a \`meta.component\` of this root's entry component to choose its default preview.`,"authoring");let k=!1,M=null,F=null;const T=new Map,D=Rt(i);await Ft();const l=ht(o,i.map(t=>({id:t.id,label:t.label,modulePath:t.modulePath,...t.title?{title:t.title}:{},parameters:t.parameters,...t.globals?{globals:t.globals}:{},...t.viewportLocked!==void 0?{viewportLocked:t.viewportLocked}:{}})),P.id,(t,u)=>{F=u,kt(M,t)},vt(i,D)),_=t=>{if(k)return;const u=l.frames.get(t.id);if(!u)return;if(t.parameters?.layout==="fullscreen"){l.setMeasuredFrame(t.id,null);return}const a={width:u.content.offsetWidth,height:u.content.offsetHeight},h=a.width>0?Nt(u.content):null;if(!h){l.setMeasuredFrame(t.id,null);return}const C=8,S=48;let b=Math.max(0,h.x-C),w=Math.max(0,h.y-C),R=Math.min(a.width,h.x+h.width+C),v=Math.min(a.height,h.y+h.height+C);if(R-b<S){const A=(S-(R-b))/2;b=Math.max(0,b-A),R=Math.min(a.width,b+S)}if(v-w<S){const A=(S-(v-w))/2;w=Math.max(0,w-A),v=Math.min(a.height,w+S)}if(R-b>=a.width*.9&&v-w>=a.height*.9){l.setMeasuredFrame(t.id,null);return}l.setMeasuredFrame(t.id,{frame:{width:Math.round(R-b),height:Math.round(v-w)},mount:a,offset:{x:Math.round(b),y:Math.round(w)}})},rt=t=>{setTimeout(()=>_(t),0),setTimeout(()=>_(t),1e3)},G=async(t,u=t.args)=>{const f=l.frames.get(t.id)?.content;if(f){try{const a=await Pt(f,t.modulePath,t.name,t.Component,u);if(!a)return;if(k){a.unmount();return}T.set(t.id,a),l.clearError(t.id),rt(t)}catch(a){const h=q(a);l.setError(t.id,h),E.error(`[design-time-layers] React root "${e.worldId}" failed mounting portable story "${t.name}": ${h}`,"authoring")}s.notifyIngestEdit()}};await Promise.all(i.map(t=>G(t))),l.setNote(mt().note),g&&l.activate(P.id,!0);const L=new Map(i.map(t=>[t.id,t])),nt={tagName:"DIV",get children(){return l.activeContent().children},getAttribute:t=>o.getAttribute(t),getBoundingClientRect:()=>o.getBoundingClientRect(),get style(){return o.style},get textContent(){return l.activeContent().textContent}},O=await Y();return M=new J(nt,s,{...O?{writeBackend:O}:{},designTokens:()=>{const t=l.activeContent(),u=t.closest?.("[data-volter-game-styles]")??t.querySelector?.("[data-volter-game-styles]")??t;return Ct(getComputedStyle(u))},assetRoot:o,portableStories:i.map(t=>({id:t.id,label:t.label,args:t.args,name:t.name,modulePath:t.modulePath})),portableHierarchy:D,activePortableStoryId:P.id,onPortableStoryApplied:t=>{const u=(t?L.get(t):null)??P;at(n,e.worldId,u.id);const f=F;F=null,l.activate(u.id,f===null||f==="zoom")},onPortableStoryArgsChanged:(t,u)=>{const f=L.get(t);f&&G(f,u).catch(a=>{E.error(`[design-time-layers] React root "${e.worldId}" failed updating portable story "${f.name}" args: ${q(a)}`,"authoring")})}}),d&&requestAnimationFrame(()=>U(d)),{adapter:M,dispose:()=>{k=!0,M.disposeReactRootAdapter();for(const t of T.values())t.unmount();T.clear(),l.dispose()}}}if(!p.ok)throw p.error instanceof Error?p.error:new Error(String(p.error));E.warn(`[design-time-layers] React root "${e.worldId}" has no portable CSF preview — the project declares no UI stories. Add a *.stories.tsx; give it a \`meta.component\` of this root's entry component${m?` (${m}, ${e.path})`:""} to make it this root’s default preview. Falling back to rendering the entry bare.`,"authoring");const Q=p.Entry,{createElement:B,createRoot:tt,flushSync:et}=await yt(),N=tt(o),ot=g=>{N.render(B(wt,{key:"__entry__",onCaught:g,children:B(Q)}))};let I=null;if(et(()=>{ot(g=>{I=g})}),I!==null)throw N.unmount(),I instanceof Error?I:new Error(String(I));const V=await Y(),W=new J(o,s,{...V?{writeBackend:V}:{}});return d&&requestAnimationFrame(()=>U(d)),{adapter:W,dispose:()=>{W.disposeReactRootAdapter(),N.unmount()}}}function Z(){return $().map(e=>e.ok?e.stories.map(o=>o.id).join(","):`!${e.modulePath}`).join("|")}function ye(e){let o=z()?$():null,r=o===null?null:Z(),n=null;const s=ct(()=>{if(!z())return;const d=$(),c=Z();if(o===null){o=d,r=c;return}const i=c!==r;o=d,r=c,i&&(n!==null&&clearTimeout(n),n=setTimeout(()=>{n=null,x=!0,e(),setTimeout(()=>{x=!1},0)},250))});return()=>{n!==null&&clearTimeout(n),n=null,s()}}export{we as mountReactDesignLayer,ye as reprojectWhenStoriesRepublish};
|
package/dist/assets/{document-preview-three-4FxFY9Cx.js → document-preview-three-BE-UtLOm.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as g}from"./content-bounds-
|
|
1
|
+
import{c as g}from"./content-bounds-SMMmDnR9.js";import{isEditorOwnedObject as u}from"./editor-layers-DvKAawE7.js";import{m as x}from"./renderer-ownership-BovSEcLv.js";import{W as w}from"./three.module-BLhyNg0e.js";import{f as C}from"./scene-framing-BFUJz9EH.js";import{ej as y,A as M,d9 as d,fo as s,ex as v,cj as S}from"./three.core-3arARmh6.js";import"./hierarchy-marks-QDNP7a91.js";import"./workspace-arrangement-Bf-W4FYD.js";import"./index-C7p_QQ7P.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";function W(n){const e=[];return n.traverse(a=>{!u(a)&&a.isCamera&&e.push(a)}),e}function R(n,e){const a=[];n.traverse(r=>{r.parent&&u(r)&&a.push({object:r,parent:r.parent})});for(const{object:r}of a)r.removeFromParent();let t;try{t=g(n)}finally{for(const{object:r,parent:h}of a)h.add(r)}const o=t.filter(r=>!r.overlay&&!r.enclosure),c=C(o.map(r=>r.box)),i=new d(42,e,.01,1e5),f=c.isEmpty()?new s:c.getCenter(new s),m=c.isEmpty()?1:Math.max(.01,c.getBoundingSphere(new v).radius),p=m/Math.sin(S.degToRad(i.fov/2));return i.position.copy(f).addScaledVector(new s(1,.75,1).normalize(),p*1.15),i.lookAt(f),i.near=Math.max(.001,p-m*2.5),i.far=p+m*3,i.updateProjectionMatrix(),i.updateMatrixWorld(!0),i}function P(n,e){if(e.camera){const t=new d(e.camera.fov??42,e.width/e.height,.01,1e5);return t.position.set(e.camera.position.x,e.camera.position.y,e.camera.position.z),t.lookAt(e.camera.target.x,e.camera.target.y,e.camera.target.z),t.updateMatrixWorld(!0),t}const a=W(n);if(a.length===1){const t=a[0].clone();return t.matrixWorld.copy(a[0].matrixWorld),t.matrixWorld.decompose(t.position,t.quaternion,t.scale),t instanceof d&&(t.aspect=e.width/e.height,t.updateProjectionMatrix()),t}return R(n,e.width/e.height)}function I(n,e,a,t){e.updateMatrixWorld(!0);const l=P(n,a),o=x(new w({antialias:!0,alpha:!0,preserveDrawingBuffer:!0}));let c;try{return c=t?.(o),o.setPixelRatio(1),o.setSize(a.width,a.height,!1),o.outputColorSpace=y,o.toneMapping=M,o.setClearColor(2106411,e.background===null?0:1),o.render(e,l),o.domElement.toDataURL("image/png")}finally{c?.(),o.dispose(),o.forceContextLoss()}}export{I as captureAuthoredThreeScenePreview};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ax as y,ay as v}from"./index-
|
|
1
|
+
import{ax as y,ay as v}from"./index-C7p_QQ7P.js";import{J as R,c as x}from"./json-history-resource-QtpzKzwO.js";import{D as C,s as w,a as b,c as k,m as T}from"./react-world-authoring-adapter-D7x1fQ49.js";import{g as p,b as u}from"./inspect-B4sqdFaU.js";function H(a){const e=(typeof a=="string"?a:a?.baseVal)?.trim()??"";if(e)return e.split(/\s+/)[0]}function S(a,t){if(a.id)return`${t}#${a.id}`;const e=H(a.className??"");return e?`${t}.${e}`:t}function j(a){const t=new Map;for(const[e,s]of a.nodes)t.set(e,{id:e,tag:s.object.tagName.toLowerCase(),el:s.object,parentId:s.parentId,childIds:[...s.childIds]});return{nodes:t,rootIds:[...a.rootIds]}}const g=[{prop:"color",label:"Color",type:"color"},{prop:"backgroundColor",label:"Background",type:"color"},{prop:"borderColor",label:"Border Color",type:"color"},{prop:"fontSize",label:"Font Size",type:"number"},{prop:"width",label:"Width",type:"number"},{prop:"height",label:"Height",type:"number"},{prop:"padding",label:"Padding",type:"number"},{prop:"margin",label:"Margin",type:"number"},{prop:"borderRadius",label:"Border Radius",type:"number"},{prop:"gap",label:"Gap",type:"number"},{prop:"display",label:"Display",type:"enum",options:["flex","block","none","grid"]},{prop:"textAlign",label:"Text Align",type:"enum",options:["left","center","right"]},{prop:"flexDirection",label:"Flex Direction",type:"enum",options:["row","column"]}],f="style.",M=new Map(g.map(({prop:a,type:t})=>[a,t]));class D{constructor(t,e,s){this.root=t,this.store=e;const o=e.shell.projectHistory;this.historyResource=o?new R({history:o,kind:"session-state",scope:"session",subject:{...s.journal,id:`${s.journal.id}/react-dom-edits`},displayName:"React DOM edits",capture:()=>this.captureHistoryState(),restore:async i=>{this.restoreHistoryState(i)}}):null}capabilities={transform:!1,inspectorFields:!0,persist:!1};provenance={source:"foreign",label:"live-only",detail:"Unmodified ingested React game — style edits apply for this session only and are never saved."};doc={};historyResource;projector=new C(w());snapCache=null;snapInvalidationScheduled=!1;boxEditSession=null;lockedIds=new Set;snapshot(){if(this.snapCache)return this.snapCache;this.projector.project(this.root);const t=j(this.projector);return this.snapCache=t,this.snapInvalidationScheduled||(this.snapInvalidationScheduled=!0,queueMicrotask(()=>{this.snapCache=null,this.snapInvalidationScheduled=!1})),t}nodeCount(){return this.snapshot().nodes.size}toEditorNode(t){return{id:t.id,label:S(t.el,t.tag),role:"element",kind:t.tag,parentId:t.parentId,childIds:t.childIds}}applyStyleToElement(t,e,s){t.style&&(t.style[e]=s)}recordStyleEdit(t,e,s){const o=this.doc[t]??{};o[e]=s,this.doc[t]=o}hierarchy={roots:()=>{const{nodes:t,rootIds:e}=this.snapshot();return e.map(s=>this.toEditorNode(t.get(s)))},node:t=>{const e=this.snapshot().nodes.get(t);return e?this.toEditorNode(e):null}};selection={get:()=>[...this.store.shell.selectedEntityIds],set:t=>this.store.shell.selectMultiple(t)};pickable={pick:(t,e)=>{const{nodes:s}=this.snapshot();let o=null,i=Number.POSITIVE_INFINITY,r=-1,l=-1;for(const c of s.values()){if(l++,this.lockedIds.has(c.id)||c.el.style?.pointerEvents==="none")continue;const n=c.el.getBoundingClientRect?.();if(!n||t<n.left||t>n.right||e<n.top||e>n.bottom)continue;const h=n.width*n.height;(h<i||h===i&&l>r)&&(o=c.id,i=h,r=l)}return o}};hostRect(){const t=this.root.getBoundingClientRect?.();return{left:t?.left??0,top:t?.top??0}}toHostRelative(t){const e=this.hostRect();return{x:t.left-e.left,y:t.top-e.top,width:t.width,height:t.height}}rects={rect:t=>{const s=this.snapshot().nodes.get(t)?.el.getBoundingClientRect?.();return s?this.toHostRelative(s):null},contextRects:t=>{const{nodes:e}=this.snapshot(),s=e.get(t);if(!s)return{};const o=s.parentId?e.get(s.parentId):void 0,i=o?.el.getBoundingClientRect?.(),l=(o?o.childIds:this.snapshot().rootIds).filter(d=>d!==t).map(d=>e.get(d)?.el.getBoundingClientRect?.()).filter(d=>d!=null).map(d=>this.toHostRelative(d)),c=s.el,n=c.getBoundingClientRect?.();let h;if(n){const d=y(p(c,"borderTopWidth",u))??0,I=y(p(c,"borderRightWidth",u))??0,E=y(p(c,"borderBottomWidth",u))??0,m=y(p(c,"borderLeftWidth",u))??0;h=this.toHostRelative({left:n.left+m,top:n.top+d,width:Math.max(0,n.width-m-I),height:Math.max(0,n.height-d-E)})}return{...i?{parent:this.toHostRelative(i)}:{},...l.length?{siblings:l}:{},...h?{paddingBox:h}:{}}}};colorSample={backgroundChainAt:(t,e)=>{const s=this.pickable.pick(t,e);if(!s)return null;const{nodes:o}=this.snapshot(),i=[];let r=o.get(s);for(;r;)i.push(p(r.el,"backgroundColor",u)),r=r.parentId?o.get(r.parentId):void 0;return i}};boxEdit={begin:t=>{this.historyResource?.assertCanMutate(),this.boxEditSession={id:t,touched:new Map,priorInline:new Map}},apply:(t,e)=>{this.historyResource?.assertCanMutate();const s=this.boxEditSession;if(!s||s.id!==t)return;const o=this.snapshot().nodes.get(t);if(!o)return;const i=p(o.el,"position",u),r=i==="absolute"||i==="fixed";for(const[l,c]of Object.entries(e)){const n=T(l,r);if(!n){console.warn(`[DomAuthoringAdapter] boxEdit: dropping patch key "${l}" for "${t}" — `+(l==="x"||l==="y"?`node is not absolutely/fixed positioned (computed position: "${i}"), no left/top to move`:"unrecognized box-edit patch key"));continue}if(!s.priorInline.has(n.prop)){const d=b(o.el.style,n.prop);s.priorInline.set(n.prop,d==null?"":String(d))}const h=n.cssValue(c);this.applyStyleToElement(o.el,n.prop,h),s.touched.set(n.prop,h)}},end:t=>{const e=this.boxEditSession;this.boxEditSession=null,!(!e||e.id!==t||e.touched.size===0)&&this.commitBoxEdit(t,e.touched,e.priorInline)}};commitBoxEdit(t,e,s){this.historyResource?.assertCanMutate();const o=this.captureHistoryState(),i=o.styles[t]??{};o.styles[t]=i;for(const[l,c]of s)i[l]=c;let r=!1;for(const[l,c]of e)r=this.writeStyleEntry(t,l,c)||r;r&&this.historyResource&&this.historyResource.record(`Edit ${e.size} Styles`,o,this.captureHistoryState()).catch(()=>{})}inspector={properties:()=>g.map(({prop:t,label:e,type:s,options:o})=>({path:`${f}${t}`,label:e,type:s,...o?{options:o}:{}})),get:(t,e)=>{if(e==="locked")return this.lockedIds.has(t);if(e==="visible"){const l=this.snapshot().nodes.get(t);return l?b(l.el.style,"visibility")!=="hidden":void 0}if(!e.startsWith(f))return;const s=e.slice(f.length),o=this.snapshot().nodes.get(t);if(!o)return;const i=b(o.el.style,s),r=M.get(s);return r==="number"?y(i):r==="color"?k(i):i},set:(t,e,s)=>{if(e==="locked"){s?this.lockedIds.add(t):this.lockedIds.delete(t),this.store.shell.notifyIngestEdit();return}if(e==="visible"){this.writeStyle(t,"visibility",s?"visible":"hidden");return}if(!e.startsWith(f))return;const o=e.slice(f.length);this.writeStyle(t,o,String(s))}};assetSubject={get:t=>this.assetSubjectForNode(this.snapshot(),t),entries:()=>{const t=this.snapshot();return[...t.nodes.keys()].flatMap(e=>{const s=this.assetSubjectForNode(t,e);return s?[{id:e,subject:s}]:[]})}};assetSubjectForNode(t,e){const s=t.nodes.get(e);return!s||s.tag!=="svg"||!s.el.outerHTML?null:{kind:"image",name:S(s.el,s.tag),mediaType:"image/svg+xml",text:s.el.outerHTML}}writeStyleEntry(t,e,s){const o=this.snapshot().nodes.get(t);return o?(this.applyStyleToElement(o.el,e,s),this.recordStyleEdit(t,e,s),this.store.shell.notifyIngestEdit(),!0):!1}writeStyle(t,e,s){this.historyResource?.assertCanMutate();const o=this.captureHistoryState();this.writeStyleEntry(t,e,s)&&this.historyResource&&this.historyResource.record(`Set ${e}`,o,this.captureHistoryState()).catch(()=>{})}dispose(){this.historyResource?.dispose()}captureHistoryState(){const t={};for(const[e,s]of this.snapshot().nodes){const o={};for(const{prop:i}of g){const r=b(s.el.style,i);r!==""&&(o[i]=String(r))}t[e]=o}return{edits:structuredClone(this.doc),styles:t}}restoreHistoryState(t){for(const s of Object.keys(this.doc))delete this.doc[s];Object.assign(this.doc,structuredClone(t.edits));const{nodes:e}=this.snapshot();for(const[s,o]of e){const i=t.styles[s]??{};for(const{prop:r}of g)this.applyStyleToElement(o.el,r,i[r]??"")}this.store.shell.notifyIngestEdit()}subscribe(t){return this.store.shell.subscribe(t)}get persistence(){return{...x(),destination:v}}}export{D};
|