0
$\begingroup$

Video to the question: https://youtu.be/kgvwxt84Rkg

After deleting an object which is part of a collection it seems the collection still contains the deleted object (which i did not expect). Especially problematic for me is that I can't find a way to fix this. I discovered the problem way to late to undo the deletion and I don't know how to modify the collection directly.

Please help

$\endgroup$
0
$\begingroup$

I fixed my problem by creating new collections (which obviously don't contain the deleted object), selecting an empty which shall receive the new collection as the instancing property and using a simple script

import bpy

bpy.ops.object.select_linked(type='DUPGROUP')
for obj in bpy.context.selected_objects:
    obj.instance_collection = bpy.data.collections["newCollection"]

Afterward I found out I could have done the same via Select Linked (Shift+L) \ Instanced Collection and editing the property while holding Alt (to apply it to all selected objects).

I still have the now unused collections in the blend-file and can't seem to get rid of them plus I was searching for a way to edit the original collections so I see this as a workaround and leave the question open for additional answers.

| improve this answer | |
$\endgroup$
  • $\begingroup$ Your problem comes from the fact that you are trying to instance a collection from within the very same collection, which you should'nt be able to do since logically it should recursively infintely add objects. As you found out, you should instance collections from outside of said colllections $\endgroup$ – Gorgious Jul 20 at 7:57
  • $\begingroup$ I just tested and this behaviour is fixed in the latest stable version (2.83.2), I couldn't reproduce what you did in your youtube video. (This was a bug). Also now you can directly instance collections with the Add menu $\endgroup$ – Gorgious Jul 20 at 7:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.