Zitat von Lancer
It's okay, we're all newbies when we start out.
Pad was a nil value because you didn't give it one. You have to do "pad = Controls.read()". You could also change pad to anything else, such as "input = Controls.read()", then you would check what button is being pressed with "input:circle()", for example.
If your code isn't in a loop, then LuaPlayer will go through the code once, then end the program. I set the loop to go until it detects that you are pressing the start button.
After "screen.flip()" you should put "screen.clear()" to clear the backbuffer, or else the backbuffer will have the image from the previous screen. It might help if I drew an example for you.
Tell me if you want me to explain something in more detail. It's always nice to know how things work, rather than just knowing that they do.