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/Bullets/Bullets.cpp
- Revision:
- 29:6b8411bb040a
- Parent:
- 28:98848e6a77a2
diff -r 98848e6a77a2 -r 6b8411bb040a Entity/Bullets/Bullets.cpp
--- a/Entity/Bullets/Bullets.cpp Thu May 02 21:30:49 2019 +0000
+++ b/Entity/Bullets/Bullets.cpp Sat May 04 15:39:20 2019 +0000
@@ -17,7 +17,7 @@
direction = dir;
}
-void Bullets::move(float speed, float unused, int * unused2)
+void Bullets::move(float speed, float unused, int * unused2, bool * unused3)
{
if (direction == 0) {
position.y -= speed;
@@ -40,9 +40,9 @@
return (int *) bullets_sprite;
}
-bool Bullets::out_of_bounds_check(int * map)
+bool Bullets::out_of_bounds_check(int * map, bool * doorways)
{
- if (matrix_collision_test(position.x, position.y, map)) {
+ if (entity_to_map_collision_test(position.x, position.y, map, doorways)) {
return true;
}
if ((0 > position.x) || (position.x > 84) || (0 > position.y) || (position.y > 48)) {