diff --git a/games/boybomb.p8 b/games/boybomb.p8 index d121a62..7c99762 100644 --- a/games/boybomb.p8 +++ b/games/boybomb.p8 @@ -6,9 +6,12 @@ __lua__ #include sprites.lua function _init() + -- global initialization palt(11, true) palt(0, false) - start_level(2) + -- start first scene + --start_level(1) + start_scene("title") end function _update() @@ -36,13 +39,31 @@ function scene_time() end function draw_title() - cls() - print("title " .. scene_time()) + cls(2) + if scene_time() < 2 then + fillp(0b1010010110100101) + elseif scene_time() < 4 then + fillp(0b1010110110101101) + end + --rectfill(0, 0, 128, 128, 9) + fillp(0) + print("THE", 10, 0, 6) + print("\^w\^tboy", 10, 8, 11) + print("WHO", 10, 24, 6) + print("\^w\^tbecame", 10, 32, 11) + print("A", 10, 48, 6) + print("\^w\^tbomb", 10, 56, 11) + + for n=7,0,-1 do + if scene_time() > n then + sspr(16*n, 16, 16, 16, n*14, 90-((1.5*n)*(1.5*n)), 32+n*2, 32+n*2) + end + end end function update_title() - if scene_time() > 2 then - start_scene("explainer") + if scene_time() > 15 or btnp(4) then + start_level(1) end end @@ -75,7 +96,7 @@ function draw_explainer() print("WATCH OUT!", 40, 15, 7) end - print("in 1978, eddie boyman was \n involved in an accident.", 10, 80, 7) + print("in 1978, frank a. boyman was \n involved in an accident.", 10, 80, 7) if st > 4 then print("\nas a bystander of a \n failed nasa experiment") end @@ -86,10 +107,13 @@ function draw_explainer() print("a bomb", 70, 118, bcolor) end + if st > 15 or btnp(4) then + start_scene("title") + end + if st > 3 and st < 6 then draw_beam() end - draw_sprite(exp_spr) end