Infraworks: Javascript to Randomize Species and Height

What it Does and Where to Paste It


The script below is to replace the default tree feature script that is in the "Script" tab of the data source configuration. 
  • Adjust percent chance of tree type by modifying the if condition (Math.random() > 0.5)
  • Set the base line scale factor for each tree type by modifying the scaleFactor variable.
  • Set how much variance you want to allow by modifying scaleVariationMax variable.

The Script:

I hope you find this useful.

Comments

Post a Comment

Popular posts from this blog

Alignment to Polyline: How to Make a Polyline Copy of an Alignment or Profile

The XLIST Window is too Narrow!

How Can I Freeze the Alignment but Keep the Alignment Label?