Compare commits
2 Commits
d4a67acc9b
...
78fe254e96
Author | SHA1 | Date | |
---|---|---|---|
78fe254e96 | |||
31fb5b83e9 |
@ -279,6 +279,9 @@ end
|
||||
-->8
|
||||
-- panel drawing
|
||||
|
||||
-- empty panel placeholder
|
||||
nopanel = {}
|
||||
|
||||
-- panel in ordinary state
|
||||
panel = {
|
||||
-- plt: palette as table
|
||||
@ -291,6 +294,7 @@ panel = {
|
||||
-- negative == mid-fall
|
||||
-- positive == bounce
|
||||
-- frames left
|
||||
state="idle"
|
||||
}
|
||||
mknew(panel)
|
||||
|
||||
@ -310,6 +314,7 @@ prpblkp = {14,13,2,7}
|
||||
newblock = {
|
||||
function()
|
||||
return panel.new{
|
||||
id=1,
|
||||
plt=redblkp,
|
||||
sx=83,sy=1,
|
||||
ey=2, as=0,
|
||||
@ -317,6 +322,7 @@ newblock = {
|
||||
end,
|
||||
function()
|
||||
return panel.new{
|
||||
id=2,
|
||||
plt=ylwblkp,
|
||||
sx=83,sy=11,
|
||||
ey=2,as=0,
|
||||
@ -324,6 +330,7 @@ newblock = {
|
||||
end,
|
||||
function()
|
||||
return panel.new{
|
||||
id=3,
|
||||
plt=grnblkp,
|
||||
sx=78,sy=11,
|
||||
ey=2,as=0,
|
||||
@ -331,6 +338,7 @@ newblock = {
|
||||
end,
|
||||
function()
|
||||
return panel.new{
|
||||
id=4,
|
||||
plt=blublkp,
|
||||
sx=83,sy=6,
|
||||
ey=2,as=0,
|
||||
@ -338,6 +346,7 @@ newblock = {
|
||||
end,
|
||||
function()
|
||||
return panel.new{
|
||||
id=5,
|
||||
plt=prpblkp,
|
||||
sx=73,sy=11,
|
||||
ey=2,as=0,
|
||||
@ -419,6 +428,42 @@ function ants:draw()
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-->8
|
||||
-- gameplay logic
|
||||
|
||||
game={
|
||||
incoming_frac = 0,
|
||||
speed = 0,
|
||||
gravity_lag = 30,
|
||||
pop_lag = 20,
|
||||
|
||||
stop_frames = 0,
|
||||
stop_max = 1,
|
||||
life = 180,
|
||||
life_max = 180,
|
||||
}
|
||||
|
||||
mknew(game, function(ret)
|
||||
local board = {}
|
||||
for i=1,12 do
|
||||
board[i] = {
|
||||
nopanel, nopanel, nopanel, nopanel, nopanel, nopanel,
|
||||
}
|
||||
end
|
||||
ret.board = board
|
||||
ret.garbage_queue = {}
|
||||
ret.garbage_source = source.new()
|
||||
ret.floor_source = source.new()
|
||||
end)
|
||||
|
||||
function game:update()
|
||||
end
|
||||
|
||||
function game:draw()
|
||||
end
|
||||
|
||||
|
||||
__gfx__
|
||||
0000000000111000011011000000000009999900066666000eeeee00077777000aaaaa0001111111000000000000000000000000000000000000000000000000
|
||||
00000000012221001221221000000000988888206bbbbb30eddddd207cccccd0a999994012222222300040400000000000000000000000000000000000000000
|
||||
|
Loading…
Reference in New Issue
Block a user