Sub-Events, why doesnt this work

Get help using Construct 2

Post » Wed Oct 23, 2013 2:48 pm



what i meant to make here is to make a pauze screen but...

This basicly does nothing, somebody any idea why?IkBenHarm2013-10-23 14:52:18
B
4
Posts: 14
Reputation: 228

Post » Wed Oct 23, 2013 2:57 pm

...LittleStain2013-10-23 15:14:56
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Wed Oct 23, 2013 3:04 pm

+ On Key press "P"
++ Pauze Number = 0
--- Your Actions
++ Pauze Number = 1
--- Your Actions

+ = condition
- = actions Darklinki2013-10-23 15:05:05
B
15
S
6
G
6
Posts: 512
Reputation: 5,555

Post » Wed Oct 23, 2013 3:05 pm

Event 2 sets Pauze_Number to 1, then because events run top to bottom, event 4 runs just after and sets it back to 0. Use the 'else' condition instead.
Scirra Founder
B
399
S
236
G
89
Posts: 24,519
Reputation: 195,351

Post » Wed Oct 23, 2013 3:10 pm

Setting up your events like below would be even better to prevent unwanted switching

I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Wed Oct 23, 2013 3:15 pm

i do see why it does not work now, tnx.

however, the else would not work either
B
4
Posts: 14
Reputation: 228

Post » Wed Oct 23, 2013 3:15 pm

wouldn't this just keep adding 1 at Pauze_Number?
B
4
Posts: 14
Reputation: 228

Post » Wed Oct 23, 2013 3:16 pm

[QUOTE=Ashley] Event 2 sets Pauze_Number to 1, then because events run top to bottom, event 4 runs just after and sets it back to 0. Use the 'else' condition instead.[/QUOTE]

i do see why it does not work now, tnx.
however, it still would now work with else
B
4
Posts: 14
Reputation: 228

Post » Wed Oct 23, 2013 3:16 pm

[QUOTE=LittleStain] Setting up your events like below would be even better to prevent unwanted switching

[/QUOTE]

Wouldn't this be adding 1 every time P is pressed?
B
4
Posts: 14
Reputation: 228

Post » Wed Oct 23, 2013 3:19 pm

There is a minus in front of the pauze_number, so when pauze_number is 0 it says
-0+1 (which is 1)
and when Pauze_number is 1 it says
-1+1 (which is 0)
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 8 guests