movement code
Posted: Sat Apr 13, 2019 2:08 pm
Finally! here is some code for movement
if love.keyboard.isDown("up") then
py = py - 1
end
if love.keyboard.isDown("down") then
py = py + 1
end
if love.keyboard.isDown("left") then
px = px - 1
end
if love.keyboard.isDown("right") then
px = px + 1
end
if love.keyboard.isDown("up") then
py = py - 1
end
if love.keyboard.isDown("down") then
py = py + 1
end
if love.keyboard.isDown("left") then
px = px - 1
end
if love.keyboard.isDown("right") then
px = px + 1
end