love2d - Lua requires a } to close a { that is already closed -
this issue appears if single more line "player" class.
code:
function love.load() player = { x = 0, y = 0, dky = character y_velocity = 0, jump_time = 1, jump_time_max = 1, character = love.graphics.newimage("gfx/character.png") } gravity = 400 jump_height = 300 winw, winh = love.graphics.getwidth(), love.graphics.getheight()
end
you forgot add comma after
character = love.graphics.newimage("gfx/character.png")
when added line player
.
the code give has problem: missing comma after dky = character
.
Comments
Post a Comment