 
            :on-timer
            (fn [screen entities]
-             (println "timer")
              (when (= :ambiant-sound (:id screen))
-               (when (= 0 (mod (rand-int 2) 2))
+               (when (even? (rand-int 2))
                  (cell/ambiant-sound (cell/find-cell entities)))
                entities)))
 
 (defscreen main-bg-screen
            :on-show
            (fn [screen _]
-             (let [camera (orthographic)]
-               (update! screen
-                        :camera camera
-                        :renderer (stage-fit-vp camera))
-               (u/memo-texture "main-screen-background-1.png")))
-
-           :on-render
-           (fn [screen entities]
-             #_(println entities)
-             (clear! 0 1 0 1)
+             (init-graphic-settings screen)
+             (u/memo-texture "main-screen-background-1.png"))
+
+           :on-render
+           (fn [screen entities]
+             #!(clear! 0 1 0 1)
              (render! screen entities))
 
            :on-resize

           :on-show
           (fn [screen _]
             (let [background (intro-screen-background)
                   music (u/memo-sound "intro-screen-music.mp3")
                   camera (orthographic)]
               (update! screen
                        :renderer (stage-fit-vp camera)
                        :camera camera
                        :bg-width (texture! background :get-region-width)
                        :bg-height (texture! background :get-region-height)
                        :music music)

           :on-show
           (fn [screen _]

             (let [background (u/memo-texture "main-screen-background-1.png")
                   screen (-> (init-graphic-settings screen)
                              (update!
                                :world (box-2d 0 0)
                                :music (u/memo-sound "sound/fond.mp3")
                                :bg-width (u/pixels->world (texture! background :get-region-width))
                                :bg-height (u/pixels->world (texture! background :get-region-height))
                                :last-spawn 0))]

               (add-timer! screen :ambiant-sound 3 3)
               (sound! (:music screen) :loop)

               [ background
                (create-wall-entity screen)
                (cell/create-plante-zone! screen)
                (create-player-entity screen)]))

