So I have multiple "NPC" objects and multiple "target" objects. I'm using ODistance to have the "NPCs" move toward the nearest "target". What I'd like to do now is make it so they will only move toward their target if there is a clear line between them.
They don't need a facing direction LoS. I want them to see in all directions at once. I just want to draw an invisible line between them and their target. If that line overlaps a backdrop, they can't see it.
Main issue with this is that I want to have a LOT of NPCs and targets. So creating a separate LoS object that scales for each NPC or having them each shoot a stream of LoS objects won't be good for performance.
Is there a performance friendly way of detecting if there is a backdrop between two objects? Preferably without using any additional actives?