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.
Dependencies: mbed
Diff: Frog/Car.cpp
- Revision:
- 9:d210eede4a1b
- Parent:
- 8:52794de935b2
diff -r 52794de935b2 -r d210eede4a1b Frog/Car.cpp
--- a/Frog/Car.cpp Tue May 12 05:14:17 2020 +0000
+++ b/Frog/Car.cpp Tue May 12 22:04:05 2020 +0000
@@ -12,10 +12,7 @@
screenHeight = 48;
screenWidth = 84;
- size = 3;
-
- // width of all vehicles
- vehicle.width = grid * size;
+ size = 3;
}
void Car::setRow(int row){
@@ -34,6 +31,9 @@
// intialize the vehicle size and position in lcd
// x position of all vehicles
vehicle.x = seperation;
+
+ // width of all vehicles
+ vehicle.width = grid * size;
}
void Car::speedSlow(){