| summaryrefslogtreecommitdiff | 
diff options
| author | Nathanael Sensfelder <SpamShield0@MultiAgentSystems.org> | 2019-02-26 21:34:35 +0100 | 
|---|---|---|
| committer | Nathanael Sensfelder <SpamShield0@MultiAgentSystems.org> | 2019-02-26 21:34:35 +0100 | 
| commit | b055ce4b1e9f9b056f38739506157432a9a82875 (patch) | |
| tree | 4f6bfc923be0ed7fa0312a76b7154deb7ca8adf9 /src/map-editor | |
| parent | 3d945fe5726bf8da486973328a5e8f58f15d3663 (diff) | |
Splits Tile & TileInstance (Battle).
Diffstat (limited to 'src/map-editor')
| -rw-r--r-- | src/map-editor/src/Comm/SetMap.elm | 7 | ||||
| -rw-r--r-- | src/map-editor/src/Struct/TileInstance.elm | 16 | 
2 files changed, 1 insertions, 22 deletions
| diff --git a/src/map-editor/src/Comm/SetMap.elm b/src/map-editor/src/Comm/SetMap.elm index 06fa34c..10d527a 100644 --- a/src/map-editor/src/Comm/SetMap.elm +++ b/src/map-editor/src/Comm/SetMap.elm @@ -1,18 +1,11 @@  module Comm.SetMap exposing (decode)  -- Elm ------------------------------------------------------------------------- -import Dict -  import Json.Decode  -- Map ------------------------------------------------------------------------- -import Constants.Movement -  import Struct.Map -import Struct.MapMarker  import Struct.ServerReply -import Struct.Tile -import Struct.TileInstance  --------------------------------------------------------------------------------  -- TYPES ----------------------------------------------------------------------- diff --git a/src/map-editor/src/Struct/TileInstance.elm b/src/map-editor/src/Struct/TileInstance.elm index 4d03630..862598b 100644 --- a/src/map-editor/src/Struct/TileInstance.elm +++ b/src/map-editor/src/Struct/TileInstance.elm @@ -62,21 +62,7 @@ type alias Border =  --------------------------------------------------------------------------------  noise_function : Int -> Int -> Int -> Int  noise_function a b c = -   let -      af = (toFloat a) -      bf = (toFloat b) -      cf = (toFloat c) -      (df, ef) = (toPolar (af, bf)) -      (ff, gf) = (toPolar (bf, af)) -      (hf, jf) = (toPolar (bf, cf)) -      (kf, lf) = (toPolar (cf, bf)) -      (mf, nf) = (toPolar (af, cf)) -      (qf, rf) = (toPolar (cf, af)) -      (resA, resB) = (fromPolar ((df + qf), (ef + nf))) -      (resC, resD) = (fromPolar ((hf + mf), (jf + gf))) -      (resE, resF) = (toPolar ((resA - resC), (resB - resD))) -   in -      (round (resE - resF)) +   (round (radians (toFloat ((a + 1) * 2 + (b + 1) * 3 + c))))  --------------------------------------------------------------------------------  -- EXPORTED -------------------------------------------------------------------- | 


