Implementing 2D field of view (line of sight or shadow casting) visually

Hello, I’m making a 2D shooter game. I’m trying to make this something effect like this:

taken from this video

I only need the visual tho, the shadow thingy, not the actual part of render and unrender the object when outside of view, the current system I have:

Made this using raycasting and editing the root Motor6D C0 position when it is not rendered.
How do I make the shadow thingy then?