summaryrefslogtreecommitdiff |
diff options
author | Nathanael Sensfelder <SpamShield0@MultiAgentSystems.org> | 2017-09-21 16:32:09 +0200 |
---|---|---|
committer | Nathanael Sensfelder <SpamShield0@MultiAgentSystems.org> | 2017-09-21 16:32:09 +0200 |
commit | 0d5fba42a1597e5a43266c071776e7acf58071e2 (patch) | |
tree | 374ab9f5128486f4cbad57fca35cc5d61a8f2f7b /client/elm/battlemap/src/View.elm | |
parent | 7b9ac4352353203fd1422a93fc7ef3a0daf8a768 (diff) |
Adds movement points, indicator for current char.
Diffstat (limited to 'client/elm/battlemap/src/View.elm')
-rw-r--r-- | client/elm/battlemap/src/View.elm | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/client/elm/battlemap/src/View.elm b/client/elm/battlemap/src/View.elm index d0cb8c8..50fa563 100644 --- a/client/elm/battlemap/src/View.elm +++ b/client/elm/battlemap/src/View.elm @@ -9,6 +9,7 @@ import Model exposing (Model) import Battlemap.Html as Batmap exposing (view) import Battlemap.Direction exposing (Direction(..)) +import Dict as Dt exposing (get) -- VIEW view : Model -> (Html Msg) @@ -39,6 +40,30 @@ view model = (div [] [(Batmap.view model)] + ), + (div + [] + [ + (text + (case (model.selection, model.navigator) of + (Nothing, _) -> "" + (_, Nothing) -> "" + ((Just char_id), (Just nav)) -> + case (Dt.get char_id model.characters) of + Nothing -> "" + (Just char) -> + ( + "Controlling " + ++ char.name + ++ ": " + ++ (toString nav.remaining_points) + ++ "/" + ++ (toString char.movement_points) + ++ " movement points remaining." + ) + ) + ) + ] ) ] ) |