Code: Select all
if love.keyboard.isDown("w") then
y = y - 200 * dt --dt is the delta time
end
if love.keyboard.isDown("a") then
x = x - 200 * dt
end
if love.keyboard.isDown("s") then
y = y + 200 * dt
end
if love.keyboard.isDown("d") then
x = x + 200 * dt
end
Code: Select all
if love.keyboard.isDown("w") then
y = y - 5
end
if love.keyboard.isDown("a") then
x = x - 5
end
if love.keyboard.isDown("s") then
y = y + 5
end
if love.keyboard.isDown("d") then
x = x + 5
end
Excluding that minor hiccup, the love framework is looking really awesome, I can't wait to make my ninjas vs civil war soldiers game!