Skip to content

Instantly share code, notes, and snippets.

@ftsf
Forked from anonymous/gist:a9089a806becc96a45c8
Last active October 16, 2015 06:46
Show Gist options
  • Save ftsf/3cb861801b6a42faa2ac to your computer and use it in GitHub Desktop.
Save ftsf/3cb861801b6a42faa2ac to your computer and use it in GitHub Desktop.
function _update()
p1.vx = 0
p1.vy = 0
if s==1 then
if btn(0) then
pl.vx-=1
chspr=019
f=true
end
if btn(1) then
pl.vx+=1
chspr=019
f=false
end
if btn(2) then
pl.vy-=1
chspr=003
f=false
end
if btn(3) then
pl.vy+=1
chspr=035
f=true
end
end
pl.x+=pl.vx
pl.y+=pl.vy
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment