Hey again
I was wondering if there is anyway to add one point to some sort of score saving system whenever my character jumps over one of the spawned dustbins. Here is the code for the spawned dustbins:
function spawnDustbin() i = 0 dustbin = {} i = i + 1 dustbin[i] = display.newImage("dustbin.png") dustbin[i].xScale = 0.55 dustbin[i].yScale = 0.55 dustbin[i].y = 555 dustbin[i].x = (math.random(1000,1100) \* i) dustbin[i].speed = 4 physics.addBody( dustbin[i], "static", { friction=1.0, density=1.0, bounce=0, radius=60} ) dustbin[i].enterFrame = moveDustbin Runtime:addEventListener("enterFrame", dustbin[i]) end
Thank You Very Much
James