pelican-engine 0.3.14 → 0.3.16

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/AGENTS.md CHANGED
@@ -137,6 +137,33 @@ all earlier automatic ropes from that phase; the host tick may still have other
137
137
  partial changes and must be recovered from a known-good checkpoint. The source
138
138
  checkout includes `examples/rope-particles`.
139
139
 
140
+ New ropes resolve discrete sphere overlaps along segment interiors as well as at
141
+ particles. Corrections are distributed to movable endpoints; a segment with two
142
+ fixed anchors cannot move. `ctx.ropes.inspect(id).segmentContacts` reports the
143
+ segment index, closest-point fraction and reaction impulses. Set
144
+ `segmentCollisions: false` to retain particle-only behavior. Historical rope
145
+ solver snapshots without this field retain particle-only behavior when migrated;
146
+ `inspect(id).segmentCollisions` reports the active mode. Normal Host snapshot
147
+ engine-version restrictions still apply. Plane contacts use particle endpoints.
148
+ The segment index names its first particle; `fraction` runs toward the next.
149
+ Work increases with segment, sphere, substep and iteration counts. This does not
150
+ provide continuous collision detection or self collision, and the segment solver
151
+ and snapshot migration have not been runtime validated.
152
+
153
+ For optional visual presentation, declare a material in `defineGame({ materials:
154
+ [...] })` and create the rope with `visual: { material: "your-material-id" }`.
155
+ The renderer draws capped cylindrical instances between consecutive simulated
156
+ particles and updates their transforms as the rope moves. `radius` defaults to
157
+ the particle collision radius (or 0.025); `radialSegments` defaults to 8 and
158
+ accepts 3–32. `castShadow` and `receiveShadow` default to true. A collapsed
159
+ zero-length segment has no visible surface. `ctx.ropes.visuals()` returns
160
+ detached descriptions, not renderer objects. Visual configuration is included
161
+ in the rope snapshot and is disposed with the owning content.
162
+
163
+ This is segmented geometry with overlapping caps, not a continuous deformable
164
+ tube. Large ropes may be expensive. Raster, ray-traced modes, GPU resource
165
+ lifecycle and snapshot restoration have not been runtime validated.
166
+
140
167
  To bind a rope to existing dynamic sphere bodies, create it with `autoStep: true`
141
168
  and `bodyColliders: [{ id: "rope-collider-id", entity: "body-id" }]`. After the
142
169
  rigid-body physics phase, the host samples each bound sphere's actual collider
@@ -167,8 +194,8 @@ automatically act on a rigid body.
167
194
  For an explicitly mapped dynamic body, game code can read its actual world center
168
195
  of mass via `ctx.physics.centerOfMass(id)`, apply the linear impulse, and apply
169
196
  `reactionAngularImpulse - centerOfMass × reactionImpulse` as torque impulse.
170
- Apply each contact at most once for its `tick`; repeated `inspect` calls return
171
- the same contacts. The source checkout's `examples/rope-reaction` uses the
197
+ For manual coupling, include both `contacts` and `segmentContacts` and apply each
198
+ contact at most once for its `tick`; repeated `inspect` calls return the same contacts. The source checkout's `examples/rope-reaction` uses the
172
199
  automatic binding instead.
173
200
 
174
201
  This sampled, manually applied reaction is delayed and uses positional correction,
@@ -178,9 +205,8 @@ operations and is not transactional if a tick fails; recover from a known-good
178
205
  checkpoint. It must not be represented as complete two-way rigid-body interaction.
179
206
 
180
207
  This is an unverified development-stage increment, not complete rope physics:
181
- there is no built-in rope mesh, general rigid-body coupling, segment or self collision,
182
- or tearing. Moving entities to particle positions is not a rope renderer or
183
- coupled physics. Plane normals must be unit length; `offset` is the signed
208
+ the optional segmented visual does not provide a continuous deformable rope mesh,
209
+ general rigid-body coupling, self collision, or tearing. Plane normals must be unit length; `offset` is the signed
184
210
  normal distance from the origin. Host intervals must be between 1/1000 and
185
211
  1/30 seconds inclusive.
186
212
 
package/distribution.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "format": "pelican.npm-distribution",
3
- "version": "0.3.14",
3
+ "version": "0.3.16",
4
4
  "files": {
5
- "AGENTS.md": "4e031adeec0446317141f17c9f04c8d6c03f7339f00e27687331dd8051a4c807",
5
+ "AGENTS.md": "dd3925d893723b32047d2b0fe46a372189873574afab91f2a9ce0f4653845f36",
6
6
  "CONTRIBUTING.md": "0ffad5d841d90f319fc50a75b81d3c0ad6dab8d5d9bec2846c65c7f8358d5a50",
7
7
  "docs/AI-WORKFLOW.md": "aa992686df93f791795f6f3fce01713d812eea6a1b9556f07411ac5847278efa",
8
- "docs/api/index.json": "31ea1aa6c3531cdd2df129ae10fed54f666be4cb69c005c556690339f7b9a420",
9
- "docs/api/REFERENCE.md": "ba657a3fb169e0f6c6e77ab1233cfb94125daf6ce4914ec0e960e4b1bf07d884",
8
+ "docs/api/index.json": "daa7ab5af413e24a1de98a6c90eecbab40f983ab3bd7984d85e3356efb82da99",
9
+ "docs/api/REFERENCE.md": "6eef5cfff041c36b2457c87a77cb3bb8710d02b3aca3063c1d5e516921d87f68",
10
10
  "docs/ARCHITECTURE.md": "3184b73592d466390e7793b1cf39bbb80d6052b523fba7e7cb377b5207074627",
11
11
  "docs/assets/pelican-mark.svg": "407b10cd7e292ea83cf5dba4046fb2f01c7d566a14014c55deda3a2984562b4d",
12
12
  "docs/CAPABILITIES.md": "92950817497d8c63db07830db96dc93c877befa8d038320feed1ae1f1a053cb1",
@@ -14,14 +14,14 @@
14
14
  "docs/GETTING-STARTED.md": "5519ebe4e513e8ae4517c04948ee9dc70bcb1e3d04a65d468a6537c838502663",
15
15
  "docs/GRAPHICS-GUIDE.md": "e3d0f7df6189ca3f88d81af5ffaf393f5d6bf39b9e66167bb2f64b39194b514c",
16
16
  "docs/npm/DISTRIBUTION.md": "ff25e039921a85ba253c27608c77ed614a036117d7a04f908a78d1e3ed3f19ef",
17
- "docs/npm/GAME-AUTHOR.md": "4e031adeec0446317141f17c9f04c8d6c03f7339f00e27687331dd8051a4c807",
17
+ "docs/npm/GAME-AUTHOR.md": "dd3925d893723b32047d2b0fe46a372189873574afab91f2a9ce0f4653845f36",
18
18
  "docs/PELICAN-MIGRATION.md": "c5d6ab8e5186f4d36720a0a01d1a7e4157a5d386c5400e2db99571a7d10a1e49",
19
19
  "docs/PHYSICS-LIFECYCLE-ISSUE.md": "cc78917462de4e7e9b68e77c742192ce213b4be5b516d2ba943251fff46977ac",
20
20
  "docs/RENDER-BACKENDS.md": "d981ea94742a835d028db37d536fb7fba05102e37bc6274a37baf74f5034b954",
21
21
  "docs/ROADMAP.md": "29ac1c54f36064e23c17cfe7f549d6860889257a57d1227e322958aa9c281568",
22
- "docs/STATUS.md": "75dc60834515914a7177198a01f7bbdd7a6437feac62cf555657dde7823b0a95",
22
+ "docs/STATUS.md": "363e45b13d7af2134309cdc7622e903224672bcfdfc56fc4495329eaf1409588",
23
23
  "docs/THIRD-PARTY-NOTICES.md": "58f9b72e2b4dfaaaf2a4c08b9bde9ecef3d2b7e7d65fccd782ed54f39fa76fdc",
24
- "engine.manifest.json": "e6b474c204d00972619b80f4157c57b4d748e89913fa5455583c961e11dcf875",
24
+ "engine.manifest.json": "07aeec81ff664b6f34a1b2435879d19fa59ff4db92bf5053c5aabd2a94300a0a",
25
25
  "lib/assets/audio.js": "6facdce4e053afd172af5b9407569b035169844ea17b49f93f8b67f72b78895f",
26
26
  "lib/assets/errors.js": "70572678655c6e53179d31920d71f29882d373a0e12d560220bb0fc2cd74f2cc",
27
27
  "lib/assets/glb.js": "b808479a36299c154db97f50c16863a3b5a2c61f725e66bf01d01a5f62a288a5",
@@ -54,7 +54,7 @@
54
54
  "lib/physics/index.js": "d2f61506b26078c75ac12ea73a6ee17c62b833145dfe950fd66835659ede30b3",
55
55
  "lib/protocol/index.js": "875c9f7ba4e67adc182aa177bc5017da0907ff9c584ba523021a219b26e38c89",
56
56
  "lib/renderer/acceleration.js": "50ccafc9bc5b463470a23cffbdff8dc1a29a77bada44d21caf1eb0c3f9de2c65",
57
- "lib/renderer/browser.js": "0ef885517bef24b12a68e898d274643f5a8ee164d1956c27dc470a9a6c5a431e",
57
+ "lib/renderer/browser.js": "46e7fd62b7751f3168c171459641dcccfefe9888b60945062b999998d842a672",
58
58
  "lib/renderer/bsdf.js": "d6d3cd69dadb418dfb794367ac8158ef242799e248b13f4f88edeeb67ee08c69",
59
59
  "lib/renderer/checkpoint.js": "7d6b0447b924eb260aa6a8724d17ad69e2949186b2f639dff5f6bbea388f8c62",
60
60
  "lib/renderer/compute-executor.js": "7a9d199a1ab4f56fc99c50f82760e18169a905e63a8fa24011fb86c03e8c890a",
@@ -67,7 +67,7 @@
67
67
  "lib/renderer/environment-importance.js": "b192af1173eb8235ab3f8cbe34fe7de92fe35bf970c214d7d3a122a5c77006d9",
68
68
  "lib/renderer/environment.js": "e7eff454f49e969f188d58e936cb41c217413902af5de4d9fefa3212c3394692",
69
69
  "lib/renderer/gameplay.js": "e77b116413339af97d1e24f59b77035eeea8297ddc29963bbe21173c10077673",
70
- "lib/renderer/geometry.js": "262674d0b8c45f71a937ef5f8fde023287e14f985bd80ffcf11aa778523ba4bc",
70
+ "lib/renderer/geometry.js": "8f331cb3547751a70099d80441b146e5a66072c94e23cc9f5716694d0efa1019",
71
71
  "lib/renderer/graph-expressions.js": "3cc20d472f3894976b6c8e503b915c3eaf12de9c6d93bae45edb12b0f7e0dc4e",
72
72
  "lib/renderer/graph-tsl.js": "d698d22fd2977aabd3f7331e8f3d46d8cbf80695ea503b9326cff470859e84b4",
73
73
  "lib/renderer/graph.js": "1d5e9afff7d4f43c26c0bb82f3b6cb475a75af2750101114f0d7b03193bccfa7",
@@ -82,6 +82,7 @@
82
82
  "lib/renderer/postprocess.js": "bac52cbec8449b66e35c6ff0b80486b062a7d7d52961b9ae5073b3fb9f24622a",
83
83
  "lib/renderer/render-buffers.js": "db61cb80f691616b45ddb98231805469d54c12237497f6e4c709c1affc23cbf9",
84
84
  "lib/renderer/render-textures.js": "fe98d2657701350eaeb731c2158db22e44e9a8a308f92e661f780f66fa46428c",
85
+ "lib/renderer/rope-visuals.js": "4bceb1c55ffc7283b24136e126c07e7e28fb631a2f4cb3afd619b1eab6db80fa",
85
86
  "lib/renderer/startup.js": "2e4f8de3362358aad23504304219533f8ef25825abb3bb702bc960e2cfa79a1d",
86
87
  "lib/renderer/surface-capture.js": "847edf8c764a4e8b586bee9a441013ba362875e83a957c65ad51433ae623e59f",
87
88
  "lib/renderer/surface-gpu.js": "0db76e8873999c6b5ee3da0456e4b60d5df8d5154886a29bc0895782fdd9036b",
@@ -123,11 +124,11 @@
123
124
  "lib/runtime/world.js": "c43621fbaca8bd2b0d6477a96e60e895312f0f7b1eb97614b6e4f9b716129ea1",
124
125
  "lib/schema/index.js": "594429eecb4494c4af2f3d04537be3211f2c9297a1fc555bbba5d028d8627965",
125
126
  "lib/sdk/graph-values.js": "a58c00f127cb82aba5fd2824981942844e06d9a59a88a05e35d1d3df2fc7ed2f",
126
- "lib/sdk/index.d.ts": "f8b095dc14e5a0804a0ba5e102f144c8775f4f4e0194ce2a24ff5bd7904c425c",
127
- "lib/sdk/index.js": "3d70f1320a1739e255b461724b91d1a1fa3caeeba17a4d162155727d96f8026a",
127
+ "lib/sdk/index.d.ts": "e9be65ce2d1d2cb59bbf8f1e8749887e7f17aa5cdd0faab30d310b2e2ff42a5f",
128
+ "lib/sdk/index.js": "68283b99b69b822d5030e71d86db8ad6989533e694cba5ed765bf3c307e9583f",
128
129
  "lib/simulation/rope-body-coupling.js": "70694b73d17c79f223803a51fbf4a4dae551b717cd29bbea1fa38386ac98d621",
129
- "lib/simulation/rope-plugin.js": "050b64e82d196087aafe47047b3849e22fe8af362e3a7436dc0299c7a470d385",
130
- "lib/simulation/rope.js": "ae653f44a8edaf206ba5a0cfe8d5bf5ebe7d3fc97714368c5b97e4f870a6ec9f",
130
+ "lib/simulation/rope-plugin.js": "e96bf5c6ead475b8f14d65d5290770025a4cef6e21d9d11bbe73ae4173b20062",
131
+ "lib/simulation/rope.js": "3ceb972b55ba197e526b6c8896b2e7a48dcb05f38be0a0efbca188399eaf5469",
131
132
  "lib/tools/api-index.js": "6aedc153a0ce8eaf18239b0368a76a8ae8e4397bd8e6cdf571889bc39265be5d",
132
133
  "lib/tools/browser-session.js": "1fa7f78d4752d8a59a55dc2283b4d42cd1df230f0d5a5dc80c6d78ade45b4cdb",
133
134
  "lib/tools/cli.js": "ad5e915f046cc2e6bf612edd1a88cc33758b1d2b0ce2f057be50e0a2c4770062",
@@ -198,7 +199,7 @@
198
199
  "licenses/undici-types/LICENSE": "a6db8096b2707bc0102d256917d4d33f298ba36d8c3f25de067a2b5bb379db27",
199
200
  "licenses/uniq/LICENSE": "e67aed7df22dc8031e4fcf5338fe91cb33e3817e5c58a99a2a2802eea9069791",
200
201
  "licenses/vite/LICENSE.md": "a22152baa1aef74402443008e767e7c689a524c0909d19b0431d97f5ab066a13",
201
- "package.json": "d5874a4eba7869c56faef55c73a9b107eb209b6d3850f25943452e8fcfd83525",
202
+ "package.json": "4ff56c89dfd8f7583f2ad1d2c625b5ea0b01a9f3f163d70ef287af4401b47383",
202
203
  "README.md": "ff25e039921a85ba253c27608c77ed614a036117d7a04f908a78d1e3ed3f19ef",
203
204
  "web/index.html": "d89d6a5b5be3beae3627a8ed506ac308b165d264fb8696be3afd79fcca2f26ee"
204
205
  }
package/docs/STATUS.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  ## 版本与发布
4
4
 
5
- - 当前版本为 `0.3.14`,包、锁文件、引擎、SDK、编译器和示例中的版本保持一致。下一项功能完成后统一递增并推送;相同版本不能重复发布。
5
+ - 当前版本为 `0.3.16`,包、锁文件、引擎、SDK、编译器和示例中的版本保持一致。下一项功能完成后统一递增并推送;相同版本不能重复发布。
6
6
  - 推送主线会通过 GitHub Actions 和 npm 可信发布更新 `latest`;GitHub Release 用于记录里程碑。历史版本和旧标签保持原样,不代表当前源码通过。
7
7
  - 当前按用户要求仅允许编译和构建,不运行测试、浏览器、GPU、性能或其他验证。普通版本号不意味着运行行为、硬件或完整引擎已验收。
8
8
 
@@ -12,7 +12,7 @@
12
12
  - 动态光追、路径追踪、受控图形计算和 WebGL2 回退已有研发实现,但当前源码的完整画质、性能、兼容性和资源生命周期未验证,不能称为完整首发。
13
13
  - 刚体首步前删除存在已知缺陷;历史候选存在旧快照兼容及危险历史回放风险,不得通过修改夹具或在主进程回放危险历史掩盖。有关背景与原始证据保留在历史任务文档中。
14
14
  - 正交网格导航新增批量障碍更新接口;它只处理单个网格的阻挡状态,不等于世界流送、实体变换或物理联动。该增量尚未进行运行行为验证。
15
- - CPU 粒子绳索已接入 `ctx.ropes` 和 Host 快照,支持手动或自动固定步进。显式绑定的动态非触发球体可在物理阶段后被采样,并接收绳索投影产生的反冲量;其他采样球体/平面仍为单向。尚无绳索网格渲染、完整双向求解、绳段/自碰撞或撕裂。该增量尚未进行运行行为或快照兼容验证。
15
+ - CPU 粒子绳索已接入 `ctx.ropes` 和 Host 快照,支持手动或自动固定步进。显式绑定的动态非触发球体可在物理阶段后被采样,并接收绳索投影产生的反冲量;其他采样球体/平面仍为单向。可选分段圆柱实例随粒子位置更新;它不是连续变形绳索网格。新绳索默认对绳段内部与球体的离散重叠求解,旧粒子型快照保留原模式;尚无完整双向求解、自碰撞或撕裂。渲染、碰撞、运行行为和快照兼容均未验证。
16
16
  - 动态球体绑定的接触响应已纳入刚体接触点速度、有效逆质量和转动惯量;绳索阶段使用虚拟状态、按绳索顺序求解并延迟提交冲量。真实刚体位移在下一物理步更新,仍无全局耦合子步、摩擦、恢复系数或连续碰撞,不代表完整双向物理。稳定性、守恒、运行和快照兼容尚未验证。
17
17
  - 布料、绳索、软体、流体、连续世界、导航、动画、音频和其他首发能力仍需按各自依赖完成,不能把独立候选或局部实现写成整项完成。
18
18