Okay, I've used Construct for quite some time now, and I haven't ever been able to use Families without variable consistency errors, and yet it seems like other people are able to use them just fine. My problem is that it seems like when I change or reference variables pertaining to a family an object is in, things can go haywire where the wrong variables are called for (at least that's how I remember it, and how it seemed).

I read this in the Wiki about families:"Note that adding a new object to a family with common private variables, effects or behaviors will invalidate all existing events using them, if it does not have the same common variables etc. To ensure consistency between objects, the family manager should be used to add and remove objects from families."

I might be dumb for not being able to wrap my head around it, but it sounds like there's some sort of situation where events are invalidated. I'm trying to understand if what it says is that if I have BlueFamily and Guy is part of it, and BlueFamily is assigned variable 'butt', I can't change 'butt' in an event where I just reference Guy. Because that kind of would make my problems make sense, but sort of invalidate the use of Families for me.

I think I'm wrong though, I just want to clear up why I always get strange conflicts and have to stop using Families, which is making me create some inefficient code as replacement. Is it just a matter of being really careful to always use "Manage Families" when doing anything whatsoever to do with them?

Either way there's a problem, or something I don't understand about Families. Help!

I haven't had any problems like that. It didn't make heavy use of families, but I recently posted an example .cap that used a family so that I could pick two different instances of the same object, and it referenced private variables, here: [url:24k7cs23]http://www.scirra.com/forum/viewtopic.php?f=16&t=7028[/url:24k7cs23]. I've used families for other things with no problems, as well. I did have one project that had a different problem that I never figured out, which used families, though. This was several builds of Construct ago...

[quote:24k7cs23]I read this in the Wiki about families:"Note that adding a new object to a family with common private variables, effects or behaviors will invalidate all existing events using them, if it does not have the same common variables etc. To ensure consistency between objects, the family manager should be used to add and remove objects from families."[/quote:24k7cs23]

I think that this means that if you manually add a new object to a family in the layout editor, without using the family manager, and it doesn't have the common variables that the other objects have, that Construct will likely not work correctly in regards to that family. This would be understandable, if so.

As I recall, if you use the family manager to do so, it will take steps to ensure that the new object has the common attributes.

Adding variables to families sometimes yields strange results... such as the family NOT having the variable applied, but the objects inside the family having the variable.

The only thing you can really do in a situation like this is remove all variables from the objects individually, and use the family manager to add the new variables using the family manager only.

I have reported the problem to Ashley... it seems the way variables is applied is a bit weird (according to Davo).

I guess a lot of people haven't come across this issue, since it seems to be OK most of the time. I only came across it for the first time ever about 3-4 days ago. I think you have to be pretty unlucky to end up with this problem, but alas... "pretty unlucky" is my middle name.

[quote:3kgzlk6o]I think that this means that if you manually add a new object to a family in the layout editor, without using the family manager, and it doesn't have the common variables that the other objects have, that Construct will likely not work correctly in regards to that family. This would be understandable, if so.[/quote:3kgzlk6o]

Not really understandable if you actually CAN add objects through the Layout editor, it's like an evil trick!

I've come across it often enough that I don't use families at all. I hadn't read the thing about the family manager,but for me, anytime I add anything to a family member after its already in a family, everything goes completely messed up and unusable. Not just private variables either, behaviors, too. I can never anticipate everything ill need when I start out, so I avoid using families at all, since it almost always ends in disaster. Ill have to look into this family manager though, I thought it wad just there for convenience

i usually dont have trouble with families except for the odd time or two.

adding variables is pretty intuitive for the most part, and if you somehow mistakenly add a variable to an object alone or it goes into the wrong family, you CAN just add a variable with the same name to the family and the variable will automatically be replaced with the family counterpart

ive never had any irreversible bugs with families though and if your worried by it, you can just save before you try to do something you havent done before and revert if something messes up.

by all means you should use them if your constantly rewriting events for different objects.