diff options
| author | RibbonCable <ambiguousmachine@gmail.com> | 2022-02-20 20:16:26 -0800 |
|---|---|---|
| committer | RibbonCable <ambiguousmachine@gmail.com> | 2022-02-20 20:16:26 -0800 |
| commit | 58632958abea0a00aea0e01e9897f587a1887bbd (patch) | |
| tree | 3bebecb888d9298e725cd4f631b7cae98d5a476f /players.lua | |
| parent | be10c608c87f81e55d61c715857e1657803115f1 (diff) | |
saved some tokens by grouping the "sxorewithzeros" thing
Diffstat (limited to 'players.lua')
| -rw-r--r-- | players.lua | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/players.lua b/players.lua index f16937a..0292568 100644 --- a/players.lua +++ b/players.lua @@ -51,11 +51,10 @@ function addplayer(x, y, sprite, spriteup, spritedwn, bulletsprite) respawntimer = 5 --respawns all players in 5 seconds player.inv = 20 killallenemies() - currentscore-=10 sfx(11, 0) --killed sfx(22, 1) --rewind beat elseif player.health <= 0 then - currentscore = currentscore \ 0.5 --halves score if coop + currentscore = currentscore \ 2 --halves score if coop (backslash to floor division) sfx(11, 0) player.inv = 5 end @@ -133,7 +132,7 @@ function addplayer(x, y, sprite, spriteup, spritedwn, bulletsprite) end function isgameover() - currentscore+=-10 --lose points if hit + currentscore -= 10 --lose points if hit for i = 1, #players, 1 do if players[i].health > 0 then return |
