aboutsummaryrefslogtreecommitdiff
path: root/src/Main.elm
blob: 207a393dad28dd9f940e8368727cfc30bbe10c1e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
module Main where

import Signal
import Random
import Graphics.Element (Element)
import Html (Html)

import Model.Game (Game, initialGame)
import Model.Vec2 (originVec)
import Model.Config (Config(White))

import Update.Update (update)

import Input (getInput)

import View.Page (pageView)

main : Signal Html
main = Signal.map pageView game

game : Signal Game
game =
  Signal.foldp
    update
    (initialGame (Random.initialSeed initialTime))
    getInput

port initialTime : Int