I am making something like a "Tiled Mesh Helper" that arrays the mesh for you. I wanted to add a function that you could check how the mesh tiled. I know there are multiple ways to do this... but I am not sure how best to do it via script. There is probably an easier way that I just can't think of. I am not super experienced with the 2D tools in ZB.
My first thought was just basically the "pattern fill" in Photoshop. I make the canvas smaller and take a snapshot, then restore the doc size and then fill the canvas with that texture. BUT when you fill the canvas ZB stretches the texture to fit the canvas.
My next thought was just to drop the mesh to the canvas over and over again with an offset equal to the X/Y dimensions.
I also thought about using the 2D layers offset because it may be faster and manipulating a mesh...
Spotlight basically has this feature... but it's not scriptable that I know of? I also don't know if you can get the tiled texture out of spotlight without painting it on something. Bah! Ramblings!
If you reduce the size of the canvas, then use Transform>Fit to fit the mesh, you can grab the scale from the TransformGet values. Then scale your document back up and use TransformSet to set the scale and position, using Transform>Snapshot for each iteration.
Note: as the 'Fit' tends to make the model a bit large you may want to adjust the scale a bit, or give the user some means to do so.
[CODE][IButton,"Resize Canvas","Resize canvas and reposition model",
[If,[IsEnabled,Transform:Edit],//if there's a 3D tool selected
[If,[IGet,Transform:Edit],//and if it's in Edit mode
//get the transform values of the model
//resize the document - the keypress stops warning message appearing
//redraw the model
//reduce scale slightly
I've used the Document:Half for simplicity but you can turn off 'Pro' and set the doc size to what you want before pressing 'Resize'.