about summary refs log tree commit diff stats
path: root/main.lua
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2022-05-01 23:35:15 -0700
committerKartik K. Agaram <vc@akkartik.com>2022-05-01 23:35:15 -0700
commit886717f51ff486f24eed11cca9507ab0d8ff19ad (patch)
tree4c31d905b1ccbd06880d16df508e77467cfa9a76 /main.lua
parent32eed397e724967be3ee3cdb1df525c51b2b3b73 (diff)
downloadview.love-886717f51ff486f24eed11cca9507ab0d8ff19ad.tar.gz
handle space key
We're going to run into a few of these..
Diffstat (limited to 'main.lua')
-rw-r--r--main.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/main.lua b/main.lua
index c91cee5..16889c1 100644
--- a/main.lua
+++ b/main.lua
@@ -28,6 +28,8 @@ end
 function love.keypressed(key, scancode, isrepeat)
   if key == 'return' then
     table.insert(lines, '')
+  elseif key == 'space' then
+    lines[#lines] = lines[#lines]..' '
   else
     lines[#lines] = lines[#lines]..key
   end