Skip to content

Conversation

@thomas-advantitge
Copy link
Contributor

This helps to have a configurable order when using objects with vertex groups in order to use formation_index more easily.

@ntamas
Copy link
Member

ntamas commented May 16, 2024

This PR would also affect the behaviour of get_selected_objects_from_collection() because that uses get_selected_objects() internally. Furthermore, it would contradict the documentation of get_selected_objects_from_collection() because the documentation states that get_selected_objects_from_collection() returns the objects in the same order as they appear in context.selected_objects, which is not true anymore after this modification.

Can I suggest adding a sort: bool = False keyword argment to get_selected_objects() instead? You could then do the sort only when sort = True, and call get_selected_objects() with sort = True if needed. Sorry for being picky, I just don't see clearly what additional implications it would have to pre-sort the objects automatically and I don't want to break any existing behaviour.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants