Weird CGA rule: How does this work?

2606
2
04-07-2016 07:33 AM
PhilDesrosiers
New Contributor

Poking around in the "Pompeii" example​ , I found this line in pompeiiStreets.cga (line 55):

split(x){ stoneLength*rand(0.8,1.2): Stone | RollingStones }

I'm pretty new to CGA in general, but the docs on the split operation don't mention the possibility of a successor block without a size (as in "RollingStones" above). What will happen when this line runs? Is "RollingStones" just the shape successor for "all the remaining geometry" after the split?

0 Kudos
2 Replies
LR
by
Occasional Contributor III

Must be old code, that doesn't work anymore. It should be ~1: RollingStones.

0 Kudos
CherylLau
Esri Regular Contributor

I downloaded the code from the link you sent (and also from within CE by going to Help -> Download Tutorials and Examples), but I have something different on line 55.  The code you mention appears on line 98 instead, and it has a ~1 as Z R​ mentioned.

split(x){ StoneLength*rand(0.8,1.2): Stone | ~1: RollingStones }

0 Kudos