ITADN

parry3d-f64 panic: Option::unwrap() on None in point_composite_shape.rs:79 — proximity events on small box colliders

#768Openrobtfm 创建于 2026-05-08
R
robtfmcommented
## Summary Bevy preview crashes with a panic from parry3d-f64 while running a scene that uses `pointerEventsSystem.onProximityEnter` on multiple small box-collider entities. Stack trace points at a composite-shape point query unwrapping `None`. ## Crash output \`\`\` webgpu_build.js:2271 panicked at /home/runner/.cargo/git/checkouts/parry-d24c4b2901a9114b/8705700/crates/parry3d-f64/../../src/query/point/point_composite_shape.rs:79:14: called \`Option::unwrap()\` on a \`None\` value \`\`\` ## Reproduction context (SDK7 + decentraland.zone Bevy preview) Multiple small entities are spawned each with: - \`Transform\` (small scale, e.g. \`{ x: 0.8, y: 0.5..3, z: 1.2 }\`) - \`MeshRenderer.setBox()\` - \`MeshCollider.setBox(entity, ColliderLayer.CL_POINTER)\` - A \`Tween\` for continuous Y rotation (\`Tween.setRotateContinuous(entity, Quaternion.fromEulerDegrees(0, 1, 0), 60)\`) - \`syncEntity\` listing Transform / Brick / MeshRenderer / Material / MeshCollider / Tween The local client also calls: \`\`\`ts pointerEventsSystem.onProximityEnter( { entity, opts: { maxPlayerDistance: <radius> } }, () => { /* send a custom message */ } ) \`\`\` …on each spawned entity. The crash appears once a few of these entities exist and the player moves around them. (Switching to \`onPointerDown\` instead of \`onProximityEnter\` does not crash.) ## Possible direction \`point_composite_shape.rs:79\` is in parry's nearest-feature lookup. The \`unwrap()\` likely assumes a non-empty composite shape; if a sub-shape evaluates to \`None\` (degenerate, zero-volume, or stale leaf) it panics. Bevy-explorer might be passing a transient/empty collider into the proximity broadphase when these entities animate or get removed. (Filed by AI assistant on behalf of the developer; happy to provide a fuller repro if useful.)
0 条评论