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: MazeEngine/MazeEngine.cpp
- Revision:
- 23:6733f8b9c321
- Parent:
- 22:745b4d352183
- Child:
- 25:28c57be06933
diff -r 745b4d352183 -r 6733f8b9c321 MazeEngine/MazeEngine.cpp --- a/MazeEngine/MazeEngine.cpp Tue May 08 12:55:17 2018 +0000 +++ b/MazeEngine/MazeEngine.cpp Tue May 08 13:13:20 2018 +0000 @@ -47,10 +47,16 @@ void MazeEngine::check_goal(Gamepad &pad) { ball_pos = _ball.get_pos(); + if(ball_pos.x > 83 & ball_pos.y == 27) { + if(pad.check_event(Gamepad::START_PRESSED) == true) { + init(); + } + } } void MazeEngine::print_win(N5110 &lcd) { lcd.clear(); lcd.printString(" Bravo! ",12,2); + lcd.printString(" Press Start ",0,4); } \ No newline at end of file