Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: Level/Level.cpp
- Revision:
- 10:58cf89dd878c
- Parent:
- 9:96969b1c6bde
- Child:
- 11:db27d3838514
diff -r 96969b1c6bde -r 58cf89dd878c Level/Level.cpp
--- a/Level/Level.cpp Wed Apr 24 10:18:45 2019 +0000
+++ b/Level/Level.cpp Mon May 06 10:11:42 2019 +0000
@@ -10,13 +10,8 @@
{
_number_of_blocks = number_of_blocks;
-
-
for (int i = 0; i<_number_of_blocks; i++) {
- _blocks[i].first.x = blocks[i].first.x;
- _blocks[i].first.y = blocks[i].first.y;
- _blocks[i].second.x = blocks[i].second.x;
- _blocks[i].second.y = blocks[i].second.y;
+ _blocks[i] = blocks[i];
}
_goal = goal;
@@ -61,7 +56,7 @@
if (_blocks[current_block.index].first.x >
- (current_block.initial_pos + current_block.distance)) {
+ current_block.initial_pos + current_block.distance) {
current_block.extending = false;
}
if (_blocks[current_block.index].first.x < current_block.initial_pos) {