Wednesday, 13 March 2013

Center Pivot (or bottom-center)

99% of all obects I make I want the pivot to be at object-center or object-bottom-center (min z). I got tired of using the transform toolbox to do this, so here we are...

  • You want to center (or bottom-center) the pivot of one or more objects
  • A button to do this would be splendid
  • Select one or more objects
  • run script once to center pivot
  • run again if desired to bottom-center

-- MixeScript snippet: Center Pivot 
-- Centers pivot. if run again, will bottom-center pivot.

-- select one or more objects
-- run script
-- centers pivot, or if already centered, places at min z

for obj in selection do
if obj.pivot != then (
 obj.pivot =
) else (
 obj.pivot =
 obj.pivot.z = obj.min.z

1 comment: