Hello everybody !
I manage to make an effect to visualize to sight of the units in my RTS game.
I use a sphere and a material that use distance field.
In order to avoid that the sphere detect its own distance field, I uncheck the “affect distance field” box for the sphere.
But when I select several of my units, there respective spheres are drawing the visualization inside other spheres…
I which to merge all these sphere into one big zone that show the total sight of the group, not several circles.
How can I make my material to detect that it is inside another volume ?
I can’t use distance field here because I already did and I have deactived it for the spheres.
I can add a spheric collision volume easily but I don’t know if nor how I can use it in my material.
Is it possible ?
If it is, can you give me a lead that I can follow ?
It will be awesome if I can found a way to also detect the intersection between 2 sphere to draw something at it as I do with the world and the distance field…
You can say I’m a dreamer… But I’m not the only one
EDIT : I’ve thinking at using depth fade on my material (it’s a transluscent mat ^^) and didn’t use the distance field in the sphere’s mat anymore.
This way, I can reactivate the distance field on the spheres and the “no distance field solution” constraint is over