copy object with unique name + only 2 digits
Really confused with this one. Tried lots of varients now, but cant seem to work out what's going wrong. Say you have a Box (it's name "Box_01", only 2 digits not the normal 3). I have written a few lines of code to copy this node and give it a unique name but I only want to stick to the original 2 digit suffix i.e "Box_02, Box_03" etc.
Please can you have a quick look and see if there are any obvious mistakes. Currently the new copy jumps from "Box_01" to "Box_03 then "Box_05" etc!!!!
newObj = copy $
newObj.name = uniquename $.name numDigits:2
Many thanks in advance!!! :-)