ScriptSpot is a diverse online community of artists and developers who come together to find and share scripts that empower their creativity with 3ds Max. Our users come from all parts of the world and work in everything from visual effects to gaming, architecture, students or hobbyists.
I have a scene with with 1,400 single objects each within it's own group. the objects are named object001. 002,003 etc etc, and the group has the name I want the object to be.
Is this possible via maxscript ?
how about this ?
To rename all object inside, inside ... groups by main group name
-- firts rename all by group witout numbersfor g in objects where isGroupHead g dofor o in g do o.name = g.name
-- collect unique names array
uNames = #()for o in objects where isGroupHead o == falsedo appendifunique uNames (o.name as name)
uNumbers = #()for i = 1 to uNames.count do uNumbers[i] = 0--add numbers to the same namesfor o in objects where isGroupHead o == falsedo(if(a = findItem uNames (o.name as name))> 0 then (
uNumbers[a] += 1
o.name = o.name + (formattedPrint uNumbers[a]format:"0.3d")))
Just quick idea... please test it and let me know how it works.
Best,
Pixamoon
Comments
`
how about this ?
To rename all object inside, inside ... groups by main group name
Just quick idea... please test it and let me know how it works.
Best,
Pixamoon
...
I will use example of previous mentioned thread by DenisT.
Here you have groups inside group and some of theses are just linked to each other.
bga