Here’s a tool for Maya that is similar to a multi-path constraint in Softimage. Make a new scene, create a curve, create a few objects to attach to the curve, select the objects, and run the script below.
string $selection[] = `ls -selection`;
int $size = size($selection);
//change this to your curve name
string $path = "curve1";
for($i=0; $i<$size; $i++){
float $uLinearDistribution = 1.0/$size*($i+1);
float $uRandomDistribution = rand(0,1)/$size*($i+1);
//print ($uRandomDistribution+"\n");
string $motion = `pathAnimation -f 1 -fm 1 -etu 0 -c $path $selection[$i]`;
string $source = $motion + "_uValue.output";
string $destination = $motion + ".uValue";
disconnectAttr $source $destination;
setAttr ($motion + ".uValue") $uLinearDistribution;
//setAttr ($motion + ".uValue") $uRandomDistribution;
}
There's an option for random distribution, just disable the comment. There's no error checking, so use at your own discretion/peril. Each object will have it's own MotionPath node, so check the Attribute Editor for more info.
This will come in handy when we create grapes in the Intro to 3D Modeling course.