This commit is contained in:
James Turk 2023-04-12 01:29:49 -05:00
parent 2e73c0a92e
commit 771c057aaa

View File

@ -143,7 +143,6 @@ function hitbody()
ejected += 1 ejected += 1
end end
end end
printh("#tbody=".. #tbody .." ejected "..ejected)
end end
function toomgis_draw(x, y) function toomgis_draw(x, y)
@ -241,7 +240,7 @@ end
function reset_items() function reset_items()
items = {} items = {}
for i=0,10 do for i=0,5 do
add(items, {x=0, y=0, n=0}) add(items, {x=0, y=0, n=0})
end end
end end
@ -262,7 +261,7 @@ function level_draw()
local h=32 * zoom local h=32 * zoom
for y=0,h do for y=0,h do
tline(0, 128-h+y, 128, 128-h+y, -- screen coordinates (entire screen scanlines) tline(0, 128-h+y, 128, 128-h+y, -- screen coordinates (entire screen scanlines)
px/80, lvl.mapy+y/(8*zoom), 1/(8*zoom), 0) px/100, lvl.mapy+y/(8*zoom), 1/(8*zoom), 0)
-- don't scale x start with zoom, since position is not dependent -- don't scale x start with zoom, since position is not dependent
end end
@ -322,8 +321,6 @@ end
function streak2mult() function streak2mult()
if streak > 20 then if streak > 20 then
return 5
elseif streak > 10 then
return 3 return 3
elseif streak > 5 then elseif streak > 5 then
return 2 return 2
@ -390,6 +387,7 @@ function level_upd()
end end
if btnp(⬆️) then if btnp(⬆️) then
-- DEBUG
start_level(lvl.next) start_level(lvl.next)
end end
@ -412,7 +410,6 @@ function level_upd()
end end
local d = dist(20+8, 96-py+8, item.x+4-px, item.y+4) local d = dist(20+8, 96-py+8, item.x+4-px, item.y+4)
--printh(item.n.." "..(item.x+4-px)..","..(item.y+4).." d="..d)
if d < toomgis_radius() and item.n != 0 then if d < toomgis_radius() and item.n != 0 then
-- item collision -- item collision
if item.n > 16 then if item.n > 16 then