aboutsummaryrefslogtreecommitdiff
path: root/backend/Dungeon.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'backend/Dungeon.cpp')
-rw-r--r--backend/Dungeon.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/backend/Dungeon.cpp b/backend/Dungeon.cpp
index ce9ba9f..3fe9a58 100644
--- a/backend/Dungeon.cpp
+++ b/backend/Dungeon.cpp
@@ -44,9 +44,9 @@ void Dungeon::update_movement() {
lprtf(":: De vijanden bewegen ::\n");
Direction direction = random_direction(*location);
location->remove_enemy(enemy);
- Location * new_location = location->get_exit(direction);
- new_location->add_enemy(enemy);
- if (&this->player.get_location() == new_location)
+ Location & new_location = location->get_exit(direction);
+ new_location.add_enemy(enemy);
+ if (&this->player.get_location() == &new_location)
lprtf("%s komt de huidige locatie binnen\n", enemy->get_name().c_str());
moved = true;
}