TreeInstance contains a variable called 'lightmap' which is a type Color. Set this to something like Color(0.5,0.5,0.5,1.0);
Works now. And this answer trumps all others I have found up til now. My terrain trees are also generated by code, this was all I needed.
function genTrees()
{ for (var c=0; c<4; c++)
{ var tempTreeInstances:TreeInstance[] = new TreeInstance[100];
var tempTerrain:Terrain =grid[c].GetComponent(Terrain);
for(var d=0; d
↧