diff options
| author | 1029chris <1029chris@gmail.com> | 2016-03-17 19:45:44 -0700 |
|---|---|---|
| committer | 1029chris <1029chris@gmail.com> | 2016-03-17 19:45:44 -0700 |
| commit | 0e39cf0a16b500ac757ef2a329a0938a064e4b1f (patch) | |
| tree | 481c4aa95460b50e0f0dff5ae1419a3d777a738d /main.lua | |
| parent | f8f18f11d739edceb0caf242cb5655c054012e3b (diff) | |
Started working on Virus 1 fight.
Diffstat (limited to 'main.lua')
| -rw-r--r-- | main.lua | 15 |
1 files changed, 13 insertions, 2 deletions
@@ -15,6 +15,7 @@ function love.load() require "loading" require "elements" require "notification" + require "virus1" love.graphics.setDefaultFilter("nearest", "nearest") love.graphics.setBackgroundColor(0, 0, 0) love.graphics.setNewFont() @@ -49,6 +50,15 @@ function love.update(dt) if scene == 1 then updateSystem(dt) end + if virus1.yes == true then + virus1.timer = virus1.timer + dt + end + if virus1.yes == true and virus1.timer >= 5 then + scene = 2 + if virus1.explodeintrotimer <= 7.8 then + virus1.explodeintrotimer = virus1.explodeintrotimer + dt + end + end end function love.mousepressed(x, y, button) sys.mouse.p.x = x @@ -65,8 +75,9 @@ end function love.draw() if scene == 1 then drawSystem() - end - if scene == 0 then + elseif scene == 0 then drawLoading() + elseif scene == 2 then + drawVirusFight1() end end |
