|
@@ -9,6 +9,7 @@ local bullet_speed = 6
|
|
|
local bullet_timer = 0
|
|
|
local bullet_timer_start = 10
|
|
|
|
|
|
+-- props: x, y, vx, vy, type
|
|
|
local player_bullets = {}
|
|
|
|
|
|
local player = {
|
|
@@ -68,6 +69,16 @@ function add_bullet()
|
|
|
vx = 0,
|
|
|
vy = 0,
|
|
|
})
|
|
|
+ if #player.gunpods > 0 then
|
|
|
+ for _,pod in ipairs(player.gunpods) do
|
|
|
+ table.insert(player_bullets, {
|
|
|
+ x=pod.x + 4,
|
|
|
+ y=pod.y,
|
|
|
+ vx = 0,
|
|
|
+ vy = 0,
|
|
|
+ })
|
|
|
+ end
|
|
|
+ end
|
|
|
end
|
|
|
|
|
|
function add_gunpod()
|