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: Enemy/Enemy.cpp
- Revision:
- 15:3dbb3f4d7ae6
- Parent:
- 14:2d7e41f46879
--- a/Enemy/Enemy.cpp Tue May 26 14:33:14 2020 +0000
+++ b/Enemy/Enemy.cpp Tue May 26 19:11:26 2020 +0000
@@ -65,7 +65,7 @@
}
//resets enemies each time it gets shot
void Enemy::reset(int seed, N5110 &lcd){
- DeathAnimation(lcd);
+ death_animation(lcd);
srand(seed);
_four = (rand()%4)+1;
//pce.printf("%d", _four);
@@ -87,7 +87,7 @@
}
}
//Eenmy Death Animation
-void Enemy::DeathAnimation(N5110 &lcd){
+void Enemy::death_animation(N5110 &lcd){
int sprite_data[] = {
1,0,1,0,1,
0,1,1,1,0,
@@ -95,12 +95,8 @@
0,1,1,1,0,
1,0,1,0,1
};
-
-
Bitmap death(sprite_data, 5, 5);
-
//Render Bitmap at x & y
death.render(lcd, _x - 1, _y - 1);
lcd.refresh();
- wait(0.01);
}