diff --git a/docs/reference/basic/show-string.md b/docs/reference/basic/show-string.md index 510b6ee8..c8ef05a5 100644 --- a/docs/reference/basic/show-string.md +++ b/docs/reference/basic/show-string.md @@ -33,7 +33,7 @@ basic.showString(s) ### Lessons -[answering machine](/lessons/answering-machine), [rock paper scissors](/lessons/rock-paper-scissors), [love meter](/lessons/love-meter), [digital pet](/lessons/digital-pet) +[answering machine](/lessons/answering-machine), [rock paper scissors](/lessons/rock-paper-scissors), [love meter](/lessons/love-meter) ### See also diff --git a/docs/reference/devices/on-gamepad-button.md b/docs/reference/devices/on-gamepad-button.md index 8c28f3ad..daf5a4c5 100644 --- a/docs/reference/devices/on-gamepad-button.md +++ b/docs/reference/devices/on-gamepad-button.md @@ -19,5 +19,4 @@ devices.onGamepadButton(MesDpadButtonInfo.ADown, () => {}) ### See Also -[tell remote control to](/reference/devices/tell-remote-control-to), [raise alert to](/reference/devices/raise-alert-to), [on notified](/reference/devices/on-notified), [signal strength](/reference/devices/signal-strength), [on signal strength changed](/reference/devices/on-signal-strength-changed) - +[tell remote control to](/reference/devices/tell-remote-control-to), [raise alert to](/reference/devices/raise-alert-to), [signal strength](/reference/devices/signal-strength), [on signal strength changed](/reference/devices/on-signal-strength-changed) diff --git a/docs/reference/devices/tell-camera-to.md b/docs/reference/devices/tell-camera-to.md index c5d1f6ab..4ac69338 100644 --- a/docs/reference/devices/tell-camera-to.md +++ b/docs/reference/devices/tell-camera-to.md @@ -14,7 +14,7 @@ The set of supported events will depend on the remote device and the BBC micro:b ![](/static/mb/tell-camera-to-0.png) -### KindScript +### JavaScript ``` export function tellCameraTo(event: string) diff --git a/docs/reference/devices/tell-microphone-to.md b/docs/reference/devices/tell-microphone-to.md index 27251dc4..b4b82ddf 100644 --- a/docs/reference/devices/tell-microphone-to.md +++ b/docs/reference/devices/tell-microphone-to.md @@ -10,7 +10,7 @@ The functions in the antenna namespace allow the BBC micro:bit to communicate wi ![](/static/mb/tell-microphone-to-0.png) -### KindScript +### JavaScript ``` export function tellMicrophoneTo(event: string) diff --git a/docs/reference/devices/tell-remote-control-to.md b/docs/reference/devices/tell-remote-control-to.md index 97c81435..25549eeb 100644 --- a/docs/reference/devices/tell-remote-control-to.md +++ b/docs/reference/devices/tell-remote-control-to.md @@ -14,7 +14,7 @@ The set of supported events will depend on the remote device and the BBC micro:b ![](/static/mb/tell-remote-control-to-0.png) -### KindScript +### JavaScript ``` export function tellRemoteControlTo(event: string) diff --git a/docs/reference/game/change.md b/docs/reference/game/change.md index 6a82224b..c3ad38d0 100644 --- a/docs/reference/game/change.md +++ b/docs/reference/game/change.md @@ -1,16 +1,12 @@ # Change -The game library - -### Change - Sprite will change the x position by this number -## Block Editor +### Block Editor ![](/static/mb/change-0.png) -## KindScript +### JavaScript Sprite will change the x position by this number diff --git a/docs/reference/game/clear.md b/docs/reference/game/clear.md index 89717c56..d3d8d265 100644 --- a/docs/reference/game/clear.md +++ b/docs/reference/game/clear.md @@ -4,7 +4,7 @@ The clear function for images. Turn off all the pixels in an [Image](/reference/images/image). -### KindScript +### JavaScript ``` export function clear(img: micro_bit.Image) diff --git a/docs/reference/game/score.md b/docs/reference/game/score.md index d48e7f58..f00a4662 100644 --- a/docs/reference/game/score.md +++ b/docs/reference/game/score.md @@ -55,5 +55,5 @@ export function startCountdown(ms: number) ### Lessons -[bop it](/lessons/bop-it) | [game of chance](/lessons/game-of-chance) | [game counter](/lessons/game-counter) +[game of chance](/lessons/game-of-chance), [game counter](/lessons/game-counter) diff --git a/docs/reference/images/pixel.md b/docs/reference/images/pixel.md index 0ca138e8..629d96c9 100644 --- a/docs/reference/images/pixel.md +++ b/docs/reference/images/pixel.md @@ -4,7 +4,7 @@ The pixel function. Get the state of a pixel in an [Image](/reference/images/image). -### KindScript +### JavaScript ``` export function pixel(_this: micro_bit.Image, x: number, y: number) : boolean diff --git a/docs/reference/images/plot-frame.md b/docs/reference/images/plot-frame.md index 7c8da246..e7aa80bb 100644 --- a/docs/reference/images/plot-frame.md +++ b/docs/reference/images/plot-frame.md @@ -4,7 +4,7 @@ The plot frame function. Display an [Image](/reference/images/image) on the BBC micro:bit's [LED screen](/device/screen) -### KindScript +### JavaScript ``` export function plotFrame(_this: micro_bit.Image, index: number) diff --git a/docs/reference/images/plot-image.md b/docs/reference/images/plot-image.md index 434b8d5e..c53e77b3 100644 --- a/docs/reference/images/plot-image.md +++ b/docs/reference/images/plot-image.md @@ -4,7 +4,7 @@ The plot image function. Display an [Image](/reference/images/image) on the BBC micro:bit's [LED screen](/device/screen) -### KindScript +### JavaScript ``` export function plotImage(_this: micro_bit.Image, xOffset: number) diff --git a/docs/reference/images/scroll-image.md b/docs/reference/images/scroll-image.md index 4e106ca0..0ca0f46a 100644 --- a/docs/reference/images/scroll-image.md +++ b/docs/reference/images/scroll-image.md @@ -8,7 +8,7 @@ Scrolls the frames within an [Image](/reference/images/image) on the [LED screen ![](/static/mb/scroll-image-0.png) -### KindScript +### JavaScript ``` export function scrollImage(_this: micro_bit.Image, xOffsetPerStep: number, interval: number) diff --git a/docs/reference/images/set-pixel.md b/docs/reference/images/set-pixel.md index f87a413a..4fdd9f89 100644 --- a/docs/reference/images/set-pixel.md +++ b/docs/reference/images/set-pixel.md @@ -4,7 +4,7 @@ The set pixel function. #set pixel. Set the on/off state of pixel in an [Image](/reference/images/image). -### KindScript +### JavaScript ``` export function setPixel(_this: micro_bit.Image, x: number, y: number, value: boolean) diff --git a/docs/reference/images/show-frame.md b/docs/reference/images/show-frame.md index 5ab04967..a1f7806a 100644 --- a/docs/reference/images/show-frame.md +++ b/docs/reference/images/show-frame.md @@ -4,7 +4,7 @@ The show frame function. Display an [Image](/reference/images/image) on the BBC micro:bit's [LED screen](/device/screen) -### KindScript +### JavaScript ``` export function showFrame(img: micro_bit.Image, frame: number) diff --git a/docs/reference/images/show-image.md b/docs/reference/images/show-image.md index dc8f2b86..b2f458ca 100644 --- a/docs/reference/images/show-image.md +++ b/docs/reference/images/show-image.md @@ -4,12 +4,6 @@ The show image function. Show an [Image](/reference/images/image) on the [LED screen](/device/screen), followed by a 400ms pause. -### Block Editor - -![](/static/mb/show-image-0.png) - -### KindScript - ``` export function showImage(_this: micro_bit.Image, xOffset: number) ``` @@ -20,7 +14,7 @@ export function showImage(_this: micro_bit.Image, xOffset: number) ### Create image and show image -Use the [image editor](/reference/images/image) to create images using the [create image](/reference/image/create-image) function, and then use `show image` like this: +Use the [image editor](/reference/images/image) to create images using the [create image](/reference/images/create-image) function, and then use `show image` like this: ``` let img = images.createImage(` diff --git a/docs/reference/images/width.md b/docs/reference/images/width.md index 0a40b59f..2acf76d9 100644 --- a/docs/reference/images/width.md +++ b/docs/reference/images/width.md @@ -4,10 +4,8 @@ The width function. Get the width of an [Image](/reference/images/image) in columns. -### KindScript - -``` -export function width(_this: micro_bit.Image) : number +```sig +images.createImage().width(); ``` ### Parameters diff --git a/docs/reference/input/button-is-pressed.md b/docs/reference/input/button-is-pressed.md index 7c5622ad..6bb974cf 100644 --- a/docs/reference/input/button-is-pressed.md +++ b/docs/reference/input/button-is-pressed.md @@ -37,5 +37,5 @@ basic.forever(() => { ### See also -[on button pressed](/input/on-button-pressed), [if](/reference/logic/if), [forever](/basic/forever) +[on button pressed](/reference/input/on-button-pressed), [if](/reference/logic/if), [forever](/reference/basic/forever) diff --git a/docs/reference/input/on-pin-pressed.md b/docs/reference/input/on-pin-pressed.md index 3026d35d..a4ed27be 100644 --- a/docs/reference/input/on-pin-pressed.md +++ b/docs/reference/input/on-pin-pressed.md @@ -28,5 +28,5 @@ input.onPinPressed(TouchPin.P0, () => { ### See also -[BBC micro:bit pins](/device/pins), [pin is pressed](/input/pin-is-pressed), [analog read pin](/pins/analog-read-pin), [analog write pin](/pins/analog-write-pin), [digital read pin](/pins/digital-read-pin), [digital write pin](/pins/digital-write-pin) +[BBC micro:bit pins](/device/pins), [pin is pressed](/reference/input/pin-is-pressed), [analog read pin](/reference/pins/analog-read-pin), [analog write pin](/reference/pins/analog-write-pin), [digital read pin](/reference/pins/digital-read-pin), [digital write pin](/reference/pins/digital-write-pin) diff --git a/docs/reference/led/plot-leds.md b/docs/reference/led/plot-leds.md index c57f6061..e72410be 100644 --- a/docs/reference/led/plot-leds.md +++ b/docs/reference/led/plot-leds.md @@ -2,8 +2,6 @@ Display an [Image](/reference/images/image) on the BBC micro:bit's [LED screen](/device/screen). NOTE: `basic -> plot image` has been replaced by `basic -> show leds`. -### KindScript syntax - ```sig basic.plotLeds(` . . . . . diff --git a/docs/reference/loops/for.md b/docs/reference/loops/for.md index d4ac9890..cc89b948 100644 --- a/docs/reference/loops/for.md +++ b/docs/reference/loops/for.md @@ -24,5 +24,5 @@ for (let k = 0; k < 4; k++) { ### See also -[while](/reference/loops/while), [if](/blocks/if) +[while](/reference/loops/while), [if](/reference/logic/if) diff --git a/docs/reference/loops/while.md b/docs/reference/loops/while.md index b6d6fe4c..480ad647 100644 --- a/docs/reference/loops/while.md +++ b/docs/reference/loops/while.md @@ -39,5 +39,5 @@ The following example uses a while loop to make a diagonal line on the LED scree ### See also -[on button pressed](/reference/input/on-button-pressed), [for](/reference/loops/for), [if](/blocks/if), [forever](/reference/basic/forever) +[on button pressed](/reference/input/on-button-pressed), [for](/reference/loops/for), [if](/reference/logic/if), [forever](/reference/basic/forever) diff --git a/docs/reference/radio/on-data-received.md b/docs/reference/radio/on-data-received.md index 433ff5fc..61f2d6a2 100644 --- a/docs/reference/radio/on-data-received.md +++ b/docs/reference/radio/on-data-received.md @@ -31,5 +31,5 @@ radio.onDataReceived(() => { ### See also -[receive number](/reference/radio/receive-number), [send number](/radio/send-number), [set group](/reference/radio/set-group) +[receive number](/reference/radio/receive-number), [send number](/reference/radio/send-number), [set group](/reference/radio/set-group) diff --git a/docs/reference/types/boolean.md b/docs/reference/types/boolean.md index db8dcbea..aae7e092 100644 --- a/docs/reference/types/boolean.md +++ b/docs/reference/types/boolean.md @@ -32,7 +32,7 @@ The next six blocks represent comparison operators that yield a Boolean value. M 42 >= 0; ``` -Boolean values and operators are often used with an [if](/blocks/if) or [while](/reference/loops/while) statement to determine which code will execute next. For example: +Boolean values and operators are often used with an [if](/reference/logic/if) or [while](/reference/loops/while) statement to determine which code will execute next. For example: ### Functions that return a Boolean @@ -104,5 +104,5 @@ See the documentation on [Numbers](/reference/types/number) for more information ### See also -[if](/blocks/if), [while](/reference/loops/while), [number](/reference/types/number) +[if](/reference/logic/if), [while](/reference/loops/while), [number](/reference/types/number) diff --git a/docs/reference/types/number.md b/docs/reference/types/number.md index 75b9601a..4de7546a 100644 --- a/docs/reference/types/number.md +++ b/docs/reference/types/number.md @@ -20,7 +20,7 @@ The following arithmetic operators work on numbers and return a [Number](/refere * subtraction: `1 - 3 ` * multiplication: `3 * 2` * integer division: `7 / 3` -* modulo is available through the [math library](/blocks/math) +* modulo is available through the [math library](/reference/math) ### Relational operators @@ -47,7 +47,7 @@ Some functions return a number, which you can store in a variable. For example t ### Math functions -The [math library](/blocks/math) includes math related functions. In the [Block Editor](/blocks/editor), click `math` on the Code Keyboard to see the math functions. For example, the `absolute` function returns the returns the absolute value of input parameter `x`: +The [math library](/reference/math) includes math related functions. In the [Block Editor](/blocks/editor), click `math` on the Code Keyboard to see the math functions. For example, the `absolute` function returns the returns the absolute value of input parameter `x`: ![](/static/mb/blocks/number-3.png) @@ -57,5 +57,5 @@ The [math library](/blocks/math) includes math related functions. In the [Block ### See also -[math library](/blocks/math), [var](/reference/variables/var), [Boolean](/reference/types/boolean), [show number](/reference/basic/show-number) +[math library](/reference/math), [var](/reference/variables/var), [Boolean](/reference/types/boolean), [show number](/reference/basic/show-number) diff --git a/docs/reference/variables/assign.md b/docs/reference/variables/assign.md index 5acc2fd0..de27860b 100644 --- a/docs/reference/variables/assign.md +++ b/docs/reference/variables/assign.md @@ -28,7 +28,7 @@ let num1 = 42 ```` ### Notes -* You can use the assignment operator with variables of each of the supported [types](/blocks/types). +* You can use the assignment operator with variables of each of the supported [types](/reference/types). ### Lessons @@ -36,5 +36,5 @@ let num1 = 42 ### See also -[variable](/reference/variables/var), [types](/blocks/types) +[variable](/reference/variables/var), [types](/reference/types) diff --git a/docs/reference/variables/change-var.md b/docs/reference/variables/change-var.md index d0c596a2..1f454c42 100644 --- a/docs/reference/variables/change-var.md +++ b/docs/reference/variables/change-var.md @@ -32,9 +32,9 @@ basic.showNumber(x); ### Notes -* You can use the assignment operator with variables of each of the supported [types](/blocks/types). +* You can use the assignment operator with variables of each of the supported [types](/reference/types). ### See also -[variable](/reference/variables/var), [types](/blocks/types) +[variable](/reference/variables/var), [types](/reference/types)