- Home /
Making a specified area "darker"
So i have a dark forest set up with a sun, the intensity of the sun is pretty low making it gloomy.
But now as i leave the forest i want it to become brighter. (For en entire rest of the map) And im thinking its probably easier making the forest area "darker" than making everything else somehow brighter.
How would i go about setting this up? (Im a complete noob, so if your going to talk script, please be gentle..)
Thank you :)
Answer by GerryM · Sep 20, 2012 at 04:00 PM
Assuming your sun is a directional light, I would change it's intensity depending on the player / camera position.
You could set up a huge box covering the forest as a trigger. In it's Collider.OnCollisionEnter function you can set the light's intensity to the lower value, in Collider.OnCollisionExit you would set the intensity to the higher value.
Add a gameobject variable and set it to your directional light. You can access the intensity via light.intensity.
Another way would be using image effects in UnityPro.
Good luck!
Your answer
Follow this Question
Related Questions
Light.intensity and Lumen comparison 0 Answers
Auto White Tonemapping Issue 0 Answers
Problem with Simple Script - Rotation and Data Types 1 Answer
Shaders: Brightness of a colour? 1 Answer