I have another question concerning this script. I modified it a littel and it´s allmost working. my aim is to point+orientConstrain an array of objects to another.
this is the code -
string $stem = "dupe_";
string $suffix= "_GEO";
string $dupeSel[] = `ls ($stem + "*" + $suffix)`;
string $Leaves[] = `ls -sl`;
int $selCount = size($Leaves);
for($i = 1; $i <=$selCount; $i++)
{
int $dupeInt = rand(0, size($dupeSel));
$dupeInt++;
string $new[] = `duplicate -rr ($stem + $dupeInt + $suffix)`;
pointConstraint -offset 0 0 0 -weight 1 ($leaves)($new);
orientConstraint -offset 0 0 0 -weight 1 ($leaves)($new);
}
problem as you might have allready seen - the duped leaves get constrained, but only to the very first object in the list (string $Leaves[] = `ls -sl`; ). probably this command has to be changed, but I don´t know how to make use of all items of that array. I´m really stuck now.
tia!
everything starts and ends in the right place at the right time.
Last edited by Falott; 07-08-2007 at 01:50 PM.