尝试索引本地“场景”(函数值)

时间:2013-08-31 11:06:50

标签: android sdk corona scene scroller

我在第11行编辑Corona中的game.lua时遇到此错误 ....

尝试索引本地“场景”(函数值)

代码:

--background

- 第11行是本文下面的第

function scene:createScene(event)

    local screenGroup = self.view

    local bkg = display.newImage("bkg.png")

    local back = display.newImage("back.png")
    back.y=450
    back.speed = 1
    back:setReferencePoint(display.BottomLeftReferencePoint)

    local back1 = display.newImage("back.png")
    back1.y=450
    back1.x=2400
    back1.speed = 1
    back1:setReferencePoint(display.BottomLeftReferencePoint)

    local front = display.newImage("front1.png")
    front.y=470
    front.speed = 4
    front:setReferencePoint(display.BottomLeftReferencePoint)

    local front1 = display.newImage("front1.png")
    front1.y=470
    front1.x=2400
    front1.speed = 4
    front1:setReferencePoint(display.BottomLeftReferencePoint)

    local bird = display.newImage("bird.png")
    bird.y = 285; bird.x= 200
    physics.addBody(bird, "dynamic", {density=0.1, bounce=0.1, friction=0.2, radius=10})


end

0 个答案:

没有答案