ZBrushCentral

Suppressing Show Actions

I’ve noticed that a lot of zscripts operate without showing the actions to the user, even if show actions is enabled in the zscript palette.

How do I do this for my own scripts? I’m working on one where showing actions would just slow things down dramatically, and I don’t want to require the user to uncheck show actions each time before running the script. I thought I could just do [ISet, ZScript:Show Actions, 0] at the beginning of the script then just set it back if it was set in the first place. That works, but then I have an unnecessary show action at the beginning for disabling show actions, and the script could also fail to restore the state if the user stops it mid-way.

Hi:)
To turn-off ShowActions, use the following ZScript command…[IShowActions,0]
To turn-on ShowActions, use the following ZScript command…[IShowActions,1]

This ZScript command allows you to turn-off the ShowAction without having to change the ZScript:small_orange_diamond:Show Actions switch.

Note1: ZBrush is counting the number of [IShowActions,0] and [IShowActions,1] which have been executed within your script.
Example: If you execute two [IShowActions,0] and one [IShowActions,1], actions will still be turned-off.

Note2: You do not need to execute [IShowActions,1] at the end of your script, ZBrush will automatically reset the ShowAction-counter when your script exists.

Tip: If you executing several commands and would like the result to only be shown at the end of the sequence, you may use the [IFreeze,] command. Example…

//----------------start of code---------------
[IFreeze,
// ZBrush will now disable screen-updates
[command 1]
[command 2]
.
.
.
[command n]
]
//Screen updates will now resume as usual
//----------------end of code---------------

Hope this helps,
-Pixolator

Thanks again for your help Pixolator!

There are a lot of commands that I have been unaware of. The reference I’m using is the one at http://pixologic.com/download/creating_zscripts/zs_coderef.html.It appears to be missing some things. Is there a more complete reference out now that I’m overlooking?

zs_coderef.html.
is Out Dated :cry:

CJM,

Print out your own up-to-date ZScript reference command list…

In ZBrush, press the ZScript/Export Commands button. There’s LOTS of interesting stuff in there,especially if you have not seen it yet.

Also, the ZScript/Cmd button lets you look at the same extensive commands list inside the ZScript window, AND shows some additional syntax examples you won’t find in the Exported Commands list.

Sven

it has no sample to try :cry:

Ooh thanks very much Sven. I overlooked that part of the Zscript palette, oops!