One click but triggers two condition

Get help using Construct 2

Post » Mon Aug 20, 2012 5:42 pm

I have something like that
(Event) Click:
-> (Action) Set a = 1
     
(Event) a = 1
    (Sub-event) Click:
        (Action)Command list 1

When I click, both a = 1 is set and Command list 1 is executed.
How can I make only one task to run at one moment.
Thanks in advance
B
5
Posts: 17
Reputation: 509

Post » Mon Aug 20, 2012 5:56 pm

Events are executed top-to-bottom, so you could try moving the bottom event to the top.
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544

Post » Tue Aug 21, 2012 2:06 am

Thank you Ashley
I have a code background, so basically is there any { } to embrace a code packet in Construct 2 that only allow one block to do at one time.
Best regards
B
5
Posts: 17
Reputation: 509

Post » Tue Aug 21, 2012 4:45 am

Events and sub events are like {}.

If the condition(s) of the top-level event is/are true, it will then test the conditions for the sub events of that event.
And you can have other sub events nested in that as well.

That's how events work.

You might also want to check the groups that you can activate/deactivate from a tick to another.Kyatric2012-08-21 04:46:32
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,999
Reputation: 57,793

Post » Wed Aug 22, 2012 7:07 am

Thank you Kyatric
B
5
Posts: 17
Reputation: 509


Return to How do I....?

Who is online

Users browsing this forum: Artpunk, GenkiGenga, Kagubro, Mirlas, zeneizel and 23 guests