Constructor
new(?path:IPath, ?meshes:Vector<Mesh>, ?scene:Scene3D, repeat:Int = 1, alignToPath:Bool = true, segmentSpread:Bool = true, ?container:ObjectContainer3D, randomRotationY:Bool = false)
Creates a new PathDuplicator
Class replicates and distribute one or more mesh(es) along a path. The offsets are defined by the position of the object. 0,0,0 would place the center of the mesh exactly on Path.
Parameters:
path | [optional] A Path object. The _path definition. either Cubic or Quadratic path |
|---|---|
meshes | [optional] Vector.<Mesh>. One or more meshes to repeat along the path. |
scene | [optional] Scene3D. The scene where to addchild the meshes if no ObjectContainer3D is provided. |
repeat | [optional] uint. How many times a mesh is cloned per PathSegment. Default is 1. |
alignToPath | [optional] Boolean. If the alignment of the clones must follow the path. Default is true. |
segmentSpread | [optional] Boolean. If more than one Mesh is passed, it defines if the clones alternate themselves per PathSegment or each repeat. Default is false. |
container | [optional] ObjectContainer3D. If an ObjectContainer3D is provided, the meshes are addChilded to it instead of directly into the scene. The container is NOT addChilded to the scene by default. |
randomRotationY | [optional] Boolean. If the clones must have a random rotationY added to them. |