ZBrushCentral

Help on Transformations

Hello everyone,

I’m writing a script that requires moving an object around the canvas.
At first I tought this would be trivial , but when using the [ISet,ToolDeformation:Offset,24]
command to do the job, I found that there’s nothing in this command that says that this is for either X, Y or Z.

I did a test and turned all X,Y and Z OFF. Then I turned them all ON one after another and got this…
[IModSet,ToolDeformation:Offset,1]
[IModSet,ToolDeformation:Offset,3]
[IModSet,ToolDeformation:Offset,7]

Question : What do the numbers 1,3 and 7 stand for?
Is it ALWAYS 1,3 and 7 for X,Y and Z ?

Testing futher I noticed that this not always the case.
Sometimes when I press the Y button ON I get [IModSet,ToolDeformation:Offset,2]
Notice the 2…

Can anyone help me with this?

How can I do multiple offsets ( In any X,Y,Z direction ,say at random ) on an object , in the simplest way?

Sorry for the confusion and Thanx for your Help.

The values you should use are X = 1, Y = 2, Z = 4. You can have combinations of axes which is why you are getting the values 3 (X and Y both on) and 7 (X,Y and Z on).

However, if you use Deformation:Offset you are moving the model in world space, not simply around the canvas. If your model has subtools you will need to repeat the offset for each subtool.

If all your want to do is move the model around the canvas then you can use the TransformSet command. The first two parameters are the X and Y screen coordinates in pixels. (Z, the third parameter, will remain at zero for a 3D model in Edit mode.)

http://docs.pixologic.com/user-guide/customizing-zbrush/zscripting/command-reference/#TransformSet

Hello Marcus ,

TransformSet was the first command that I tried. Unfortunatly the only thing that happened when I used
this command was that the canvas went blank and my tool/mesh would reappear only after clicking on the
canvas.Unless I’m missing something, this command is not really what I’m looking for at this point.
( Also, as you clearly pointed out, with this command , things are only moved about on the canvas
as opposed to real 3D space transformation which is what I’m looking for.)

Elsewhere, [ISet,ToolDeformation:Offset,value] is now doing the job I’m looking for with X = 1, Y = 2, Z = 4.

Thank you for pointing this out and thank you for making scripting easier for all of us .