Created
August 11, 2017 09:35
-
-
Save jasonneylon/553499eb15348374af112c31bbe91227 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
randomPoints : Generator (List(Point)) | |
randomPoints = | |
Random.list 200 (Random.map (\(x, y) -> Point x y) (Random.pair (int 1 999) (int 1 399))) | |
-- here we create a command that the elm runtime will execute and then pass the results back via the Update function | |
initialModel : (Model, Cmd Msg) | |
initialModel = | |
(Model [] [] 6 0 False, (Random.generate DrawPoints randomPoints)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment