Break and Continue commands in a loop?

Get help using Construct 2

Post » Fri Oct 25, 2013 1:19 pm

Hi guys, I'm new to the forum, but I've been experiencing with Construct 2 for almost a month and I successfully ported an app which was initial made in another language.
Construct is complex and easy to use, but one of the important things that I'm missing is the possibility to add Break and Continue commands within nested loops. How do you deal with it? did someone made a plugin or something?
B
3
Posts: 3
Reputation: 206

Post » Fri Oct 25, 2013 1:37 pm

System Stop loop ( = continue)

or

-define local variable
+ for loop
+ variable != 1
- set variable 1 as soon as you want to break ;)

(= break)


I could make a break plugin, but I dont think this would save much time.Darklinki2013-10-25 13:42:34
B
15
S
6
G
6
Posts: 512
Reputation: 5,555

Post » Fri Oct 25, 2013 2:10 pm

Yes, you are right, we can use System Stop loop and add local variables and put conditions in the loop. But a real Break command would break the loop and not execute the remaining code from the current iteration. The Continue command would force the loop to not continue the iteration and jump to the next one.
B
3
Posts: 3
Reputation: 206


Return to How do I....?

Who is online

Users browsing this forum: lahbach and 24 guests