With this MacroScript you can stack any objects randomly into anything you can imagine. It's been used to make neighborhoods of houses and low-rise apartment blocks, or in the case of our tutorial, a dystopian fantasy favela.
See the below video for an overview of what it does.
- In Windows Explorer copy the Macroscript into the 3ds Max\Scripts\Startup folder.
- Open 3ds Max.
- Open Customize User Interface and select Toolbars.
- Under Catagory, select 3Disciple Magazine.
- Select StackUp and drag to a Toolbar to create a button.
- Unzip or copy the folders into your project or 3D asset library.
- DO NOT change the Folder Structure or Subfolder Names or StackUp will not work.
You can rename the ROOT FOLDER!
If you choose to make your own models to use with StackUp follow the above guide for each StackUp type and you'll be fine. For example, 'Modern suburban houses', 'Apartment blocks', 'Retail shops' etc.
StackUp works by importing 3D models from set folders and stacks them based on the parameters you set, from single story to 4-story plus roofs. Depending on how many models you place in each corresponding folder determines how random your final stacked model will appear. For example, if you have 1 x model in each folder there will be no variation, whereas 10 x different designed models per folder will look more random and awesome!
The script requires that each model fits within identical width and height dimensional boundaries. This allows StackUp to build the imported stack using set width/height parameters. The depth of models isn't affected, nor is the roof heights as these 'cap' the stack.
- Make sure all 3D models are collapsed to 'single edit mesh' and materials converted to a 'single unwrapped UVW map', for each model.
- All collapsed models pivot points must sit at coordinates 0, 0, 0 (X,Y,Z). This allows StackUp to import them correctly.
StackUp places imported 3D models into a grouped stack generated at a set distance, placed along a single or multiple splines.
The splines MUST be converted to an editable spline to work. If you create a shape and apply the script to this, it will crash. Close the script and reopen it, if it does!
- Open the script by clicking the button on the Toolbar.
- Select the spline or splines you wish to generate StackUp to. As this is a script and not a plugin*, it can take some time to create if these are long splines so be sensible. We advise creating one or two at a time!
Select Model Files
- To use Auto Path, select the main folder directory. StackUp automatically selects the sub-folders in this directory. Please note DO NOT change folder names or StackUp will crash.
- Select the number of floors to stack. Currently only 1-4.
- Check the 'Create Random Number of Floors' if you wish to generate a random layout.
- Set the Width and Height dimensions of all your models. The preset is set to the tutorial width of 5m wide and 3m in height. Please note the maximum size is 99 units (widge and height).
- The Depth axis is set by default to Y.
- Tick 'Display object in box mode' if you are creating a complex scene.
- Random Scale Range add a small variation in scale to each model. Range 0.1 to 2.0. Default 0.
- Position of StackUp on Path. Sets the layout pivot point to being Inside, Centre or Outside.
Model Material Options
- Self-explanatory. Instanced or Unique.
- Click to generate. It may take some time depending on the length of spline and complexity of the above parameters. Be patient on big scenes!
HAVE YOU CHECKED YOUR PATH SPLINE?
Can I create my own models?
- Absolutely! That's the intention. Just make sure you follow the guidelines above and point the script to your new project directory.
Can I adapt the script for my own use, add floors, etc?
-Yes you can. I developed this script years ago for a production project and it's been sitting on the 'virtual shelf' gathering dust. If you know MAXScript please adapt as you wish. We've given it a bit of an update for the 3Disciple tutorial and removed some of the other bespoke functions. We have no plans to update it, so use it as is.
What happens if it crashes?
If you don't follow the steps above and it crashes, then close the script and reopen it.
*What are the differences between MAXScript and Plugins?
In general terms, MAXScripts and MacroScripts can only use one processor. Plugin developers, such as SiNi Software, write code in C++ which is a much more powerful coding language, able to send functions outside of 3ds Max to utilise all your system processes, similar to render engines. The end results will look the same but it will take more time getting there!
What the terms and conditions of use?
Please see the terms included with the downloaded Tutorial.
In simple terms, use it as you wish, use it as is, including any faults, bugs or defects. You cannot claim copyright or resell. However you can modify the code, for your purposes only, but we are not liable for anything. You should be fine if you play nice.
Please go enjoy and have fun making crazy things!
With this simple MAXScript by Vojtech Cada you can create catenary curved splines, perfect for cables, ropes etc.
Catenary comes free with the StackerWorld training project.
See the below video for an overview of what it does.
We've used CATENARY extensively in environment 3D modelling to add cables.
Save the MAXScript into the Autodesk 3ds Max/Scripts/Startup folder.
CATENARY is located on the side Create/Splines Rollout.
- Click on the dropdown and select 3Disciple Training.
- Click on CATENARY to run.
Click anywhere in a viewport to begin drawing catenary splines. Under the Parameters tab adust the Sag height. Under Sag Variability adust the randomness between points.
IMPORTANT - You need to create manual CATENARY splines first before changing to By Object. Click in the viewport and create a few sagging splines. Then in the Corner Placements rollout, switch to By Objects. Click the 3 dots button and select the objects you wish to generate catenary splines from. The script automatically swaps from Manual to By Object. Tip. You can move these objects and CATENARY will follow.
This script has been modified from the original MAXScript written by Vojtech Cada.