 
 (def width 100)
 (def height 100)
+(def expand 4)
+(def neighbour-width 1)
 (def hue 100)
 (def sat 200)
 (def max-b 200)

          (rand-int 2))))))

(defn neighbouring [x y]
  (for [dx (range -1 2)
        dy (range -1 2)
        :when (not (and (= dx 0) (= dy 0)))]
    [(+ x dx) (+ y dy)]))

(defn get-neighbours [field x y]
  (map (fn [[x y]] (get-in field [y x] 0))
       (neighbouring x y)))

(defn check-spawn [v neighbours]


(defn draw-dot-at [field x y]
  (let [color (to-color (get-in field [y x]))]
    (apply q/fill color) ; with-stroke doesn't work somehow
    (q/rect (* expand x) (* expand y) expand expand)
    ))

(defn draw-state [s]
