Changes
This commit is contained in:
@@ -1 +1 @@
|
||||
["^ ","~$map->ComponentRotation",["^ ","~:row",9,"~:col",1,"~:fixed-arities",["~#set",[1]],"~:name","^0","~:ns","~$sekai.core.init","~:top-ns","^7"],"~$ComponentRotation",["^ ","^1",9,"^2",1,"^5","^9","^6","^7","^8","^7"],"~$register-component",["^ ","^1",69,"^2",1,"^3",["^4",[3]],"^5","^:","^6","^7","^8","^7","~:type","~:fn"],"~$->Event",["^ ","^1",7,"^2",1,"^3",["^4",[5]],"^5","^=","^6","^7","^8","^7"],"~$map->Event",["^ ","^1",7,"^2",1,"^3",["^4",[1]],"^5","^>","^6","^7","^8","^7"],"~$->ComponentPosition",["^ ","^1",8,"^2",1,"^3",["^4",[2]],"^5","^?","^6","^7","^8","^7"],"~$init",["^ ","^1",90,"^2",1,"^3",["^4",[0]],"^5","^@","^6","^7","^8","^7","^;","^<"],"~$do-event!",["^ ","^1",32,"^2",1,"^5","^A","^6","^7","^8","^7"],"~:filename","/home/kahr/Projects/our_world/src/main/sekai/core/init.cljs","~$->ComponentRotation",["^ ","^1",9,"^2",1,"^3",["^4",[1]],"^5","^C","^6","^7","^8","^7"],"~$Event",["^ ","^1",7,"^2",1,"^5","^D","^6","^7","^8","^7"],"~$enqueue",["^ ","^1",22,"^2",1,"^3",["^4",[1]],"^5","^E","^6","^7","^8","^7","^;","^<"],"~$map->ComponentPosition",["^ ","^1",8,"^2",1,"^3",["^4",[1]],"^5","^F","^6","^7","^8","^7"],"~$game-state",["^ ","^1",5,"^2",1,"^5","^G","^6","^7","^8","^7"],"~$gameloop",["^ ","^1",73,"^2",1,"^3",["^4",[1]],"^5","^H","^6","^7","^8","^7","^;","^<"],"~$dequeue",["^ ","^1",25,"^2",1,"^3",["^4",[0]],"^5","^I","^6","^7","^8","^7","^;","^<"],"~$make-rotate-event",["^ ","^1",57,"^2",1,"^3",["^4",[3]],"^5","^J","^6","^7","^8","^7","^;","^<"],"~$render",["^ ","^1",12,"^2",1,"^3",["^4",[0]],"^5","^K","^6","^7","^8","^7","^;","^<"],"~$ComponentPosition",["^ ","^1",8,"^2",1,"^5","^L","^6","^7","^8","^7"],"~$make-move-event",["^ ","^1",49,"^2",1,"^3",["^4",[3]],"^5","^M","^6","^7","^8","^7","^;","^<"],"~$register-entity",["^ ","^1",66,"^2",1,"^3",["^4",[1]],"^5","^N","^6","^7","^8","^7","^;","^<"],"~$clear-game-view",["^ ","^1",85,"^2",1,"^3",["^4",[0]],"^5","^O","^6","^7","^8","^7","^;","^<"]]
|
||||
["^ ","~$init",["^ ","~:row",11,"~:col",1,"~:fixed-arities",["~#set",[0]],"~:name","^0","~:ns","~$sekai.core.init","~:top-ns","^7","~:type","~:fn"],"~:filename","/home/kahr/Projects/our_world/src/cljs/sekai/core/init.cljs"]
|
@@ -1 +1 @@
|
||||
["^ ","~$make-pixi",["^ ","~:row",4,"~:col",1,"~:fixed-arities",["~#set",[0]],"~:name","^0","~:ns","~$sekai.core.pixi","~:top-ns","^7","~:type","~:fn"],"~:filename","/home/kahr/Projects/our_world/src/main/sekai/core/pixi.cljs"]
|
||||
["^ ","~$make-canvas!",["^ ","~:row",4,"~:col",1,"~:fixed-arities",["~#set",[2]],"~:name","^0","~:ns","~$sekai.core.pixi","~:top-ns","^7","~:type","~:fn"],"~$clear-canvas!",["^ ","^1",8,"^2",1,"^3",["^4",[0]],"^5","^;","^6","^7","^8","^7","^9","^:"],"~$make-sprite!",["^ ","^1",13,"^2",1,"^3",["^4",[1]],"^5","^<","^6","^7","^8","^7","^9","^:"],"~:filename","/home/kahr/Projects/our_world/src/cljs/sekai/core/pixi.cljs"]
|
28
.clj-kondo/config.edn
Normal file
28
.clj-kondo/config.edn
Normal file
@@ -0,0 +1,28 @@
|
||||
{:linters
|
||||
|
||||
;; {:clojure-lsp/unused-public-var
|
||||
;; {:level :warning
|
||||
;; :exclude #{sekai.macros.components/defcomponent
|
||||
;; my-ns/bar
|
||||
;; other-ns
|
||||
;; my-func}
|
||||
;; :exclude-regex #{"sekai.macros.components/*"}
|
||||
;; :exclude-when-defined-by #{my-ns/defflow}
|
||||
;; :exclude-when-defined-by-regex #{"sekai.macros.components/*"}
|
||||
;; :exclude-when-contains-meta #{:my-cool-meta}}}
|
||||
|
||||
{
|
||||
:unresolved-symbol
|
||||
{:exclude [(sekai.macros.components/defcomponent)]}
|
||||
|
||||
:clojure-lsp/unused-public-var
|
||||
{
|
||||
:level :off
|
||||
:exclude #{sekai.macros.components}
|
||||
:exclude-when-defined-by [(sekai.macros.components/defcomponent)]
|
||||
:exclude-when-defined-by-regex #{"sekai.macros.components/*"}
|
||||
}
|
||||
}
|
||||
:hooks
|
||||
{:analyze-call {sekai.macros.components/defcomponent
|
||||
hooks.macros.components/defcomponent}}}
|
18
.clj-kondo/hooks/macros/components.clj
Normal file
18
.clj-kondo/hooks/macros/components.clj
Normal file
@@ -0,0 +1,18 @@
|
||||
(ns hooks.macros.components
|
||||
(:require [clj-kondo.hooks-api :as api]
|
||||
[clojure.string :refer [capitalize]]))
|
||||
|
||||
|
||||
(defn defcomponent [{:keys [node]}]
|
||||
(let [[name fields & [generator constructor destructor]] (rest (:children node))
|
||||
constructor (symbol (str "->Component" (capitalize name)))
|
||||
map-constructor (symbol (str "map->Component" (capitalize name)))
|
||||
generator (symbol (str "" name))]
|
||||
(println name)
|
||||
(println "wutwut")
|
||||
|
||||
{:node (api/list-node
|
||||
[(api/token-node 'declare)
|
||||
(api/token-node constructor)
|
||||
(api/token-node map-constructor)
|
||||
(api/token-node generator)])}))
|
Reference in New Issue
Block a user