From 4d007f6802246c6411a2838e68e957c2b4d56d3d Mon Sep 17 00:00:00 2001 From: Joris Guyonvarch Date: Wed, 4 Mar 2015 23:27:59 +0100 Subject: Adapt the game to elm version 0.14.1 --- src/Main.elm | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'src/Main.elm') diff --git a/src/Main.elm b/src/Main.elm index 267bb8c..fcafbda 100644 --- a/src/Main.elm +++ b/src/Main.elm @@ -1,10 +1,22 @@ module Main where -import Game (initialGame) +import Signal +import Random +import Graphics.Element (Element) + +import Game (Game, initialGame) import Display (display) import Step (step) import Input (getInput) import Vec2 (originVec) main : Signal Element -main = lift display (foldp step (initialGame originVec 0) getInput) +main = Signal.map display game + +game : Signal Game +game = Signal.foldp step (initialGame initialSeed originVec 0) getInput + +port initialTime : Int + +initialSeed : Random.Seed +initialSeed = Random.initialSeed initialTime -- cgit v1.2.3