put pivot to centre of object and X - 0

Hi,

wanting a script to centre pivot of object and put it to X=0.

It ends up beings a three click process...script to simplify please.

thx

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
airbrush's picture

thx

thx

miauu's picture

.

This will works for selection of objects.

(
	if selection.count != 0 do with redraw off
	(
		CenterPivot selection
                selection.pivot.x = 0
                -- if you want to use a loop
		-- for o in selection do o.pivot.x = 0
	)
)
airbrush's picture

sorry..yes. world X position

sorry..yes. world X position i meant

miauu's picture

.

What X - 0 means?
World X or something else?
Can you show a picture?

-- put the object's pivot to objhect's center
centerPivot selection[1]
-- move the object's pivot to world X = 0
selection[1].pivot.x = 0

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.