Browse Source

borb can stand on tree

main
Colin McMillen 2 weeks ago
parent
commit
9b6fb90852
  1. 35
      borb.p8

35
borb.p8

@ -79,7 +79,7 @@ function update_player()
end
player.y += player.vy
player.vy += 0.5
if player.vy > 0 and btn(🅾️) then
if player.vy > 0 and btn(🅾️) and player.state >= fly then
if player.state == fly then
set_state(glide)
end
@ -93,6 +93,15 @@ function update_player()
end
end
terrain = mget((player.x+4)/8,(player.y+8)/8)
if player.vy > 0 and fget(terrain, 0) then
player.y = ((player.y + 1)\ 8) * 8
player.vy = 0
if player.state >= fly then
set_state(stand)
end
end
player.x = mid(0, player.x, 1016)
-- update sprite
@ -177,13 +186,13 @@ __gfx__
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
4444444444444444ff4444ffff4444ffffffffffffffffffffffffff000000000000000000000000000000000000000000000000000000000000000000000000
4444444444444444ff4444ffff4444ffffffffffffffffffffffffff000000000000000000000000000000000000000000000000000000000000000000000000
1444444144444411ff4444ffff4444ffffffffffffffffffffffffff000000000000000000000000000000000000000000000000000000000000000000000000
1114411111441111ff4444ffff4444fffffff33ff33ff33ff33fffff000000000000000000000000000000000000000000000000000000000000000000000000
1111111111111111ff4444ffff4444fffff333333333333333333fff000000000000000000000000000000000000000000000000000000000000000000000000
1111111111111111f444444fff4444ffff33333333333333333333ff000000000000000000000000000000000000000000000000000000000000000000000000
1111111111111111f444444fff4444fff3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
4444444444444444ff4444ffff4444fffffff33ff33ff33ff33fffff000000000000000000000000000000000000000000000000000000000000000000000000
4444444444444444ff4444ffff4444fffff333333333333333333fff000000000000000000000000000000000000000000000000000000000000000000000000
1444444144444411ff4444ffff4444ffff33333333333333333333ff000000000000000000000000000000000000000000000000000000000000000000000000
1114411111441111ff4444ffff4444fff3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
1111111111111111ff4444ffff4444fff3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
1111111111111111f444444fff4444ff333333333333333333333333000000000000000000000000000000000000000000000000000000000000000000000000
1111111111111111f444444fff4444ff333333333333333333333333000000000000000000000000000000000000000000000000000000000000000000000000
1111111111111111f444444fff4444fff3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000ff4444fff3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000ff4444ff333333333333333333333333000000000000000000000000000000000000000000000000000000000000000000000000
@ -194,15 +203,15 @@ __gfx__
000000000000000000000000ff4444ff333333333333333333333333000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000ff4444fff3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000f3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000333333333333333333333333000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000333333333333333333333333000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000f3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000f3333333333333333333333f000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000ff33333333333333333333ff000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000fff333333333333333333fff000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000fffff33ff334433ff33fffff000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000ffffffffff4444ffffffffff000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000ffffffffff4444ffffffffff000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000ffffffffff4444ffffffffff000000000000000000000000000000000000000000000000000000000000000000000000
__gff__
0000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000000000000010101000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
__map__
0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
@ -213,8 +222,8 @@ __map__
0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000004445460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000005455560000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000005455560000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003
0000000000000000006465660000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003
0000000000000000000043000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000

Loading…
Cancel
Save