perf improvements, mobile working on i4s

This commit is contained in:
Bryce Covert
2017-05-24 06:15:28 -07:00
parent be916eb5f3
commit 2f6e0a4081
10 changed files with 262 additions and 186 deletions

View File

@@ -3,6 +3,7 @@
[play-clj.ui :refer :all]
[play-clj.utils :refer :all]
[play-clj.g2d :refer :all]
[clojure.tools.logging :as log]
[clojure.set :as set]
[advent.pathfind]
[advent.tween :as tween]
@@ -322,6 +323,7 @@
(and utils/mobile? action-cursor (not item-cursor) (not= :main action-cursor))
(assoc-in [:action-icon]
(assoc
;; todo reflection here
(texture (aget all-icons 0 (.indexOf utils/+all-cursors+ (or item-cursor action-cursor))))
:x (* utils/ui-scale 32 4) :y (* utils/ui-scale 4)
:width (* 18 4 utils/ui-scale) :height (* 16 4 utils/ui-scale)))