Multiple fog color

Is it possible to define a fog color per camera ?

The reason am asking is because i’m working on a multiplayer game / installation where the users control some small swimming animals.

The animals can swim around just below the water surface or dive down into the deep. To simulate that I simply use the animals y position to fade the back ground color between a light surface color and a very dark bottom color

To simulate the water I use fog, the fog color I set to the same color as the background color, this technique works very well, when using only one camera ( = 1 player).

But I need to make it work with 3 cameras ( one camera = 1 player) and since the 3 cameras will be tracking the players animals, the background color on the different cameras will probably never be same, and that is why I need 3 different fog colors.

Or maybe there is a better way to simulate that you are underwater.

Hope my question makes sense

You can adapt that script to modify the fog color instead of only enabling/disabling for per camera.

thanks for the quick reply Joachim.

your solution did the trick

thanks again

  • claus bjerre

I liked that little Fog Layer component… it inspired me to do a full CameraRenderSettings script for all the render settings and paste it to the community wiki:
http://www.unifycommunity.com/wiki/index.php?title=CameraRenderSettings

Great stuff Keli.Thanks
AC

This link ins’t working. Is this still available?