It used to be possible to make light with negative color values using a script,
GetComponent<Light>().color = new Color(-1, -1, -1, 1)
I used it with a cookie texture for fog of war like this http://i.imgur.com/fFgWpFX.jpg. It worked in Unity 5.5 or 5.6, but after updating to 2017.1.0f3 it doesn’t seem to be work at all (the negative colored light doesn’t have any effect on the surroundings).
So, anyone know if this feature has been removed, or can be achieved in a different way?
I’m surprised that ever worked but, if it did, it was undefined behaviour so has possibly been fixed in some release. Colors are defined by three floating point values between 0-1, as documented at Unity - Scripting API: Color
How can a color have a negative red component? The standard blending modes regarding additive or multiplicative light would behave very oddly, and it certainly makes no sense in a PBR context. I’m unclear what you’re trying to achieve - if you want to make part of your level dark, just don’t light it in the first place?
It did behave kinda oddly with some colors, but had a couple of very useful applications since it could alter colors without increasing total brightness.
The color (-1,-1,-1,1) could be used to make the area around the light darker, which could be used for black magic effects, for example. Taking a color and subtracting 1 from each component would make that color more prominent, e.g. red with each component reduced by 1 made the surroundings much redder (spotlight with a cookie: http://i.imgur.com/QxTCD9R.jpg ).
In the fog of war image a directional negative light was used to darken the surroundings. The benefit from this compared to normal lighting is that it also darkened objects which would be lit by torches and such and made toggling the fog of war effect easy.