summaryrefslogtreecommitdiff |
diff options
Diffstat (limited to 'elm/battlemap/src/Battlemap/Navigator/Move.elm')
-rw-r--r-- | elm/battlemap/src/Battlemap/Navigator/Move.elm | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/elm/battlemap/src/Battlemap/Navigator/Move.elm b/elm/battlemap/src/Battlemap/Navigator/Move.elm index 924f715..9d7a17b 100644 --- a/elm/battlemap/src/Battlemap/Navigator/Move.elm +++ b/elm/battlemap/src/Battlemap/Navigator/Move.elm @@ -111,7 +111,11 @@ to : ( to battlemap nav dir char_list = let next_location = (Battlemap.Location.neighbor nav.current_location dir) - is_occupied = (List.any (\c -> (c.location == next_location)) char_list) + is_occupied = + (List.any + (\c -> ((Character.get_location c) == next_location)) + char_list + ) in if (not is_occupied) then |