Zbrush Import/Export Script

Hi guys

i dont have much info about scripting, I have this script for zbrush import/export, its for windows and I’m using Mac osx, i tried to use it on Mac but apparently only “Obj out”(export) works fine but the “Obj in”(import) Dosen’t work, can anyone help me to rewrite this script for Mac ? i tried it on windows and it worked fine.(btw i tried to fix it by changing the location of the folder to match Mac path )

Copy the 2 files into your Zplusg64, and the two button will show on your right button on you zbrush screen.

Thanks in advance !

I don’t think this can work on Mac at all in the current shape since paths seem to be a funny thing on the ZB OSX version (at least up to 4R8 which is the most recent one I’ve used). Just putting in a Mac filesystem path will not do in my experience.

You could try this:

Make a directory in your user folder to store the OBJ file in that does not contain spaces or special characters in the filename. Lets name it “/Users/alihh12/objs/” Put a valid obj file named “1.obj” there as well - in my experience the Mac version crashes instantly if you feed it a path that does not exist.

Then - I can’t test this atm but looking through my own mac-related ZStartup scripts - replace line 9 in your script with this one
[VarDef, Object1, “ZBRUSH_\objs\1.obj” ]

Make a symbolic link in your filesystem to the folder you just created in the ZBrush install directory. For that use Terminal(.app), “cd” to the ZB installation folder under /Applications and from that ZB directory use

ln -s /Users/alihh12/objs/ ./

That should create a symlink called “objs” right in the ZB folder. If you are unsure about what this does, check google to learn more or read this: https://www.howtogeek.com/297721/how-to-create-and-use-symbolic-links-aka-symlinks-on-a-mac/
Still from the ZB install directory use

ls -al

and check the output, you’ll see the symlink appearing in the file list like so objs@ -> /Users/alihh12/objs/ . In Finder it will look like a shortcut.

Now place your script where it’s supposed to be (and launch the application and see if it shakes out.

Here’s a revised version of the script. When you first press a button it will ask you for a file name. This is so you can set the file name and location to what you want. Once that’s set the buttons will export or import without more input. There’s also a third button called “Reset” which simply deletes the saved file path. Pressing one of the other buttons will then give you the file dialog again so you can choose a new name/location.

Be sure to delete the old version. The zscript text file is included in the zip.

ObjOut_rev.zip (2.95 KB)

HTH,ObjOut_rev.zip (2.95 KB)

Hey marcus

i tried your script but apparently there is a problem in it , when i tried to import or export the mac give me this message:

file error Sorry, the disk space is critically low. Please clear more disk space (by emptying the trash, deleting files, etc.) and then click OK to resume.

maybe its a path script problem ? btw i picked the folder location and followed your instruction and i do have a lot of space on my mac.

Thank you again for helping

sorry for my english


I guess you are trying to use the script in an old version of ZBrush. It will only work with ZBrush 2018.1. (Upgrades are free to registered users.)

Thanks for the tips. I confirm it was a versioning issue.

Alexandra from W2C