From 05c10238d59c8e6e1289aa8cae930c3a4c940c53 Mon Sep 17 00:00:00 2001 From: RibbonCable Date: Sat, 19 Feb 2022 00:50:49 -0800 Subject: Token hunting: removed most of "local" before variables (seems to work fine), removed health from wall shooter since it was always 10, added check for coop and laser functionality on wave 16 --- pickups.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'pickups.lua') diff --git a/pickups.lua b/pickups.lua index d43984b..41fa66c 100644 --- a/pickups.lua +++ b/pickups.lua @@ -20,7 +20,7 @@ function addpickup(x, y, type) type = type or rnd({"fastshoot", "3shoot"}) function pickup.draw(pickup) - local sprite = 4 --had to move these checks into draw or they'd have incorrect sprites + local sprite = 4 --health if type == "fastshoot" then sprite = 20 elseif type == "3shoot" then @@ -38,18 +38,18 @@ function addpickup(x, y, type) end function pickup:affect(player) - local color = 8 + pickupcolor = 8 --health if type == "fastshoot" then player.shootspeed = 0.17 - color = 12 + pickupcolor = 12 elseif type == "3shoot" then player.shoot3 = true - color = 9 + pickupcolor = 9 else player.health = 3 end for i = 1, 8, 1 do - addcircle(x, y, sin(i/8), cos(i/8), 2, 0.6, color) + addcircle(x, y, sin(i/8), cos(i/8), 2, 0.6, pickupcolor) end currentscore+=10 --10 points sfx(30, 1) -- cgit