pxt-ev3/docs/coding/traffic-lights-1.md
Peli de Halleux 2467b3c4c9
renaming pauseforcolor to pause until color detected (#405)
* renaming pauseforcolor to pause until color detected

* pauseForLight -> pauseUntilLightConditionDetected

* on light changed -> on light condition detected

* fixing docs

* docs tweaks
2018-04-03 05:05:01 -07:00

9 lines
232 B
Markdown

# Traffic Lights Activity 1
```blocks
brick.buttonEnter.onEvent(ButtonEvent.Bumped, function () {
motors.largeBC.tank(20, 20)
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
motors.largeBC.tank(0, 0)
})
```