bbi.environment.time_of_day

pydantic model TimeUpdateParam

Bases: AnimationFrame

field time: Annotated[int, Field(ge=-1, le=23)] | None = None
class Time(time: int = 0)

Bases: Node, Animatable[TimeUpdateParam]

Class for controlling the time of day.

The World has a default time of day accessible via world.env.time_of_day.

Time, or the hour of the day, is represented as an integer from 0 to 23. A value of -1 disables the time of day.

Parameters:

time (int, optional) – The time of day in the world from 0 to 23. Defaults to 0.

property time: int
set_time(time: int) None

Set the time of day.

Parameters:

time (int) – The time of day in the world from 0 to 23. A value of -1 disables the time of day.

execute(frame_id: int | None = None, frame_max: int | None = None, delta_seconds: float | None = None) None

Updates the time to the specified frame.

Parameters:
  • frame_id (int | None, optional) – The frame ID. Defaults to None.

  • frame_max (int | None, optional) – Max frame count in the current loop. Defaults to None.

  • delta_seconds (float | None, optional) – The target real-time in seconds between frames. This is used to calculate physical displacement for certain assets. Defaults to None.