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 MotionSensor
Diff: Entity/Player/Bullets/Bullets.cpp
- Revision:
- 35:06cd6be999ad
- Parent:
- 34:1d5b4da3935e
- Child:
- 37:a404860171a9
diff -r 1d5b4da3935e -r 06cd6be999ad Entity/Player/Bullets/Bullets.cpp
--- a/Entity/Player/Bullets/Bullets.cpp Mon May 06 13:58:39 2019 +0000
+++ b/Entity/Player/Bullets/Bullets.cpp Mon May 06 20:05:14 2019 +0000
@@ -13,7 +13,7 @@
sprite_size.width = 3;
sprite_size.height = 3;
sprite_size.offset_x = 0;
- sprite_size.offset_y = 1;
+ sprite_size.offset_y = -1;
direction = dir;
}
@@ -32,8 +32,8 @@
void Bullets::draw(N5110 &lcd)
{
- lcd.drawSpriteTransparent(position.x-sprite_size.offset_x,
- position.y-sprite_size.offset_y,
+ lcd.drawSpriteTransparent(position.x+sprite_size.offset_x,
+ position.y+sprite_size.offset_y,
sprite_size.height,
sprite_size.width,
get_frame());