ScriptSpot

Forum topic · General Scripting

scale an object in the coordinate system of another object.

By Any · 2019-01-22

Description

Hi everyone

There is the box $Box001 and the point $Point001 in the scene.
if you write such an expression

scale $Box001 [2,2,2],

the box is scaled relative to the PIVOT point.
But if we translate the coordinate system,

toolMode.coordsys $Point001
max scale

then when you scale the box $Box001, there is both a change in scale and position of the box, relative to the point $Point001.

Is there a way to record such a transformation programmatically?

For example

in coordsys $Point001 $Box001.scale = [2,2,2]

But this way of writing only changes the scale...

Comments (2)

Any · 2019-01-22

Thanks so much, Jahman!!!

.

jahman · 2019-01-22

use about context