Menu
Lumberyard
User Guide (Version 1.13)

Setting a Day-Night Cycle

You can use the Time of Day Editor to configure changes to environment parameters over time to mimic a day-night lighting cycle. The Time of Day Editor uses a 24-hour timeline graph and a recording function to store changing environment parameter values in an XML file. Select the red button to record.

Environment parameter values that you change in the Parameters panel of the Time of Day Editor are set for the currently selected time. The Time of Day graph shows changes to the selected parameter over time. When a parameter value is changed, the graph curve is updated for the currently selected time. You can also directly change the curve by dragging it up or down between the keyframe points. Keyframe points are displayed as yellow dots. You can insert new keyframe points by double-clicking the curve. To remove existing keyframe points, double-click the keyframes (yellow dots) themselves. Lumberyard interpolates parameter values for times that lie between keyframe points.

To configure a day-night cycle

  1. In Lumberyard Editor, click Tools, Other, Time Of Day.

  2. In the Time of Day Tasks pane, under Tasks, click Toggle Advanced Properties to view all parameters.

  3. In the Parameters pane, adjust the parameter value for each cycle that you want to create. Then do the following:

    1. Click the red button to start recording.

    2. In the Time of Day Tasks pane, under Time, set the Current Time to apply the parameter value. The graph reflects the new value at the specified time.

    3. Set a new parameter value and current time value pair. Repeat as many times as needed to get a realistic change over time for the parameter.

    4. Click the red button to stop recording.

  4. In the Time of Day Tasks pane, complete the following tasks as needed to export, import, and play a time-of-day (day–night) cycle.

    Import From File

    Imports cycle settings from an .xml file.

    Export To File

    Exports cycle settings to an .xml file.

    Reset Values

    Resets all parameters to their default values.

    Current Time

    Sets the current time in the Time of Day editor.

    Start Time

    Sets the time to use when the game starts. This is not the same value as the current time.

    End Time

    Sets the time to use when the game ends. If you set the end time to 23.59, the time loops and starts the next cycle when the day is over.

    Play Speed

    Sets the speed at which time advances in the cycle.

    Play

    Starts or resumes the playback of the cycle in the Time of Day editor. If the current time value is not within the start and end times, playback begins at the specified start time.

    Stop

    Stops the playback of the cycle in the Time of Day editor.

    Force Sky Update

    Updates the sky lighting calculations in each frame. If deselected, calculations are distributed over several frames. The effect may not be visible for some time.