It's possible to raycast transparent objects too?

I’m trying to fade in objects, which hides player avatar from the camera, and fade out objects, which is no more hide it. But raycast is not possible, when object’s alpha is 0, so previously hidden object will never know, if it already no on the ray. Is it possible to raycast, ignoring the alpha value? Or I have to create such math method manually?

Raycasts don’t care about the color of a renderer whatsoever. They only care about colliders and layers.

That’s strange. So the reason of no hits in RaycastAll result is different

Yep. It could be a wrong layermask or maybe your ray is not correct.

But, initially, all needed objects is catched by the ray. But, after alpha is become 0, no hit seems to be exists. So, this is not connected directly

Are you sure you are only changing the alpha and nothing else? Can you share your code?

After replacing List for hidden objects with Dictionary with InstanceIds as a key, all works correcly. “Contains” seems to be not working with Gameobject list

RaycastAll worked wery well, but there was incorrect condition to accumulate hidden objects for current frame. So, when raycast was still hit same object, other part of system thinked, that there are no raycast hit in this frame