diff --git a/vacuum_gambit.p8 b/vacuum_gambit.p8 index 5bdae5d..611e96f 100644 --- a/vacuum_gambit.p8 +++ b/vacuum_gambit.p8 @@ -234,7 +234,7 @@ function updategame() end events:vore(new_events) events:strip(call_move) - for _, lst in ipairs{intangibles_bg, eships, pbullets, ebullets} do + for _, lst in ipairs{intangibles_bg, eships, pbullets} do lst:strip(call_move) end @@ -247,6 +247,8 @@ function updategame() return es:hitship(ps) end) ebullets:strip(function(eb) + -- loopify this when split moves implemented + eb:move() if (not collides(pbox, hurtbox(eb))) return ps:hitbullet(eb) return eb:hitship(ps) @@ -257,15 +259,7 @@ function updategame() -- use bucket collider for efficiency local eship_collider = collider.new() - -- save tokens, lose time: - -- eships:strip(function(s) eship_collider:insert(s) end) - local p, n = eships, eships.next - while n do - n.prev = p - eship_collider:insert(n) - p = n - n = p.next - end + eships:strip(function(s) eship_collider:insert(s) end) -- lose tokens, save time: -- unroll `strip` to avoid