PDA

View Full Version : ApplyServer, applying settings on creation?



Red_Oddity
01-16-2008, 01:24 PM
Is it possible to have ApplyServer send initial settings to the added plugin?

So is it for example possible to have ApplyServer("CustomObjHandler", "LW_ItemShape"); change the item shape to box and give the label a text?

Lightwolf
01-16-2008, 01:43 PM
Nope, I wish...

Cheers,
Mike

Red_Oddity
01-16-2008, 02:10 PM
Drat...i can't seem to find any simple way (besides saving and parsing the LWS file and reloading it again) to change that data...

That's a shame, it kinda makes this command useless for mass editting and applying plugins in a workflow, i mean, i still end up with a couple of hundred plugins that need to be editted piece by friggin' piece (man, i so wish LW was as open as Maya at times)

adamredwoods
01-17-2008, 07:34 PM
The way I do it is my CustomObject plug reads a file when Create_ is activated and sets its values to that.

My other "AutoRig" program creates and modifies the file.

faulknermano
01-18-2008, 10:34 PM
Drat...i can't seem to find any simple way (besides saving and parsing the LWS file and reloading it again) to change that data...


you can avoid the reloading aspect, but you do have to get your hands dirty on scene writing. if you code it right you may be able to make these plugin parameters apply to many other plugins.

using your example, use lscript to output a scene file with using a null that has ItemShape attached to it. of course, the lscript should ask user input for varios parameters (you'd have to study the plugin's parameters). then you execute a LoadFromScene in the same script, and for as many times as you need.

faulknermano
01-18-2008, 10:42 PM
edit: uh, not really what you originally wanted (e.g. apply settings onto existing objects), but it's pretty close i think.

Red_Oddity
01-19-2008, 05:17 PM
Hmmm...actually, that might be handy in some situations though.