When I run my app in the simulator, everything goes fine.
But when I run the game on my Neuxs 7, I get a pop-up message that says:
Runtime Error
H:\mygame\main.lua:542: attempt to index global ‘titlebackground’ (a nil value)
Here’s what I have (starting at line 540):
function makebackground() titlebackground=display.newImage("background.png") titlebackground:scale(320,480) titlebackground:toBack() end
my png file is exactly named background.png.
Why is this happening?