PDA

View Full Version : Copy paste plugin on selected objects?



Dennik
05-07-2011, 06:38 AM
I need a plugin that has this functionality, when I copy a plugin on the buffer, to be able to paste it on the selected list of objects.
Please help me do this.

jeric_synergy
05-10-2011, 01:57 AM
You're going to have to explain that need better than that. Details!

Dennik
05-10-2011, 02:27 PM
You're going to have to explain that need better than that. Details!

Well my first thought was to use a text editor and regular expressions.
But I've no idea which editor could be able to grab blocks of code from the scene file and replace it with something else. Neither do I know the regex syntax for that.
As for making it an actual plugin again my SDK knowledge is next to zero.
My guess is, an external program just reading the scene file, would have better chances of doing this.
For example, have a selection list of many objects. Then take plugin from source object and copy it to all objects on the selection list. This should be fairly straight forward, as long as the various plugin blocks can be identified and isolated.

Cryonic
05-12-2011, 09:33 AM
Well my first thought was to use a text editor and regular expressions.
But I've no idea which editor could be able to grab blocks of code from the scene file and replace it with something else. Neither do I know the regex syntax for that.
As for making it an actual plugin again my SDK knowledge is next to zero.
My guess is, an external program just reading the scene file, would have better chances of doing this.
For example, have a selection list of many objects. Then take plugin from source object and copy it to all objects on the selection list. This should be fairly straight forward, as long as the various plugin blocks can be identified and isolated.

That sounds like something for an external program to do. The scene files are just text files. Perl or Python should be able to read those files, then it is just a matter of parsing the text to figure out what you need to copy where. There doesn't appear to be any existing Perl modules for Lightwave scene files on CPAN.

Dennik
05-12-2011, 09:40 AM
The more I think about it, this could get complicated with interconnecting or nested plugins that share values (plugin within the channel of another plugin).
I haven't studied the scene structure but even Lightwave I noticed makes mistakes when copying plugins. Sometimes it makes a mess with the motion plugins inside Graph editor.