summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathanael Sensfelder <SpamShield0@MultiAgentSystems.org>2018-08-05 21:01:17 +0200
committerNathanael Sensfelder <SpamShield0@MultiAgentSystems.org>2018-08-05 21:01:17 +0200
commitc255684ad2f8257e01855edf13df8d2aece259dc (patch)
treefe70b1b722165016a2f6bd3dbe26fa03d17a8cdd /src/map-editor
parent74d5f55bbfa96d9a60aa9932746cbcbbe68bad8f (diff)
Fixes the borders being displayed in reverse order.
Diffstat (limited to 'src/map-editor')
-rw-r--r--src/map-editor/src/Comm/SendMapUpdate.elm8
-rw-r--r--src/map-editor/src/Comm/SetMap.elm2
2 files changed, 4 insertions, 6 deletions
diff --git a/src/map-editor/src/Comm/SendMapUpdate.elm b/src/map-editor/src/Comm/SendMapUpdate.elm
index 27a5747..d47cee2 100644
--- a/src/map-editor/src/Comm/SendMapUpdate.elm
+++ b/src/map-editor/src/Comm/SendMapUpdate.elm
@@ -38,11 +38,9 @@ encode_tile_instance tile_inst =
(Json.Encode.int (Struct.Tile.get_variant_ix tile_inst))
]
++
- (List.concat
- (List.map
- (encode_tile_border_values)
- (Struct.Tile.get_borders tile_inst)
- )
+ (List.concatMap
+ (encode_tile_border_values)
+ (Struct.Tile.get_borders tile_inst)
)
)
)
diff --git a/src/map-editor/src/Comm/SetMap.elm b/src/map-editor/src/Comm/SetMap.elm
index 7a83320..36ddade 100644
--- a/src/map-editor/src/Comm/SetMap.elm
+++ b/src/map-editor/src/Comm/SetMap.elm
@@ -30,7 +30,7 @@ deserialize_tile_borders : (
)
deserialize_tile_borders rem_ints current_borders =
case rem_ints of
- [] -> current_borders
+ [] -> (List.reverse current_borders)
(a :: (b :: c)) ->
(deserialize_tile_borders
c