artbycrunk / vscode-maya

A Visual Studio Code extension with support for coding for Maya.
MIT License
43 stars 9 forks source link

Output from Maya in VSCODE and debug capabilities #24

Closed leonardpin-br closed 3 years ago

leonardpin-br commented 3 years ago

First, I want you to know that I like this extension a lot. I have 2 questions:

  1. Is it possible to see the output from Maya inside VSCODE?
  2. Is there any plan to add MEL debugging capabilities to this extension?

I created a file named userSetup.mel in folder C:\Users\<username>\Documents\maya\2020\scripts\ containing commandPort -name "localhost:7001" -sourceType "mel" -echoOutput; commandPort -name "localhost:7001" -sourceType "python" -echoOutput; but I can't see the output inside VSCODE.

Also, it would be GREAT to be able to debug MEL scripts.

Thank you.

artbycrunk commented 3 years ago

Hi @leonardpin-br

Thank you for your kind words.

  1. Yes it's possible to see the output inside vscode`s output window under Maya. ( as the following image)

  2. Currently no plans to allow debugging MEL code ( this would be a significant effort). That being said this extension is open-sourced so new features can be added by anyone interested :)

As for your userSetup.mel, if you're using an extension version higher than 0.9, then MEL and Python code uses the same port in Maya. so you only need one commandPort open.

commandPort -name "localhost:7001" -sourceType "mel" -echoOutput;

leonardpin-br commented 3 years ago

Thank you!