summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorthe lemons <citrons@mondecitronne.com>2022-12-22 16:21:14 -0600
committerthe lemons <citrons@mondecitronne.com>2022-12-22 16:21:14 -0600
commitede9af54010eab4eb6ee1b81fe9d6a0333846e88 (patch)
tree9b15a9ff5fba7ba08e9f4b5ae3bdf9dda2258ff3
parent1354987c10c6ac6803a8e49d40e4f360f052a4de (diff)
do not initiate drag selection when holding shift
-rw-r--r--main.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.lua b/main.lua
index 5eb7b54..619b5ec 100644
--- a/main.lua
+++ b/main.lua
@@ -108,7 +108,7 @@ function love.draw()
end
function love.update()
- if not (selection or dragging) then
+ if not (selection or selecting) then
for o in obj.all() do
o:tick()
end
@@ -155,7 +155,7 @@ function love.mousemoved(x, y, dx, dy)
if drag_start then
if not dragging then
local clicked = obj.at(x, y)()
- selecting = not clicked
+ selecting = not clicked and not love.keyboard.isDown "lshift"
end
if selecting then
local sx, sy = unpack(drag_start)