ZBrushCentral

Include Zscripts like Header and Source files?

I swear I read something before that lets you include text files into your scripts like how you have a header file and your source files in c++ i just cant remember where I saw it or exactly what its referred to inside zscripting.

Anyone have any experience with that?

Yes, you can use <zscriptinsert>:
http://docs.pixologic.com/user-guide/customizing-zbrush/zscripting/command-reference/#zscriptinsert

Thats what it was.

Do you know the limitations of it? Can you insert UI elements like buttons and things? Or is it just all strictly pure code?

There aren’t any limitations. Whatever you can put in a zscript you can have in the zscriptinserted zscript. It’s really just like copying-and-pasting code at that point.

It’s useful if you develop routines that you use often. For example, to check for a polymesh is in Edit mode, or do some subtool operations.