Hi All,
It has been a long while - but I need your help DynamoForum!
I’m using a dynamo script to make unique groups and then place other instances at different locations.
The issue I’m having is that it places the group in the right spot, but then it seems to also shift the element inside the group by the same coordinates relative to the group origin. See below. This element inside the group (a placeholder family) should be at the group origin, but it is not.
Frankly, I don’t understand this behavior at all.
Ok. So I’ve actually just realized it is the creation of the initial groups and their origin that is the problem. The placeholder family is placed in the right place relative to the model, but the origin of those initial groups are seemingly randomly determined. Then when I go to place an instance the problem becomes obvious. So I’ve “solved” my issue, in that I’ve determined it is a different issue.
EDIT: Ok. I don’t know if anyone else will have this issue, but here is what got me. I placed the family with FamilyInstance.ByPointAndLevel. It puts the family in the right place and associates with the right level, but its origin point is still the model origin [0,0,0] not the point you assigned to place it. Then when you group it and go to place instances of that group, the origin is not where you expect it. See below:
I got around this by placing all the family instances at 0,0,0 (using ByPoint and not ByPointAndLevel), then moving them where I want before grouping. Everything is working now.