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: main.cpp
- Revision:
- 13:1dbef50789ed
- Parent:
- 12:f7dfd44569b6
- Child:
- 14:739115711bf8
diff -r f7dfd44569b6 -r 1dbef50789ed main.cpp --- a/main.cpp Thu Apr 23 09:10:11 2020 +0000 +++ b/main.cpp Wed Apr 29 12:48:40 2020 +0000 @@ -38,15 +38,16 @@ while(game_check == false) { lcd.clear(); + objects.draw_shots(lcd); + functions.ball_creater(lcd, objects, pad); + //functions.collision_checker(lcd,objects); objects.draw_base(lcd); objects.cannon_position(pad); objects.draw_cannon(lcd); - functions.ball_position_linear(lcd,objects,3); + game_check = functions.cannon_smash(lcd, objects); - objects.draw_shots(lcd); - functions.collision_checker(lcd,objects); lcd.refresh(); - wait(0.05); + wait(0.15); lcd.clear(); objects.cannon_position(pad); @@ -54,7 +55,7 @@ lcd.refresh(); wait(0.005); } - printf("bool is: true "); + printf("Score is: %d", functions.get_score()); } void initialise()