PDA

View Full Version : Can Lscript do this?



daddda
01-25-2010, 10:28 AM
Hello everyone! Yes, I'm brand spanking new to this forum and boy do I need some help.

Okay, I've created a 3D application on my own in Windows .NET that creates customized 3D objects in WPF. It all works fine and dandy except that I need to be able to affectively share these objects with other 3D applications like Lightwave3D, which I have been using off and on for nearly 15 years. During that time I've created a number of simple Lscript plugins to become fairly familiar with how it works as well as LSID for GUI creation. (Nothing like .NET Forms, but doable.. yet frustrating)

What I've accomplished so far on my current project is an Lscript plugin that executes (spawns) a .NET executable which dumps raw 3D data out to a txt file. (points, faces and color) Lscript then processes that data, by reading the text file, and recreates the 3D object. The Lscript script currently passes origin and scaling information as arguments to the .NET executable so that the object has a place to center itself. Not what I ultimately want however... read below.

Given my explanation above, my questions are...

1. Does Modeler allow an Lscript plugin to create it's own cursor graphic?

2. Can my Lscript GUI window remain open while I create points on Modeler's grid which would then show up on some display control on the Lscript GUI window? (this is why I'd like to change the cursor graphic)

3. Can I create my own drawing support graphics in Modeler that assist the user in aligning/creating points on Modelers grid? An example would be, let's say my plugin draws multi-tiered wedding cakes (which it doesn't) and I want the user to see how many tiers the cake will be without looking at the GUI. I'd like the user to see reflected in the cursor somehow information on how the cake will look before clicking on the grid. So somehow being able to draw ellipses, circles, lines, arcs, etc on the cursor would be awesome.

4. Is it possible to communicate directly with a .NET dll so I can avoid dumping data to a text file then reading it back in? I'm sure that would be a lot faster.

... and finally, how much easier would all this be if I were to avoid Lscript altogether and go with Lightwave's other plugin tools? (C++ based) Isn't Lscript only an entry level plugin paradigm? And let's say I want to stick with Lscript, would it be considered robust enough to actually make money from selling this plugin? Assuming there was interest of coarse.

Let me know please and thanks.

Darrell

evenflcw
01-25-2010, 10:36 AM
No to first 3 questions. You must use the sdk meshedittool class.

LScript is robust. However it does not support all server classes and does not have as much access as the sdk. There are a couple non-trivial commercial 3rd party lscripts (Maestro, Janus etc), so it is certainly a viable option depending on what you need to do.

Matt
01-25-2010, 10:38 AM
1. Does Modeler allow an Lscript plugin to create it's own cursor graphic?

Nope

2. Can my Lscript GUI window remain open while I create points on Modeler's grid which would then show up on some display control on the Lscript GUI window? (this is why I'd like to change the cursor graphic)


Nope

3. Can I create my own drawing support graphics in Modeler that assist the user in aligning/creating points on Modelers grid? An example would be, let's say my plugin draws multi-tiered wedding cakes (which it doesn't) and I want the user to see how many tiers the cake will be without looking at the GUI. I'd like the user to see reflected in the cursor somehow information on how the cake will look before clicking on the grid. So somehow being able to draw ellipses, circles, lines, arcs, etc on the cursor would be awesome.

Yup, there are some basic drawing commands available.
http://www.mikegreen.name/Lscript/Lscript%20Index.html (Check under "Drawing Commands")

4. Is it possible to communicate directly with a .NET dll so I can avoid dumping data to a text file then reading it back in? I'm sure that would be a lot faster.

I would guess nope, but not sure.

... and finally, how much easier would all this be if I were to avoid Lscript altogether and go with Lightwave's other plugin tools? (C++ based) Isn't Lscript only an entry level plugin paradigm?

LScript although quite powerful, can't do as much as a proper plugin (.p plugins can be run as non-modal being one) and they run a lot slower too.

And let's say I want to stick with Lscript, would it be considered robust enough to actually make money from selling this plugin? Assuming there was interest of coarse.

This is just me, but if I were to buy a plugin, I kinda feel better if it's a "proper" plugin.