Start 0.2.5-SNAPSHOT
This commit is contained in:
@@ -101,6 +101,8 @@
|
||||
"Input" {"input!" :methods}
|
||||
"Input.Keys" {"key-code" :static-fields
|
||||
"key-pressed?" :static-fields}
|
||||
"Input.Buttons" {"button-code" :static-fields
|
||||
"button-pressed?" :static-fields}
|
||||
"Interpolation" {"interpolation" :static-classes}
|
||||
"Intersector" {"intersector!" :static-methods}
|
||||
"IntAttribute" {"attribute :int" :constructors
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
(defproject play-clj "0.2.4"
|
||||
(defproject play-clj "0.2.5-SNAPSHOT"
|
||||
:description "A LibGDX wrapper for easy cross-platform game development"
|
||||
:url "https://github.com/oakes/play-clj"
|
||||
:license {:name "Public Domain"
|
||||
|
||||
@@ -116,6 +116,20 @@
|
||||
[k]
|
||||
`(key-pressed? ~k))
|
||||
|
||||
(defmacro button-code
|
||||
"Returns a static field from [Input.Buttons](http://libgdx.badlogicgames.com/nightlies/docs/api/com/badlogic/gdx/Input.Buttons.html).
|
||||
|
||||
(button-code :left)"
|
||||
[k]
|
||||
`~(u/gdx-field "Input$Buttons" (u/key->upper k)))
|
||||
|
||||
(defmacro button-pressed?
|
||||
"Returns a boolean indicating if the button cooresponding to `k` is being pressed.
|
||||
|
||||
(button-pressed? :left)"
|
||||
[k]
|
||||
`(input! :is-button-pressed (button-code ~k)))
|
||||
|
||||
(defn ^:private add-input!
|
||||
[^InputProcessor p]
|
||||
(let [^InputMultiplexer multi (input! :get-input-processor)]
|
||||
|
||||
Reference in New Issue
Block a user