Clarification required: Stop Loop system action

Discussion and feedback on Construct 2

Post » Mon Mar 27, 2017 12:00 pm

I notice some really strange things going on when I give the Stop Loop system action in the events of a specific loop running, does it only stop the loop it belongs to ie. For "y" 1-100 + condition check > Do this & Stop Loop, stops only the "y" loop, or does it stop ALL loops (global) running currently?
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,616

Post » Mon Mar 27, 2017 12:03 pm

Stops the loop in scope.
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Mon Mar 27, 2017 12:05 pm

99Instances2Go wrote:Stops the loop in scope.


Okay I thought so, but the wording for that action is "Stop any currently running loop"... I was worried it was halting all other running loops causing some funky issues, but otherwise, it's just my sloppy coding causing the issues then if it works as loop-specific.
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,616

Post » Mon Mar 27, 2017 12:08 pm

Well, the scope is not always that easy to spot, especial when you gonna use functions and triggers.
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Mon Mar 27, 2017 12:44 pm

Common example.

https://www.dropbox.com/s/sdtfgycx3xv7y ... .capx?dl=0
I have no idea how to stop the 'for each'.

So, lets organize the events in way that the scope is clear.
https://www.dropbox.com/s/b09vmzc4g7u40 ... .capx?dl=0
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 11 guests