This commit is contained in:
Kistaro Windrider 2024-02-04 17:49:08 -08:00
parent 51522e699c
commit 8c0b369339
Signed by: kistaro
SSH Key Fingerprint: SHA256:TBE2ynfmJqsAf0CP6gsflA0q5X5wD5fVKWPsZ7eVUg8

View File

@ -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 = {