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
Fork of el17dg by
Diff: game/enemies.h
- Revision:
- 32:5403bb974294
- Parent:
- 31:becb8f6bf7b7
- Child:
- 33:c623c6d5ed16
--- a/game/enemies.h Tue Apr 23 18:18:57 2019 +0000
+++ b/game/enemies.h Fri Apr 26 13:09:03 2019 +0000
@@ -62,10 +62,10 @@
if (GameGlobals::game_score >= 200){
if (switch_enemy_y_dir == false){pos.y -= 1;}
else if(switch_enemy_y_dir == true){pos.y += 1;}
- if (pos.y > (game_area_height - enemy2_height)){
+ if (pos.y >= (game_area_height - enemy2_height)){
switch_enemy_y_dir = false;
}
- else if (pos.y < game_area_y){
+ else if (pos.y <= game_area_y){
switch_enemy_y_dir = true;
}
}
