This commit is contained in:
Peli de Halleux 2016-06-01 21:19:16 -07:00
Родитель d54aa41fc9
Коммит 1e436f4e71
26 изменённых файлов: 23 добавлений и 89 удалений

Просмотреть файл

@ -1,6 +1,6 @@
# micro:bit - the device
The micro:bit device #docs
The micro:bit device
The micro:bit is a very capable device with many components:

Просмотреть файл

@ -1,6 +1,6 @@
# Error codes
The micro:bit error codes #docs
The micro:bit error codes
Your micro:bit may encounter a situation that prevents it from running your code. When this happens, a frowny face will appear on your micro:bit screen (see picture) followed by an error number.

Просмотреть файл

@ -1,6 +1,6 @@
# The micro:bit - a reactive system
The micro:bit is a reactive system. #docs
The micro:bit is a reactive system.
### Computing systems

Просмотреть файл

@ -1,6 +1,6 @@
# blocks - if statements
An introduction to conditions for the Block Editor. #docs
An introduction to conditions for the Block Editor.
## Introduction to conditions

Просмотреть файл

@ -1,6 +1,6 @@
# bop it challenges
a game similar to "Simon Says" with the BBC micro:bit. #docs
a game similar to "Simon Says" with the BBC micro:bit.
## Before we get started

Просмотреть файл

@ -1,6 +1,6 @@
# blocks - challenges
Extra stuff for the Block Editor - an introduction to GPIO #docs
Extra stuff for the Block Editor - an introduction to GPIO
## Before we get started

Просмотреть файл

@ -1,6 +1,6 @@
# game of chance blocks lesson
create an answering machine on the BBC micro:bit #docs
create an answering machine on the BBC micro:bit
## Topic

Просмотреть файл

@ -1,6 +1,6 @@
# blocks - rendering graphics
An introduction to graphics for the Block Editor. #docs
An introduction to graphics for the Block Editor.
## Before we get started

Просмотреть файл

@ -1,6 +1,6 @@
# blocks - loops
An introduction to Loops for the Block Editor. #docs
An introduction to Loops for the Block Editor.
We may want to handle the users input multiple times or remain waiting for their input for a long time. We use loops to make sure that our code runs multiple times. These can be found in the **Loops** drawer.

Просмотреть файл

@ -1,6 +1,6 @@
# offset image challenges
Coding challenges for the offset image tutorial. #docs
Coding challenges for the offset image tutorial.
## Before we get started

Просмотреть файл

@ -1,8 +1,6 @@
# prank wifi lesson
create a fake wifi app to trick your friends.
create a fake wifi app to trick your friends
Create a fake wifi app to trick your friends
* [activity](/lessons/prank-wifi/activity)
* [quiz](/lessons/prank-wifi/quiz)

Просмотреть файл

@ -1,6 +1,6 @@
# prank wifi challenges
create a fake wifi app to trick your friends. #docs
create a fake wifi app to trick your friends.
## Before we get started

Просмотреть файл

@ -1,8 +1,6 @@
# rock paper scissors lesson
a game against the BBC micro:bit.
A game against the BBC micro:bit.
## Topic

Просмотреть файл

@ -20,6 +20,7 @@ Learn how to create images that look like a rotating animation by using a while
## Documentation
```cards
while (true) {}
let x = 0
input.onButtonPressed(Button.A, () => {})
basic.showLeds(`
@ -30,7 +31,6 @@ basic.showLeds(`
. . . . .
`)
basic.pause(100)
while (true) {}
```
## Objectives

Просмотреть файл

@ -1,8 +1,6 @@
# screen wipe blocks lesson
clear the screen by pressing button "A".
Clear the screen by pressing button "A".
## Topic

Просмотреть файл

@ -1,8 +1,6 @@
# smiley blocks lesson
design a blinking image lesson #docs
Design a blinking image lesson
## Topic

Просмотреть файл

@ -1,6 +1,6 @@
# speed button challenges
Coding challenges for the speed button tutorial. #docs
Coding challenges for the speed button tutorial.
## Before we get started

Просмотреть файл

@ -1,6 +1,6 @@
# Blocks - Variables
An introduction to variables for the Block Editor. #docs
An introduction to variables for the Block Editor.
## What is a variable?

Просмотреть файл

@ -1,18 +1,10 @@
# Game Library
The game library #docs
The game library supports simple single-player time-based games. The player has a **sprite**, number of **lives** and a **score**. The game has a sprite, number of **levels** and a **countdown clock**. The general goal of a game will be to move the sprite and achieve a top score before time runs out or the number of lives goes to zero.
## Block Editor
![](/static/mb/game-library/pic0.png)
## KindScript
The code below shows a simple game where the user gets to press the button ``A`` as much times as possible in 10 seconds.
```
```blocks
input.onButtonPressed(Button.A, () => {
game.addScore(1)
})

Просмотреть файл

@ -1,20 +1,10 @@
# Score
The game library #docs
The game library supports simple single-player games. The player has a **score**.
## Block Editor
The code below shows a simple game where the user gets to press the button ``A`` and adds 1 point to score that will be displayed on the BBC micro:bit screen
![](/static/mb/game-library/add-point-to-score-0.png)
## KindScript
The code below shows a simple game where the user gets to press the button ``A`` as much times as possible in 10 seconds.
```
```blocks
input.onButtonPressed(Button.A, () => {
game.addScore(1)
})

Просмотреть файл

@ -1,7 +1,5 @@
# Start Countdown
The game library #docs
The game library supports simple single-player time-based games. The general goal of a game will be to achieve a top score before time runs out of time.
## Block Editor

Просмотреть файл

@ -1,7 +1,5 @@
# Events Library
The events library #docs
The functions in the events namespace allow the BBC micro:bit to communicate with a separate (remote) device, such as a smartphone, over Bluetooth (Smart). The set of supported events will depend on the remote device and the BBC micro:bit apps available for the remote device. The events accessible from Touch Develop are listed below.
### Remote control

Просмотреть файл

@ -1,7 +1,5 @@
# Game Library
The game library #docs
The game library supports simple single-player time-based games. The player has a number of **lives** and a **score**. The game has a number of **levels** and a **countdown clock**. The general goal of a game will be to achieve a top score before time runs out or the number of lives goes to zero.
## Touch Develop

Просмотреть файл

@ -1,20 +1,10 @@
# Add Points to Score
The game library #docs
The game library supports simple single-player time-based games. The player will ** add points to score**.
## Block Editor
The code below shows a simple game where the user gets to press the button ``A`` as much times as possible and the score will display on the screen.
![](/static/mb/game-library/add-point-to-score-0.png)
## Touch Develop
The code below shows a simple game where the user gets to press the button ``A`` as much times as possible in 10 seconds.
```
```blocks
input.onButtonPressed(Button.A, () => {
game.addScore(1)
})

Просмотреть файл

@ -1,20 +1,8 @@
# Change Score By
The game library #docs
The game library supports simple single-player time-based games. The player will ** add points to score**.
## Block Editor
The code below shows a simple game where the user gets to press the button ``A`` as much times as possible and the score will display on the screen.
![](/static/mb/change-score-by-0.png)
## Touch Develop
The code below shows a simple game where the user gets to press the button ``A`` as much times as possible in 10 seconds.
```
```blocks
input.onButtonPressed(Button.A, () => {
game.addScore(1)
})

Просмотреть файл

@ -1,20 +1,8 @@
# Game Over
The game library #docs
The game library supports simple single-player time-based games. The game can end the game by calling the `game over` function
## Block Editor
You can end the game by calling the `game over ` function. In this example, if BBC micro:bit's answer to the question is GAME OVER, GAME OVER will be displayed to end the game.
![](/static/mb/game-library/game-over-0.png)
## Touch Develop
You can end the game by calling the `game -> game over` function:
```
```blocks
game.gameOver()
```