So far (outside of somehow adding it into Godot via C++ myself) this doesn’t seem possible but wanted to ask to see if i maybe missed something.

The most i could find was this issue and a couple of related ones.

My specific use case would be for drawing bullet holes onto meshes (via decals). Ideally also being able to determine the texture used on the faces of the meshes that are intersected (to determine an appropriate decal to use).

Having everything that is possible to hit duplicated as a static body or area seems excessive to me. Since the only data required for ray intersection should be the transform of the meshes faces/edges/vertices etc which i would think are already contained in the mesh itself?

Failing being able to make intersecting a ray with meshes work i will probably try experimenting with using areas. They seem the lowest performance cost out of all the options the existing ray cast can detect. I would still end up with most of the games geometry being duplicated though, once as actual meshes and once as collisions for all the areas.

  • Feyter@programming.devM
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    To much is always to much.

    My advice would be to implement it first and try to optimize if you need to. I think disabling object outside of a range what the player can currently interact with would probably be a good start to save performance.