fCraft.Forester.ProceduralTree.ShapeFunc C# (CSharp) Method

ShapeFunc() protected method

protected ShapeFunc ( int z ) : float
z int
return float
            protected virtual float ShapeFunc( int z )
            {
                if ( Args.Rand.NextDouble() < 100f / Sqr( Height ) && z < TrunkHeight ) {
                    return Height * .12f;
                } else {
                    return -1;
                }
            }