exit code
Moderators: Shine, Insert_witty_name
exit code
hi, i'm a bit of a noob when it comes to lua. i'm trying to fix a program which is broken. my main question is, how do i get lua to exit my program. i read that i have to stop all sound and music etc. i haven't the faintest where to start. i looked in the tutorial, and there wasn't a bit for exit code? any help?
-
- Posts: 116
- Joined: Mon Jul 18, 2005 2:20 am
You add a break condition to your game loop, like:
Then, when you press start, the game wil exit back to lowser (or whatever else). If you want to exit back to the psp's browser then you have to do what ShUr1k3n said ;)
Code: Select all
REPEAT = 0
while REPEAT==0 do
-- other game stuff here
if Controls.read():start()then
REPEAT = 1
end
end