Line of sight replicating as in Nox(2000)?

Hello

I was hoping someone could point me in the right direction to try and implement the TrueVision/trueSight system like in Nox, a game from 2000.

From the wikipedia:
“The line of sight is limited by an innovative and well-received fog of war system named “TrueSight”, which dynamically blacks out portions of the screen which Jack cannot see from his current position.”

You can see it in action here:

Basicly, the player sees everything in 360 degrees, the player can see. Everything else gets “masked”/hidden with black.

I’ve been thinking maybe (constantly?) doing a 360 degree raycast but that seems pretty excessive on performance?
Maybe some shader magic? (I don’t really know a lot about shaders but if I can be pointed in the right direction I could try that approach).

This asset seems to do the trick, I’ll try to contact the developer also

EDIT after some more work and tutorials:

Thanks for the fast reply! I have followed Sebastian Lague’s tutorial on raycasted line of sight, it seems to work great and what I wanted up to E02.
Only thing now is that I’m stuck on how to figure out that only the walls should get rendered.
I followed his third video

This is what I have after E02.
medicalmeanconure

This is what i have after E03:
meanwavyavians

So I really like the E02 video look I have got going on but just want everything black outside what I can see and have the objects (like walls/windows/players) etc… be visible when they enter my line of sight… I’m breaking my head over this!

This is what I’m going for:

More info from Nox map editor:

This may help:

https://iaco79.wordpress.com/2015/03/27/lights-and-shadows-for-2d-worlds/

And here’s a completely different approach:

https://www.gamasutra.com/blogs/RobWare/20180226/313491/Fast_2D_shadows_in_Unity_using_1D_shadow_mapping.php

Would this also work in 3D?

I’m sure it could be made to work for a 3D isometric-ish game - perhaps rendering a top-down view of the shadows/LOS to a rendertexture, then projecting it onto 3D geometry in a shader. (Would be trickier for an isometric game with 2D assets)

Thanks for the fast reply! I have followed Sebastian Lague’s tutorial on raycasted line of sight, it seems to work great and what I wanted up to E02.
Only thing now is that I’m stuck on how to figure out that only the walls should get rendered.
I followed his third video
https://www.youtube.com/watch?v=xkcCWqifT9M

This is what I have after E02.
medicalmeanconure

This is what i have after E03:
meanwavyavians

So I really like the E02 video look I have got going on but just want everything black outside what I can see and have the objects (like walls/windows/players) etc… be visible when they enter my line of sight… I’m breaking my head over this!

This is what I’m going for:

i’ll put this as an edit in the OP

This video might help. It creates a custom mesh based on raycasts and renders it to hide what the Player can’t see.

how you reach to it