try texGetShells. its located in C:\Autodesk\Maya20XX\scripts\others\texGetShells.mel its a hidden mel script thats not documented. Its being used in a lot of the functions inside uv toolkit. I have been digging around that folder for some hidden cmds for mu UDIM layout script ive been working on forever.
I'm trying to select UV shells by index and then run some code and then select the next UV shell and run that same code, etc. Imagine if you wanted to scale each UV shell by 50%, that's not what I need to do, but if I could figure out how to select each shell one at a time in the script that would solve my problem. Is this…
Interesting, any idea why trying to store this in an array and then select it errors?$tempShell = `texGetShells`; select $tempShell;// Error: line 1: Invalid attribute name: pPlane1.map[1] pPlane1.map[5:6] pPlane1.map[11] //
Okay got it working. Here is the code, just replace the polyEditUV line with whatever custom code you want to run on selected UV shells. ConvertSelectionToUVShell; $shellUVs = `ls -sl`; $findShells = `texGetShells`; $numbShells = `size $findShells`; $shellIndex = 0; for ($item = 0; $item < $numbShells; ++$item) { select…
Update, someone from the Autodesk forum was able to figure out how to convert the first shell in the array so you can select it, now I need to work on storing each shell into it's own array to loop through and run my code on which I think I know how to do using the size command and a counter. Will report back if I get it…