Rotation/Scale Pivot

I have two joints. One is grouped unto itself. Through Mel I am trying to move the rotation/Scale Pivot postition of the group to the other joints pivot. If I were to do this manually I would hit insert and moving the pivot point to the center of the other joint by using snap to point. Any ideas on how to do this. I have been having terrible luck. heh. Anyway, any help would be apprectiated. Thanks in advance.

Walter Behrnes
Digital Sculptor
http://www.polyextrude.com

First selec tthe object that you wish to snap the pivot point to and then shift select the second object whose pivot is being modified.

//------start

string $sel[]=ls -sl -fl;

float $tx=eval("getAttr "+$sel[0]+".tx");
float $ty=eval("getAttr "+$sel[0]+".ty");
float $tz=eval("getAttr "+$sel[0]+".tz");

eval("move -a $tx $ty $tz "+$sel[1]+".scalePivot "+$sel[1]+".rotatePivot") ;

//--------end

Just curious....why use eval all the time. Wouldn't just the following script do the job.

string $sel[] = ls -sl;
float $pos[] = xform -q -ws -t $sel[0];
move -a $pos[0] $pos[1] $pos[2] ($sel[1] + ".rotatePivot ") ($sel[1] + ".scalePivot");

Ragnar

You are absolutely right.. bad habit