r_lighting toggles lights, material rename

This commit is contained in:
2022-05-22 21:54:57 +03:00
parent e93e616a97
commit 553280945e
4 changed files with 4 additions and 17 deletions

View File

@@ -210,23 +210,6 @@
"PostFxMaterials": {}
}
},
{
"ID": "aee0adec4b308ede0c0d32a0e1c5d585",
"TypeName": "FlaxEngine.DirectionalLight",
"ParentID": "194e05f445ece24ec5448d886e1334df",
"IsActive": false,
"Name": "DirectionalLight",
"Transform": {
"Orientation": {
"X": 0.6622079610824585,
"Y": 0.0,
"Z": 0.0,
"W": 0.7493202090263367
}
},
"Layer": 1,
"Brightness": 0.5999999046325684
},
{
"ID": "fc79615444d89ee2d290a295e1ad8004",
"TypeName": "FlaxEngine.SkyLight",

View File

@@ -218,6 +218,10 @@ namespace Game
boolValue = valueFloat != 0f;
globals.SetValue("Scene Lighting", boolValue);
Light[] lights = Level.GetActors<Light>();
foreach (Light light in lights)
light.IsActive = boolValue;
}
}