因此,如果我的分数高于5,那么gotoSceneA elseif gotoSceneB 但是我收到了这个错误:
game.lua:439: unexpected symbol near '..'*
如果我删除..
我得到:
game.lua:443: 'then' expected near 'end'
我的代码:
if .. score > 5 then
storyboard.gotoScene("bonus", "fade", 400)
elseif
storyboard.gotoScene("gameover", "fade", 400)
end
end
答案 0 :(得分:3)
if score > 1000 then
storyboard.gotoScene("bonus", "fade", 400)
else
storyboard.gotoScene("gameover", "fade", 400)
end