MEL line SelectToggleMode; not working
So I made a MEL-script, and when I made the script everything worked fine. When I later on switched to another maya scene (after saving the script), and I ran the script on a model, I noticed that it was in vertex-mode (it should end in object-mode), and did some spooky things to the model that it wasnt supposed to do.. I looked at what was going on and basicly every time i had the line "SelectToggleMode;", it'd ignore it (the line works if i run it separately). No wonder it made a mess. So now I've saved out a few diffrent parts of the script, so i'll do the SelectToggleMode; manually, and continue on with the script until it encounters another SelectToggleMode;. Which is annoying. I'd like it to work, but I really have no idea why this particilar line wouldn't work for me. Its kind of annoying. Do any of you know a sulotion to this? A line that does the same function maybe? I dont really have time to investigate more on this, since im going to use this script on all my models for the project im in (the script creates 1 group with a high-poly version, a cage-version and the original model, aswell as another group with the exploded high-poly&cage&LP). Itd be easier to get the script working in 1 click instead of having to go through 6 clicks every time i want to do this operation
You can try it out yourself if you want. Just select an object and run the script Code:
//1st in group = Low-poly |
I ran into problems sooner than that. "TransformAlongNormal" can't be found and throws an error. Just by looking, I can see some issues. The use of variables would make this a lot easier and flexible. It would basically eliminate the need to constantly pickwalk in order to act on objects.
Then there are lines like these: Code:
SelectToggleMode; Code:
DeleteHistory; Code:
PolySelectConvert 3; Code:
PolySelectConvert 3; |
All times are GMT. The time now is 11:38 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Simply Maya 2018