Liking cljdoc? Tell your friends :D

clunk.core


default-draw!clj

(default-draw! {:keys [vg default-font window current-scene] :as state})
source

default-on-closeclj

(default-on-close & _)
source

default-optsclj

source

drain-events!clj

(drain-events!)
source

draw-background!clj

(draw-background! [r g b a])
source

draw-game!clj

(draw-game! {:keys [scenes current-scene] :as state})

Draw the game using the current scenes :draw-fn.

Draw the game using the current scenes `:draw-fn`.
sourceraw docstring

draw-preload-progress!clj

(draw-preload-progress! window current total)
source

empty-queueclj

source

enqueue-event!clj

(enqueue-event! e)
source

eventsclj

source

gameclj

(game override-opts)

Create a game config map

Create a game config map
sourceraw docstring

initclj

(init {[initial-window-width initial-window-height] :size :as game-config})
source

init-audioclj

(init-audio state)
source

init-contextclj

(init-context {:keys [window] :as state})
source

init-error-callbackclj

(init-error-callback state)

Set up an error callback, the default implementation will print the error message in System.err

Set up an error callback, the default implementation will print
the error message in System.err
sourceraw docstring

init-event-handlersclj

(init-event-handlers {:keys [window] :as state})
source

init-glfwclj

(init-glfw {[initial-window-width initial-window-height] :size :as state})

Initialise GLFW, most GLFW functions will not work before doing this

Initialise GLFW, most GLFW functions will not work before doing this
sourceraw docstring

init-nanovgclj

(init-nanovg state)

Initialise text rendering stuff

Initialise text rendering stuff
sourceraw docstring

init-orthoclj

(init-ortho {[initial-window-width initial-window-height] :size :as state})
source

init-transparencyclj

(init-transparency state)

enable transprency for drawing images

enable transprency for drawing images
sourceraw docstring

main-loopclj

(main-loop {:keys [window] :as state})
source

position-windowclj

(position-window {:keys [window] :as state})
source

preload-assets!clj

(preload-assets! window {audio-assets :audio image-assets :image})

Pre-load assets and display a loading bar

Pre-load assets and display a loading bar
sourceraw docstring

process-eventclj

(process-event {:keys [current-scene scenes] :as state}
               {:keys [event-type] :as e})
source

quit!clj

(quit! {:keys [window]})
source

reset-ortho-projectionclj

(reset-ortho-projection w h)
source

start!clj

(start! {:keys [init-scenes-fn on-start-fn on-close-fn] :as game})
source

update-gameclj

(update-game {:keys [scenes current-scene last-frame-time] :as state})

Update the game state based on the current scenes :update-fn.

Applies all unprocessed events to the game.

Update the game state based on the current scenes `:update-fn`.

Applies all unprocessed events to the game.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close