wave top
This commit is contained in:
parent
51522e699c
commit
8c0b369339
22
vacation.p8
22
vacation.p8
@ -382,8 +382,13 @@ function wave(toff)
|
||||
return 2.5 * sin((t()+toff)>>1)
|
||||
end
|
||||
|
||||
waves={}
|
||||
mknew(waves)
|
||||
sea = {}
|
||||
mknew(sea)
|
||||
|
||||
function sea:draw()
|
||||
rectfill(0, 72+wave(), 128, 84, 1)
|
||||
|
||||
end
|
||||
|
||||
arcade_level = {
|
||||
score=0,
|
||||
@ -393,8 +398,7 @@ mknew(arcade_level, function(x)
|
||||
x.phin = toyphin.new{splasher=x}
|
||||
-- TODO: decent looking sky and sea
|
||||
x.sky = bg.new{c=12}
|
||||
x.sea = bg.new{y=72, c=1}
|
||||
x.waves = waves.new()
|
||||
x.sea = sea.new()
|
||||
-- event list includes words
|
||||
x.e = event_list.new()
|
||||
-- TODO: score renderer
|
||||
@ -453,12 +457,12 @@ end
|
||||
-- single sprite is bigger on
|
||||
-- the sprite sheet but easier
|
||||
-- to render.
|
||||
phin_nrm_pal = {
|
||||
game_nrm_pal = {
|
||||
[2]=2,
|
||||
[7]=7,
|
||||
[7]=7,
|
||||
[14]=14,
|
||||
}
|
||||
phin_uw_pal = {
|
||||
game_uw_pal = {
|
||||
[2]=130,
|
||||
[7]=13,
|
||||
[14]=141,
|
||||
@ -474,8 +478,8 @@ function setup_arcade_pal()
|
||||
memset(0x5f79,0xff,7)
|
||||
pal()
|
||||
pal(identity, 2)
|
||||
pal(phin_nrm_pal, 1)
|
||||
pal(phin_uw_pal, 2)
|
||||
pal(game_nrm_pal, 1)
|
||||
pal(game_uw_pal, 2)
|
||||
end
|
||||
|
||||
phinstate_nrm = {
|
||||
|
Loading…
Reference in New Issue
Block a user