aevyrie / bevy_mod_raycast

A little mesh raycasting plugin for Bevy
https://crates.io/crates/bevy_mod_raycast
MIT License
320 stars 93 forks source link

ERROR raycast: bevy_mod_raycast: Invalid intersection check: `TriangleList` is the only supported `PrimitiveTopology` #90

Closed zzhgithub closed 12 months ago

zzhgithub commented 1 year ago

when I update to new version. this happened and not cast with 'Set'? how to fix it

aevyrie commented 12 months ago

This behavior has not changed in a long time: https://github.com/aevyrie/bevy_mod_raycast/blame/424e0f0c1dcb47d759428902086727faa7a6f79e/src/lib.rs#L554

Raycasting only works for TriangleList meshes. See the bevy mesh docs: https://docs.rs/bevy/latest/bevy/render/mesh/enum.PrimitiveTopology.html