Simple question

Previous topic - Next topic

Darmakwolf

This may be a terribly stupid question, but I want to be able to quit an application in the Wiz, but volume +&- is rather silly. I know how to disable that from working, but there seems to be no way to just get back to the wiz's menu screen. END doesn't do the trick. Help?

Ian Price

You can just end all running functions/loops and it'll exit back to the WIZ menu.

Eg

Code (glbasic) Select

SETSCREEN 320,240,0

main()

// Main function
FUNCTION main:

LOCAL quit=0

// Loop until the condition is met (ie quit<>0)
WHILE quit=0

// Loop through all possible key values and exit the function if key pressed
FOR n=0 TO 255
IF KEY(n) THEN QUIT=1
NEXT

PRINT "PRESS ANY KEY TO EXIT",10,10

SHOWSCREEN

WEND

ENDFUNCTION


That's from memory, not tested, but it should work.
I came. I saw. I played.

Darmakwolf

That does the trick on the Wiz! Thank you much.