Description
The FogStrength
property of the SceneLight
class represents the intensity of the fog effect applied to the light. This property is a float
value that determines how strongly the fog influences the light's appearance in the scene. A higher value results in a more pronounced fog effect, while a lower value reduces the fog's impact.
Usage
To use the FogStrength
property, you can get or set its value on an instance of the SceneLight
class. Adjusting this property allows you to control the visual effect of fog on the light, which can be useful for creating atmospheric effects in your scene.
Example
// Create a new SceneLight instance
SceneLight myLight = new SceneLight();
// Set the fog strength to a moderate level
myLight.FogStrength = 0.5f;
// Retrieve the current fog strength
float currentFogStrength = myLight.FogStrength;
// Output the current fog strength
// Note: Avoid using Console.WriteLine in Sandbox
// Instead, use in-game debugging tools or UI elements to display values
// Debug.Log($"Current Fog Strength: {currentFogStrength}");