possible to specify variable of family member?

Get help using Construct 2

Post » Tue Mar 13, 2012 10:38 pm

ok so here it is:

player casts a spell (star)
star has a variable (DMG) that decides the damage target takes.
star is also a member of the family "spells"
target har a variable (HP) and is a member of the family "enemies"

is it possible to make an event to look like this?:(> = event - = action)

>spells on collision with enemies -enemies subtract spells.DMG from enemies.HP

cant find a way to make a specific family members variables to effect a variable on a specific member of a different family. Is this possible?
B
28
S
10
G
6
Posts: 251
Reputation: 6,655

Post » Tue Mar 13, 2012 11:38 pm

anyone?
B
28
S
10
G
6
Posts: 251
Reputation: 6,655

Post » Tue Mar 13, 2012 11:44 pm

Not sure to understand your question there, but maybe you are looking for the system compare two values condition, or simply the fact of adding several conditions on the same event (right click on the event, "Add another condition").
New to Construct ? Where to start

Image Image

Image Image

Please attach a capx to any help request or bug report !
Moderator
B
273
S
100
G
71
Posts: 7,270
Reputation: 76,425

Post » Tue Mar 13, 2012 11:59 pm

what I mean is when someone from the family "enemies" is hit by a spell from the family "spells" the variable DMG of that specific spell is used to change the variable of the specific target. So I dont have to make tons of events and actions between every kind of spell and every kind of enemy.
B
28
S
10
G
6
Posts: 251
Reputation: 6,655

Post » Wed Mar 14, 2012 12:39 am

It would help if you posted the capx of how you've configured/setted things so far in your project.

Have a look at that uncommented capx is it what you are looking for ?
New to Construct ? Where to start

Image Image

Image Image

Please attach a capx to any help request or bug report !
Moderator
B
273
S
100
G
71
Posts: 7,270
Reputation: 76,425

Post » Wed Mar 14, 2012 12:45 am

Yep! thats it :) thank you so much!!
B
28
S
10
G
6
Posts: 251
Reputation: 6,655

Post » Sun Jul 22, 2012 5:58 am

Just wanted to post to say Kyatric's example helped me out too. Thanks!
B
9
Posts: 6
Reputation: 862


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 9 guests