Skip to main content

Set Directional Light Intensity

Sets the intensity of the directional light shining on the terrain to the input.

Set Directional Light Intensity block

Description

The Set Directional Light Intensity block sets the intensity of the directional light shining on the terrain to the input. This is a code block part of the Environment drawer.

Usage

Use Set Directional Light Intensity to control the brightness of the ambient lighting in your simulation. This can be linked to slider values for dynamic control or set to specific values for different lighting conditions.

Syntax

Input:

  • A number (intensity)

Example

The directional light intensity of the world which gives it ambient light is set to be the slider value at all times.

Set Directional Light Intensity example code