Simplifying engine interface #14
1 changed files with 5 additions and 4 deletions
|
|
@ -371,7 +371,7 @@
|
||||||
(assert (symbol? name))
|
(assert (symbol? name))
|
||||||
(assert (member type '(key-press)))
|
(assert (member type '(key-press)))
|
||||||
(set! input-actions
|
(set! input-actions
|
||||||
(cons (list name
|
(cons (cons name
|
||||||
(apply (cond
|
(apply (cond
|
||||||
((eqv? type 'key-press) make-key-press))
|
((eqv? type 'key-press) make-key-press))
|
||||||
data))
|
data))
|
||||||
|
|
@ -389,9 +389,10 @@
|
||||||
(lambda (action)
|
(lambda (action)
|
||||||
(cond
|
(cond
|
||||||
((key-press? (cdr action))
|
((key-press? (cdr action))
|
||||||
(push-event 'input
|
(when (key-pressed? (key-press-key (cdr action)))
|
||||||
(car action)
|
(push-event 'input
|
||||||
(cdr action)))))
|
(car action)
|
||||||
|
(cdr action))))))
|
||||||
input-actions))))
|
input-actions))))
|
||||||
|
|
||||||
;; Render queue exports
|
;; Render queue exports
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue