From 50f0e858848c521fd17bcd29b3f0a09df14dc8c6 Mon Sep 17 00:00:00 2001 From: Peli de Halleux Date: Tue, 20 Dec 2016 12:31:25 -0800 Subject: [PATCH] docs updates --- docs/getting-started.md | 2 +- docs/getting-started/buttons.md | 4 ++-- docs/getting-started/coin-flipper.md | 4 ++-- docs/getting-started/screen.md | 10 ++-------- docs/reference/basic/forever.md | 14 +++++++------- 5 files changed, 14 insertions(+), 20 deletions(-) diff --git a/docs/getting-started.md b/docs/getting-started.md index 475366f8..09313936 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -33,7 +33,7 @@ basic.forever(() => { When this program runs, you will see a smiley face, then a blank screen, then a smiley again -- it never stops! (That's because of the -``forever`` block.) +`[basic.forever(() => {})]` block.) Click **Download** to move your program to the @boardname@! Make sure to follow the instructions. diff --git a/docs/getting-started/buttons.md b/docs/getting-started/buttons.md index 120352f7..c91d84af 100644 --- a/docs/getting-started/buttons.md +++ b/docs/getting-started/buttons.md @@ -17,7 +17,7 @@ input.onButtonPressed(Button.A, () => { #### ~hint -The ``showString`` block can show letters, numbers, and punctuation +The `[basic.showString("HI")]` block can show letters, numbers, and punctuation on the @boardname@ screen. #### ~ @@ -33,7 +33,7 @@ input.onButtonPressed(Button.B, () => { #### ~hint You can find the letter `B` by clicking the letter `A` on the -``onButtonPressed`` block. +`[input.onButtonPressed(Button.A, () => {})]` block. #### ~ diff --git a/docs/getting-started/coin-flipper.md b/docs/getting-started/coin-flipper.md index fd5d13ae..d9ab3305 100644 --- a/docs/getting-started/coin-flipper.md +++ b/docs/getting-started/coin-flipper.md @@ -23,8 +23,8 @@ input.onButtonPressed(Button.B, () => { ``` ### ~hint -The ``pick random true or false`` block randomly tells the ``if`` -block `true` or `false`. If the ``pick`` block picked `true`, the +The `[Math.randomBoolean()]` block randomly tells the ``if`` +block `true` or `false`. If value picked is `true`, the ``if`` block shows the letter `H`. Otherwise, it shows the letter `T`. That's it! diff --git a/docs/getting-started/screen.md b/docs/getting-started/screen.md index fd700b41..947b1af6 100644 --- a/docs/getting-started/screen.md +++ b/docs/getting-started/screen.md @@ -9,7 +9,7 @@ There are 25 bright LEDs on the @boardname@ screen. Let's use them to create som ### Happy unhappy face Draw an unhappy face instead of the blank screen. Click on the dots -in the second ``show leds`` block until it matches the blocks below. +in the second `[basic.showLeds("")]` block until it matches the blocks below. Now you have an **animation** (cartoon) that shows a happy face, then an unhappy one, then a happy one again, forever (or until you turn off your @boardname@)! @@ -36,7 +36,7 @@ Click **Download** to move your program to the @boardname@! ### Your turn! -Pile up more ``show leds`` blocks to create an animation! Create an +Pile up more `[basic.showLeds("")]` blocks to create an animation! Create an animation with at least 5 pictures. What does this animation show? ```blocks @@ -87,12 +87,6 @@ basic.forever(() => { ``` Click **Download** to move your program to the @boardname@! -#### ~hint - -You can find the ``show leds`` block in the **Basic** part of the editor. - -#### ~ - ### ~button /getting-started/buttons NEXT: BUTTONS ### ~ \ No newline at end of file diff --git a/docs/reference/basic/forever.md b/docs/reference/basic/forever.md index d06ec3c8..8455c257 100644 --- a/docs/reference/basic/forever.md +++ b/docs/reference/basic/forever.md @@ -18,15 +18,15 @@ and updates the screen with the direction. basic.forever(() => { let heading = input.compassHeading() if (heading < 45) { - basic.showString("N", 100) + basic.showString("N") } else if (heading < 135) { - basic.showString("E", 100) + basic.showString("E") } else if (heading < 225) { - basic.showString("S", 100) + basic.showString("S") } else { - basic.showString("W", 100) + basic.showString("W") } }) ``` @@ -40,7 +40,7 @@ You can use a program like this to count things with your @boardname@. ```blocks let num = 0 basic.forever(() => { - basic.showNumber(num, 150) + basic.showNumber(num) }) input.onButtonPressed(Button.A, () => { num = num + 1 @@ -56,10 +56,10 @@ Try this on your @boardname@: ```blocks basic.forever(() => { - basic.showNumber(6789, 150) + basic.showNumber(6789) }) input.onButtonPressed(Button.A, () => { - basic.showNumber(2, 150) + basic.showNumber(2) }) ```