> For the complete documentation index, see [llms.txt](https://gley.gitbook.io/mobile-traffic-system/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gley.gitbook.io/mobile-traffic-system/setup-guide/traffic-lights-crossing.md).

# Traffic Lights Crossing

A traffic light crossing is a pedestrian crossing with traffic lights, something like this:

<figure><img src="/files/Mx0jVIkM3aPSOgu5i4XQ" alt=""><figcaption></figcaption></figure>

To set it up go to **Settings Window -> Intersection Setup**

<figure><img src="/files/O1iPOc0xCjcQ3MkbBUWc" alt=""><figcaption></figcaption></figure>

If **Show All Intersections** is checked you will see the intersections from the entire scene. If unchecked, only the intersections visible in the scene view will be displayed. Using the **View**, **Edit,** and **Delete** buttons you can perform the respective operations on each intersection from that list.

Press Create Traffic Lights Crossing to create a new light crossing. This will open the Traffic Lights Crossing Setup Window.&#x20;

<figure><img src="/files/xKbbFCYINk53w80tW8Vj" alt=""><figcaption></figcaption></figure>

**Hide Waypoints** - will hide the scene waypoints offering you the possibility to select different objects inside the scene.

The **Green** and **Yellow** times will be applied if the corresponding times in the Traffic Component are set to -1. See the [Initializing Asset](/mobile-traffic-system/setup-guide/initializing-asset.md)section for more details.

The **Red Light Time** is the time allowed for pedestrians to cross the road.

Press **Assign Road** to select the stop waypoints.

Select the waypoints where you want cars to stop at red lights. Selected waypoints will be marked with red circles.

Select your red, yellow, and green light objects. They will be enabled when that light color is on and disabled when the light color is off.

<figure><img src="/files/FtlEVYexd7pzf3jBZMnB" alt=""><figcaption></figcaption></figure>

You can add more waypoints to any road by using the **Assign Road** button.

You can delete a waypoint by using the **Delete** button.

Using the **View** buttons, you can focus the scene view on the selected waypoint.

{% hint style="warning" %}
If an intersection does not change the light colors it might be outside of the active cells. See the [Prepare Scene](/mobile-traffic-system/setup-guide/prepare-scene.md)section for more info.
{% endhint %}

If you want to check the status (the color of the traffic light) you can use the API[GetTrafficLightsCrossingState](/mobile-traffic-system/complete-api/gettrafficlightscrossingstate.md). If the color is Red make your pedestrians cross.
