Jump to content
Sign in to follow this  
-~1ncognito~-

Very simple question...

Recommended Posts

How do you exit a script? say you have a loop script

and you want it to end after it is finished doing whatever

you wanted it to do. Would you just type Goto "end" and

then have

#end

end

Share this post


Link to post
Share on other sites

Use the Exit command.

#Loop

Dostuff

if (value = true) : goto "end"

goto "Loop"

#end

Exit

Maybe you can say exit right away instead of goto "end", but i need to test that.

Share this post


Link to post
Share on other sites

_i = 0

#loop

_i = _i + 1

? _i == 3 : goto "blah"

? _i < 10 : goto "loop"

hint "i = 10 now!"

exit

#blah

hint "What are you doing here??  I heard i = 3!"

goto "loop"

hint "This code will never execute"

EDIT: Eep! Didn't see other post by Fangie.

Doolittle

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×