- Home /
Question by
drjd24 · May 02, 2013 at 04:58 PM ·
fogunderwater
Underwater Script
So i was browsing the answer forums and i could not find anything similar to what i needed. I tried my own script, but it didn't work. Nothing at all
public var underwater = 90;
function Update() {
if(transform.position.y < underwater)
{
color = Color (56, 166, 198, 122);
RenderSettings.fogColor = color;
RenderSettings.fogDensity = 0.1;
}
else
{
color = Color (78, 142, 149, 122);
RenderSettings.fogColor = color;
RenderSettings.fogDensity = 0.0004;
}
}
Comment
Your answer
Follow this Question
Related Questions
Individual fog change 0 Answers
Underwater fog is working but how do I prevent the world fog from turning off? 0 Answers
Camera Effect for partially Underwater View 0 Answers
underwater fog script 1 Answer