aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--conf.lua1
-rw-r--r--main.lua6
2 files changed, 7 insertions, 0 deletions
diff --git a/conf.lua b/conf.lua
index 2ef6952..c5ffc8e 100644
--- a/conf.lua
+++ b/conf.lua
@@ -4,5 +4,6 @@ function love.conf(t)
t.version = "0.10.0"
t.modules.joystick = false
t.window.title = "Don't Get a Virus"
+ t.window.fullscreentype = "exclusive"
t.window.fullscreen = false
end
diff --git a/main.lua b/main.lua
index 10b6b44..a138d94 100644
--- a/main.lua
+++ b/main.lua
@@ -22,12 +22,18 @@ function love.update(dt)
sys.mouse.x = love.mouse.getX()
sys.mouse.y = love.mouse.getY()
if love.keyboard.isDown("escape") == true then
+ love.window.setMode(800, 600, {fullscreen=false})
love.event.quit()
end
if love.keyboard.isDown("u") == true and win[1].min == true then
win[1].min = false
win[2].min = false
end
+ if love.keyboard.isDown("f4") == true then
+ love.window.setMode(800, 600, {fullscreen=true, fullscreentype="exclusive"})
+ elseif love.keyboard.isDown("f5") == true then
+ love.window.setMode(800, 600, {fullscreen=false})
+ end
end
function love.mousepressed(x, y, button)
sys.mouse.p.x = x