[PLUGIN] While-loop

Post your completed addons to share with the community

Post » Sat Jan 28, 2012 5:18 am

What would be the proper way to trigger 'toggle spawn using the timeline function?

Putting onCondition:function outside of the loop doesn't affect the boolean instance variable of the loop :( Khaz2012-01-28 05:21:02
B
12
S
3
G
2
Posts: 110
Reputation: 2,435

Post » Sat Jan 28, 2012 11:53 am

Thanks for this plug-in :)
B
17
S
4
G
4
Posts: 137
Reputation: 3,767

Post » Sat Jan 28, 2012 3:20 pm

@Khaz

I'm not sure what you want. To put "condition:on function", you should do this.

BTW, in "condition:while", you start timer "spawn" many times, it will only start "this" timer one time.
If you want start many timers, you should use many "action: create timer" for each timer.rexrainbow2012-01-28 15:24:37
B
107
S
25
G
243
Posts: 4,391
Reputation: 137,474

Post » Sat Jan 28, 2012 4:16 pm

Tnx for all Rex ^^
B
163
S
39
G
13
Posts: 234
Reputation: 18,286

Post » Sat Jan 28, 2012 6:33 pm

What I'm trying to achieve: I want the loop to run every X seconds until remain becomes 0.

the loop is,

choose a zombie type.
spawn the zombie.
B
12
S
3
G
2
Posts: 110
Reputation: 2,435

Post » Sat Jan 28, 2012 6:35 pm

Use a flag, that stops the loop and then create a "every x second" event. If you have a capx I will edit it for you
B
44
S
21
G
13
Posts: 723
Reputation: 14,770

Post » Sat Jan 28, 2012 6:38 pm

Thanks :)

I've been trying to use a flag but I just don't know Construct2 very well I suppose. Khaz2012-01-28 18:43:19
B
12
S
3
G
2
Posts: 110
Reputation: 2,435

Post » Sat Jan 28, 2012 6:50 pm

Here you go...

Changed CAPX
B
44
S
21
G
13
Posts: 723
Reputation: 14,770

Post » Sat Jan 28, 2012 6:54 pm

Thanks, I suppose that's a lot simpler solution. ><
B
12
S
3
G
2
Posts: 110
Reputation: 2,435

Post » Sat Jan 28, 2012 6:55 pm

I hope it does what you intended
B
44
S
21
G
13
Posts: 723
Reputation: 14,770

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: No registered users and 2 guests