v1.0
This commit is contained in:
parent
6ea7bd8af3
commit
9be34a91d6
23
snowdogs.p8
23
snowdogs.p8
@ -37,9 +37,11 @@ function _draw()
|
||||
draw_game()
|
||||
draw_snow()
|
||||
draw_hud()
|
||||
draw_bounds()
|
||||
--draw_bounds()
|
||||
elseif mode == "gameover" then
|
||||
draw_flag()
|
||||
draw_flag(true)
|
||||
elseif mode == "win" then
|
||||
draw_flag(false)
|
||||
end
|
||||
end
|
||||
|
||||
@ -113,6 +115,8 @@ function cast_dr()
|
||||
print("dogs", 38, 110, 1)
|
||||
sled_dr()
|
||||
|
||||
print("❎ to mush", 45, 75, 1)
|
||||
|
||||
draw_heart(100, 80)
|
||||
draw_fan(100, 90)
|
||||
print("the fan", 90, 120)
|
||||
@ -195,8 +199,8 @@ function draw_hud()
|
||||
print("▒", 108, 0, 0)
|
||||
|
||||
if distance >= goal then
|
||||
print("you win!", 35, 64)
|
||||
-- if distance is near 100
|
||||
mode = "win"
|
||||
-- if distance is near multiple of 1000
|
||||
elseif distance%1000 < 100 then
|
||||
local mtg = ceil((goal-distance)/1000)*100
|
||||
print(mtg.." miles to go!", 30, 64)
|
||||
@ -228,7 +232,7 @@ function sled_upd()
|
||||
steering = 0
|
||||
end
|
||||
|
||||
speed = 1 + (distance / 5000)
|
||||
speed = 2 + (distance / 3000)
|
||||
|
||||
if btnp(4) and t() - mush_time > 1 then
|
||||
mush_time = t()
|
||||
@ -472,7 +476,7 @@ end
|
||||
-->8
|
||||
--end screens
|
||||
|
||||
function draw_flag()
|
||||
function draw_flag(loser)
|
||||
cls()
|
||||
|
||||
for x=0,128,1 do
|
||||
@ -494,7 +498,14 @@ function draw_flag()
|
||||
print("★", star.x, star.y + sin(t()+((star.x+4)/128)) * 5-10, 9)
|
||||
end
|
||||
|
||||
if loser then
|
||||
print("better luck next year", 20, 115, 9)
|
||||
else
|
||||
music(0)
|
||||
local scale = (sin(t()) + 2)*2.5 * 8
|
||||
sspr(32, 24, 8, 8, 80-scale/2, 48-scale/2, scale, scale)
|
||||
print("see you again in '84!", 20, 115, 9)
|
||||
end
|
||||
end
|
||||
|
||||
__gfx__
|
||||
|
Loading…
Reference in New Issue
Block a user