[Suggestion] Adding families to families

Discussion and feedback on Construct 2

Post » Fri May 17, 2013 4:52 pm

Similarly (and this is one of the issues that initially sparked this idea), you can't have cross-family interactions that both address the same variable, since a family can only check variables that it has.

For example,

You have a Yin family and a Yang family. When a Yin they collide, you want them to reduce each other's Power variable by the other's value, and destroy if it hits 0. (So if a 20-power Yang and a 10-power Yin collide, the result should be a 10-power Yang and no Yin). Under the current system, there's no way that both families can have the same variable in common.
B
17
S
4
G
4
Posts: 143
Reputation: 4,004

Post » Fri May 17, 2013 7:15 pm

We would have to overhaul large and complicated parts of the engine to allow nested families, so I'm afraid right now I'd say it's very unlikely we'd take this on. Hopefully it's possible to workaround by duplicating variables in families.

@roxflame - you don't need families for your example, you can work around it with 'Pick Nth instance'. Instance 0 will be the first colliding instance and instance 1 will be the second, then you can handle each separately in subevents.
Scirra Founder
B
359
S
214
G
72
Posts: 22,951
Reputation: 178,578

Post » Fri May 17, 2013 11:23 pm

[QUOTE=ChrisAlgoo] Similarly (and this is one of the issues that initially sparked this idea), you can't have cross-family interactions that both address the same variable, since a family can only check variables that it has.

For example,

You have a Yin family and a Yang family. When a Yin they collide, you want them to reduce each other's Power variable by the other's value, and destroy if it hits 0. (So if a 20-power Yang and a 10-power Yin collide, the result should be a 10-power Yang and no Yin). Under the current system, there's no way that both families can have the same variable in common.[/QUOTE]

@ChrisAlgoo: Unless there's something wrong in the description of your example this is totally doable as it is in C2.
Each family has a different variable indeed, but I don't see it as an issue since they are different "objects" anyway.
Example capx
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

Previous

Return to Construct 2 General

Who is online

Users browsing this forum: Eisenhans and 13 guests