I figured to use this in the Intro to Game Programming class I am teaching and a coding club I am helping with. Not being real familiar with Corona I went through it first. Everything went smoothly until the last function, the onCollision event function. First the error was telling me an “end” was needed to close the function. I found that one. There was an extra “end” on the line just above the elseif. This extra “end” was in the reading and in the downloaded complete program (which also gave the same error). I fixed that. Now I am getting “attempt to index global ‘obl1’ (a nil value)” at the line of the second if statement in onCollision. I get the same error in the downloaded complete program. This error pops up after the game has run a few seconds. This one is on the edge of my understanding this language. I am guessing it has something to do with the way the obj1 object is declared in the event.phase if statement just above the error line but it looks good to me.
This might be something the Corona website manager might want to correct on the tutorial. Unless they want new users (me) to get really frustrated. Other than these little glitches this is going to be great for the coding club for this month. If I can find the bugs that is.