diff options
Diffstat (limited to 'src/main/cpp/Map.cpp')
-rw-r--r-- | src/main/cpp/Map.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main/cpp/Map.cpp b/src/main/cpp/Map.cpp index 3cb1b9d..d192b3b 100644 --- a/src/main/cpp/Map.cpp +++ b/src/main/cpp/Map.cpp @@ -24,6 +24,11 @@ const std::vector<Tile>& Map::tiles() const bool Map::moveActor(Tile &from, Tile &to) { + if (to.actor() != nullptr) + return false; + to.actor(from.actor()); from.clearActor(); + + return true; } |