ScriptSpot

Forum topic · General Scripting

Scaling modifier gizmo

By Alen · 2011-12-19

Description

I'm having trouble forcing gizmo to scale in relation to its center (as described in max script help).

Here's the part of the code:

addmodifier $ (vSelect=Vol__Select level:2 type:1 autofit: false )
vSelect.gizmo.scale = vSelect.gizmo.scale*0.2

If I omit the second line the modifier will be placed in an object's center, but with the line modifier gets offset (as far as I can tell in a random direction, but constant for a given object) and offset is invertly proportional to the scale multiplier.

Anyone has any thoughts on this?

Comments (2)

br0t · 2011-12-19

works for me if I do it like this


vSelect=Vol__Select level:2 type:1 autofit: false 

addmodifier $ vSelect
vSelect.gizmo.scale = vSelect.gizmo.scale*0.2

Have you tried "Reset Xform" on the object before applying the modifier?

Alen · 2011-12-20

Unfortunately neither helped...