Check if the objects center is being obstructed

Hi, i’ve been wondering if there’s a way to check if an object is being obstructed by another object that is in front of the camera. Pretty much how a lens flare works (If the plane’s center is being obstructed by an object infront of the camera, the object becomes invisible until it’s not being obstructed anymore.)

Oh, and there’s also another small question. Is there a way to make an object get bigger as the camera gets away from it? Thanks, and any help is appreciated :slight_smile:

Use a ray, the object cast a ray to the camera.
For the second question, if you use python you can make it, get the distance to the object with getDistanceTo() and scale the object using that value.