FamilyCloneGN (LScript version 2.2)
written by faulknermano, Lernie D Ang

 

BRIEF

FamilyCloneGN v1.2 has been modified from v1.01 and v1.1 to include two extra 'Formation Modes.' The random jitter also works for all Formation Modes as long as there is something greater than zero (the default value) inputted there. Lastly, there are three 'main modes' that dictate the validity of the formation modes. I'll explain that below.

 

 

Main Modes

1. Cloner - this tells FCGN to clone and formate based on the selected Formation Mode.

2. Arrayer - this mode tells FCGN not to clone. It takes the currently selected objects and applies the selected Formation Mode to them.

Some stuff you would like to be aware of when using the Arrayer:

a. When using it with the Mirror formate, FCGN will distribute the objects as evenly as it can across the mirror axis alternating between selections.

b. When using it with the Radial formate, FCGN will take note of the first selected object and use that as the reference point for constructing the circle around the axis point.

c. When using it with the Array formate, FCGN will try to allot the X, Y, and Z axes instances that have been inputted in the fields in that same order of importance. Thus FCGN will populate to satisfy the X axis first, and upon achieving that, will go on to the Y axis, and then finally to the Z axis.

3. Rename - this mode cancels all cloning and formation functions of FCGN. Only the renaming functions are valid. Note that you must still activate the checkbox on the Rename Panel for the renaming function to work.

 

Formation Modes

These Formation Modes are only valid (e.g. effective) when the Main Mode is either on Cloner or Arrayer.

1. Normal - this clones the selected parents and their family but does not modify their position.

2. Mirror - this clones one (1) instance per selected object and mirrors the clone across a specified axis and center location. You may input the values by hand, or you may optionally select a current Layout item as a reference item for those values. The Position and Rotation checkboxes instruct FCGN which parameter(s) will be affected by the mirroring.

3. Radial - this clones the selected parents and their family and offsets the clones so that it forms a circle around the specified center of the specified axis. You may manually input the values or you may select an existing Layout item as the reference point. This function works identically to Modeler's Radial Array command.

4. Motion Path - this formation mode will take an existing Layout item's motion path and will clone the selected heirarchy(ies) to conform to that path. Unlike the Mirror and Radial Formation Modes, this one absolutely needs a reference item to denote whose object's motion you wish the follow. To use Motion Path input your desired number of clones, then enter what frame you want to start and end on on that path.

There are are two sets of choice boxes namely WLD, LOC (Position) and Copy, Orig (Rotation).

a. WLD - this will formate the clones directly on the motion path using world coordinates.

b. LOC - this will formate the clones relative to the cloned heirarchy's position.

c. Copy - this option will get the actual rotational values stored in the motion path.

d. Orig - this option will use the selected object(s) own rotations.

A tip using Motion Path: you can set Align to Path for the object travelling down the motion path and FCGN will pick it up. This will then have the same effect as Modeler's Rail Clone with auto-orientation applied.

4. Dump File - this option enables you to set a custom formation using points in Modeler. To do this you must first go to Modeler, set up your points and run FCGNDumper. This will save out a specially-formatted file containing point information. Back in Layout, FCGN will translate that file and clone/formate your selected items or heirarchies based on that.

Note that when you save out your dump files in FCGNDumper, the filename is globally stored and FCGN will pick it up. This saves you the hassle of trying to go through your directories on load time.

 

Rename Panel

The Rename Panel is straightforward. Type in the string you want to find, and a replacement string to replace it. Check the box to activate the function. Do remember that only lights, cameras, and null objects can be renamed. FCGN will ignore any attempt to rename a mesh object.

One worthwhile note: if Mirror is active, the renaming function will only rename the clones and not the originally selected object. This does not apply to the other Formation Modes, where even the original selected object will be renamed based on the search results.

 

Random Jitter

As mentioned above, Random Jitter will now affect all Formation Modes as long as they are valid (e.g. Main Mode set to either Cloner or Arrayer). Values are additive. If you do not want to jitter your clones, be sure to have all of the fields at zero (0) before you execute.

 

Clone Limit Warning Confirmation

This is just a fail-safe to make sure you do not create more clones than you originally intended. It is helpful to have this box always checked just in case as it will warn you if you FCGN is being told to produce a large number of clones. When the warning dialog box shows, you have the option of setting a new warning limit.

Unchecking the box will bypass the warning confirmation.

 

LIMITATIONS

The current version does not, repeat, does not support bones fully, and does not support bones with goals at all. Because bones are cloned 'en masse' unlike mesh, light, and camera items, this has presented a couple of sticky problems that I hope to resolve at the next revision.

Be aware of another limitation when keeping targets and/or goals when using the ARRAY function. The limitation is that the target or the goal must be part of the heirarchy you are wishing to clone. If it is outside a heirarchy which contains the item that is targetted/goaled to it, FCGN will not recognize it and target/goal it to the original item.

If you have problems running FCGN or find bugs, please contact me at faulknermano1@yahoo.com

 

Thanks to:

Craig Paup for suggesting the Create Key At feature.

Yoko for giving me the first heads-up on an FCUGN v1.01 interface problem and going through with me to fix it.

Peter Aquinde for lending me his light rig for testing, for testing FCGN v1.1 itself for integrity and bugs, as well as suggesting three of the new features in v1.2 namely the Mirror and Motion Path Formation Modes and the Renaming function.

 

***APPENDANT (06.10.02)***

I modified the Mirror formate so that the children of the selected item is mirrored in relation to the parent. Originally, only the parents were mirrored along the axis. Thanks to Peter Aquinde for suggesting this.

 

***APPENDANT (02.07.03)***

I've revised FCUDumper to output four types of data from LightWave geometry:

1.) Point Locations: the usual point coordinates.

2.) Point Normals: outputs the points coordinates and the point normal as based on the average polygon normals around that point. I am not educated on how one truly solve for point normals, so this may be just a hack.

3.) Polygon Centers: takes the center of each polygon and uses those coordinates.

4.) Polygon Normals: outputs the coordinates of the center of each polygon along with that polygon's normal.

These new options of FCUDumper will require FamilyCloenGN v1.2.1.

 

***APPENDANT (02.18.03)***

I've improved the code for Polygon Normal. Previous results were screwed up rotation when the dump file was used in Layout.