[solved] trigger subconditions in a function with parameter?

Get help using Construct 2

Post » Thu Jul 24, 2014 5:23 pm

Hi folks,

whilst playing around on a new project i stummbled upon a problem i'm not quite sure how to fix.
As you can see I call a function with a parameter. The first command ("set animation [...]") in the function works fine, which means the parameter is correctly set to a string called "down" or "up" or whatever since my animations are named in that way.
However the subevent conditions are not triggered even if the parameter has to be "down" (triggered on touch). Can anyone explain this to me plausible?

Thanks in advance!

~Gougth

screen.png
You do not have the required permissions to view the files attached to this post.
Last edited by Gougth on Thu Jul 24, 2014 5:36 pm, edited 1 time in total.
B
14
S
2
G
1
Posts: 53
Reputation: 850

Post » Thu Jul 24, 2014 5:27 pm

You have to compare the parameter 0, not the parameter Function.Param(0)

Function.Param(0) is the value of the 0th parameter
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
53
S
22
G
18
Posts: 2,122
Reputation: 17,123

Post » Thu Jul 24, 2014 5:34 pm

Thanks for the fast answer!

Where is the difference? And how do I compare the other one since i can't find any condition/index command to check it. :shock:


edit: I got it, thanks. I have to check function.param(1) since it's the 1# parameter not the 0th as u mentioned.

Many Thanks :-)
B
14
S
2
G
1
Posts: 53
Reputation: 850


Return to How do I....?

Who is online

Users browsing this forum: shawnzien and 7 guests