Any Suggestions for my Fog of War system?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By xofox

So I have been making this small fog of war effect for a roguelike that I’ve been making and one of the biggest issues has been making sure it doesn’t remove the fog shader if the cell is behind a wall. I figured I would use 16 rays cast out to determine if there were any obstacles that light shouldn’t be able to pass through. That aspect worked like a charm. I’m wondering if anyone has any ideas as to how I could use that information to clear a circle like area?

Thanks for the help,
Xofox