string $selE[] =`ls -sl -fl`; int $selTyp = `selectType -q -meshComponents`; string $temp[]; tokenize $selE[0] "." $temp; string $theObj = $temp[0]; polyUVSet -create -uvSet "TempWWWUvSetB" $theObj; polyUVSet -currentUVSet -uvSet "TempWWWUvSetB" $theObj; int $fObj1[] = `polyEvaluate -f`; string $ffObj = ($theObj+".f[0:"+$fObj1[0]+"]"); select -r $theObj; polyProjection -ch 1 -type Planar -ibd off -kir -md z $ffObj; polyMapCut -ch 1 $selE; select -r ($theObj+".map["+$fObj1[0]+"]"); polySelectBorderShell 0; string $shUV[] = `ls -sl -fl`; string $myFaces[] = `polyListComponentConversion -fuv -tf -in`; select -r $myFaces; polyUVSet -uvs "TempWWWUvSetB" -delete; hilite -r $theObj; if($selTyp == 1){ selectType -meshComponents true; }else{ selectType -pf true; }
Replies