I’m a bit of a newb with Blueprinting, so I was hoping someone could offer some advice on how to achieve this effect:
Imagine a house on a flat grassy field, with a sky above. The house is 20m long, 20m wide, 20m tall and has a single room as interior. A character is standing inside the house, right in the middle, so that he is 10m from any nearest wall.
Standing in the middle of the room, the entire house should be invisible to the character. Only when the character walks within, lets say 2m of the wall, does the wall become visible. But only parts of the wall within 2m become visible, the rest of the house remains invisible.
So, to summarise: How to make an object visible only when within a specified distance from the Camera? And only parts of that object within the specified distance become visible.
Any advice or suggestions on how to do this would be awesome. Many thanks!
In unity you could have culling masks and layers for each thing you wanted to render . Not sure if unreal has the same things though as I think the render pipeline is different
But like I said try playing with the camera settings like view frustrum etc first.
Could also look into using custom depth
So it would work in a similar way to a torch beam facing the wall . The stuff directly in the light beam would be rendered and then the stuff outside of the torch circle in the shadows would be culled/ not renders
As for setting visibility of the meshes easiest method is probably to line trace out from you’re camera and see what it hits . Check the distance if the distance is less than the desired visibility range then set static mesh to visible