Lately I’ve been learning to script a bit in python and I’ve been trying to create a script that loops through the selected objects (polysurfaces) and puts a minimum boundingbox around each and then selecting all of those at once it’s done.
So far I’ve found a script that creates a minimum bounding box around an object and that works great, but I’m having troubles trying to adapt it to multiple objects.
I’m guessing trying to put objects into a list isn’t going to work? Is there any other way to remember the objects in order to loop through them or am I approaching this the wrong way?
Yes, I’ve found an old script here that calculates the minimum size bounding box and creates this. It worked perfectly before I tried to put it into a list so I didn’t think that’s where the problem was.
Currently when I try to run this script it doesn’t show anything, no errors either which is why I’m not sure how to fix it.
Edit: I’m an idiot and noticed I didn’t even run the function. That is fixed so I’m getting errors again. I still have my original questions about putting objects into lists though. I found some posts about GUID, is that where I should be looking?
I’ll reupload the script in the original post just in case.
Edit 2: Just now I found this info about rhino objects in python, actually written by you… I feel quite silly for posting this thread now.