@ -46,7 +46,7 @@ let obstacles: game.LedSprite[] = []
|
||||
Now generate vertical obstacles consisting of 4 sprites and 1 random hole.
|
||||
Create new variable called `emptyObstacleY`. Using ``||math:pick random||``, generate a random number from `0` to `4` and store it inside `emptyObstacleY`.
|
||||
|
||||
Using ``||loops:for||`` loop, iterate from `0` to `4`. For every coordinate not equal to `emptyObstacleY` create and add obstacle sprites to the endo fo the `obstacles` array.
|
||||
Using ``||loops:for||`` loop, iterate from `0` to `4`. For every coordinate not equal to `emptyObstacleY` create and add obstacle sprites to the end of the `obstacles` array.
|
||||
|
||||
```blocks
|
||||
let emptyObstacleY = 0
|
||||
@ -268,4 +268,4 @@ Here are some additional features you can add to the game:
|
||||
|
||||
## About the authors
|
||||
|
||||
This project was created by [Karolis Vycius](https://www.linkedin.com/in/vycius/). The original Flappy Bird game was developed by [Dong Nguyen](https://en.wikipedia.org/wiki/Flappy_Bird).
|
||||
This project was created by [Karolis Vycius](https://www.linkedin.com/in/vycius/). The original Flappy Bird game was developed by [Dong Nguyen](https://en.wikipedia.org/wiki/Flappy_Bird).
|
||||
|
Reference in New Issue
Block a user