diff options
| author | 1029chris <1029chris@gmail.com> | 2022-02-14 17:06:56 -0800 |
|---|---|---|
| committer | 1029chris <1029chris@gmail.com> | 2022-02-14 17:06:56 -0800 |
| commit | bd12de76d95361f59d148ebfa97df5d49fc6ddd4 (patch) | |
| tree | de8dcc3b3e00fa13f102691dc61bf82290bf04ed /players.lua | |
| parent | 2de3f16585df153dd249cebf44d0455c611a553d (diff) | |
implemented wall boss, also FUCK!!! trying to reduce tokens!!!!!!
Diffstat (limited to 'players.lua')
| -rw-r--r-- | players.lua | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/players.lua b/players.lua index ac755f1..117a518 100644 --- a/players.lua +++ b/players.lua @@ -1,9 +1,7 @@ -playercount = -1 alwaysfire = false players = {} function addplayer(x, y, sprite, bulletsprite) - playercount += 1 local player = {} player.health = 3 player.x = x @@ -14,7 +12,7 @@ function addplayer(x, y, sprite, bulletsprite) player.bulletsprite = bulletsprite player.ymov = 0 player.inv = 2 - player.id = playercount + player.id = #players player.shootcooldown = 0.0 player.particlecooldown = 0.0 player.shootspeed = 0.25 @@ -67,7 +65,7 @@ function addplayer(x, y, sprite, bulletsprite) addcircle(player.x+4, player.y+4, sin(i/8), cos(i/8), 2, 0.6, 7, 0) end --normal and light respawn sfx for co-op - if playercount == 1 then + if #players == 1 then sfx(27, 1) else sfx(28, 1) |
