Blender-28-Addons
Blender-28-Addons copied to clipboard
'Needs at least two selected objects' when distribute objects in blender 2.91
My configuration:
ubuntu 20.04
python 3.8.5
blender 2.91
I cloned this:
git clone https://github.com/oscurart/Blender-28-Addons
To local,then copy subfolder to addons:
sudo cp -r /home/alex/workspace/Thirdparty/Blender-28-Addons/oscurart_tools/ /usr/share/blender/2.91/scripts/addons
Then try to distribute 5 selected objects,but got error:
Needs at least two selected objects
and it seems this error occurred in old version.
https://blenderartists.org/t/oscurart-tools-update-rig-model-render-setting-more/576702/28
Try to use the last blender version.
Remember open the oscurart list in the properties menu.
No longer works with v2.93
No longer works with v2.93
yes. Only for builder version.
@arminhupka change distribute.py
to have this def:
def ObjectDistributeOscurart(self, X, Y, Z):
if len(bpy.context.selected_objects) > 1:
# VARIABLES
selection = bpy.context.selected_objects
dif = selection[-1].location - selection[0].location
chunkglobal = dif / (len(selection) - 1)
chunkx = 0
chunky = 0
chunkz = 0
deltafst = selection[0].location
# ORDENA
for OBJECT in selection:
if X:
OBJECT.location.x = deltafst[0] + chunkx
if Y:
OBJECT.location[1] = deltafst[1] + chunky
if Z:
OBJECT.location.z = deltafst[2] + chunkz
chunkx += chunkglobal[0]
chunky += chunkglobal[1]
chunkz += chunkglobal[2]
else:
self.report({'INFO'}, "Needs at least two selected objects")
Thank you! it worked for blender 3.6!