From 7ec2e0fbd6c53faa52ca0e6f2e8e172d3556c81d Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Sat, 17 Feb 2018 22:08:18 +0100 Subject: Fix all warnings (errors with -Werror) --- src/main/cpp/Map.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/main/cpp/Map.cpp') 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& Map::tiles() const bool Map::moveActor(Tile &from, Tile &to) { + if (to.actor() != nullptr) + return false; + to.actor(from.actor()); from.clearActor(); + + return true; } -- cgit v1.2.1