From 5886071e3e05e6d75ffe0990776b5bd407f7ce3d Mon Sep 17 00:00:00 2001 From: equa Date: Fri, 23 Apr 2021 18:20:01 -0500 Subject: menu --- lib/main.fnl | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'lib/main.fnl') diff --git a/lib/main.fnl b/lib/main.fnl index e88f704..b657d94 100644 --- a/lib/main.fnl +++ b/lib/main.fnl @@ -77,6 +77,15 @@ (when profi? (profi:stopHooks))) +(fn love.mousepressed [x y button] + (match (pcall #(state.mousepressed the-state x y button)) + (true x) nil + (false x) (do + (print (.. "mousepressed: \n" x)) + (table.insert messages + {:ticks 5 + :msg (.. "mousepressed: \n" x)})))) + (fn love.keypressed [key scancode repeat] (when (and (= key "f") (not repeat)) (love.window.setFullscreen (not (love.window.getFullscreen)))) -- cgit 1.3.0-6-gf8a5