Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(+2)

Glad you liked it! There are two parts to the effect:
The visual hole is done by fetching the light attenuation at a fragment, if it is high enough, we discard it (overlayed with some screen space noise)
The collider hole is done by splitting the wall collider in four (left, top, right, bottom). The colliders are scaled and positioned based on four ray casts from the light source (an approximation of the spotlight volume). So the result is a rectangular hole in the collider that encompasses the circular visual hole.

Hope that makes sense :D