PDA

View Full Version : LScript that deselects all and drops tool in one go



Boris Goreta
09-29-2009, 10:58 AM
Hi, I need to write a script that deselects all and drops the current tool. I need it because I do this sequence all the time and I want to have it both on one short cut. This is what I did so far:

@warnings
@version 2.3
@script modeler

main
{

selmode(USER);
selpoint(CLEAR);
selpolygon(CLEAR);


}


I don't know the command for dropping current tool, and current deselection code is no good because when LScript finishes modeler is always in polygon mode and I want the mode to be untouched.

Matt
09-29-2009, 11:19 AM
I remember trying to find that once, I don't think there is one.

art
09-29-2009, 11:25 AM
It finishes in polygon mode because your last command is selpolygon(CLEAR);

I'm not sure if you can detect the selection mode beforehand so that you can return to it later. Additionally, if you started in edge mode, I don't think there is a way in lscript to switch back to that mode. LScript does not support edges.
The seledge() command seems to exist, but it does not do anything.

Boris Goreta
09-29-2009, 11:26 AM
That sucks. Maybe drop tool command is some other command with an argument that does the same thing ?