Hi all
As we're redoing all lights in our scenery, we don't want to "waste" too much time manually adding attachpoints. We found the little script for renaming effects in the wiki, but of course it doesn't work for objects.
Do you have any idea if it's possible to make a similar script to rename objects instead of effects?
The script from the wiki:
I think the following part has to be changed:
A first try, but doesn't work. Actually I'm a bit confused about the "name", which is the GUID but there has to be another name in it:
Best Regards
Remo Eugster
As we're redoing all lights in our scenery, we don't want to "waste" too much time manually adding attachpoints. We found the little script for renaming effects in the wiki, but of course it doesn't work for objects.
Do you have any idea if it's possible to make a similar script to rename objects instead of effects?
The script from the wiki:
Code:
strAttachNumber = 0
for obj in $box* do
(
obj.name = ("attachpt_MyEffectName" + (strAttachNumber as string))
strBufferText = ("<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?> <FSMakeMdlData version=\"9.0\"><Attachpoint name=\"attachpt_MyEffectName" + (strAttachNumber as string) + "\"> <AttachedObject> <Effect effectName=\"fx_MyEffectName\" effectParams=\"\"/> </AttachedObject> </Attachpoint></FSMakeMdlData>")
setUserPropBuffer obj strBufferText
strAttachNumber += 1
)
I think the following part has to be changed:
Code:
<Effect effectName=\"fx_MyEffectName\" effectParams=\"\"/>
A first try, but doesn't work. Actually I'm a bit confused about the "name", which is the GUID but there has to be another name in it:
Code:
strAttachNumber = 0
for obj in $box* do
(
obj.name = ("attachpt_MyEffectName" + (strAttachNumber as string))
strBufferText = ("<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?> <FSMakeMdlData version=\"9.0\"><Attachpoint name=\"attachpt_MyEffectName" + (strAttachNumber as string) + "\"> <AttachedObject> <LibraryObject name="526FE61F7FA240F1A249807746236CD4" scale="1.0"/> </AttachedObject> </Attachpoint></FSMakeMdlData>")
setUserPropBuffer obj strBufferText
strAttachNumber += 1
)
Best Regards
Remo Eugster
