I finally had some time to try this out with Motionbuilder. And it works!!
It's amazingly simple to set up. Some very quick steps:
. Get PTVS, free version here: https://pytools.codeplex.com/wikipage?title=PTVS%20Installation
. Copy C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\Extensions\Microsoft\Python Tools for Visual Studio\2.0\ptvsd somewhere to your Mobu's python path, or add it to sys.path
. Add import ptvsd and some breakpoint to your python script
. Launch Motionbuilder, on VS do Debug/Attach to Process and select motionbuilder.exe
. Open the same python script on the python editor (and this is important, drag and dropping the script on the viewport does not work) and run it.
. Motionbuilder should stop on the breakpoint and you should have all the debugging info on VS
It's a bit trickier. Basically you need to have C:\Program Files\Autodesk\MotionBuilder 2013\bin\config\Python\pyfbsdk_gen_doc.py accessible by VS. You could copy it to something like c:\Python26\Lib, but that sucks. The best option is to add it on the Search Path for the project, either from that folder or some custom one. And lastly, you need to rename it pyfbsdk.py (to be able to do import pyfbsdk, instead of pyfbsdk_gen_doc)