Lighting mechanic for horror game

so i’m beginning development for a horror game and basically all of my plans are in place but one. i want to start the game in a pitch black house with only a flashlight with a yellowish tint, ONLY the area of the flashlight should be visible maybe some feather off the sides and the character
you then go around the house lighting candles that will partially illuminate the surrounding area with an orange tint,
how would i do this? is there a way to show only some textures of objects or something?

1 Like

I made a lighting system previously (This). For what you want this doesn’t work, but the system can be slightly modified to work like a flashlight. Normally the system would cover the view, but if you reverse it will act like a flashlight. Normally if you wanted a 60-degree view it would cover that, but if you instead have a 300-degree light in the opposite direction it will work like a flashlight.

There is a problem with this, in the direction that you can see you will be able to see until the edge of the screen.
(I probably did a bad job explaining this so just @ me if you want me to explain something in more detail)

3 Likes

Also, if the “light” extends to the edge of the screen then a screen overlay would work the same, so my suggestion wouldn’t quite be the best.

Heres another idea
You could use thebrickccentric lighting example for the candles (Will need to be slightly modified so it doesn’t update every other frame). And for the flashlight thing, I would need to think about it more to make it also work with the candles

2 Likes

i was able to get the first version of the lighting system to work!

1 Like