Hello everyone-
I was wondering if there is a way to have the script editor in python echo the commands that you are doing like maya does. For example, if I select and delete something in Maya, it will show up in the command prompt.
Im currently starting to script in python in Maya. There are some mocap ideas I have but i was curious to see if it reacts the same. Thanks and any suggestions would be great!.
Not at this time, but the script examples that come with MotionBuilder are well done, commented and would be the best place to start to get an idea of the what and how things are being called in the GUI.
I’ve heard it said that “Maya is written in MEL,” and while that’s not strictly true in every sense, it might give you an idea of how Maya and MotionBuilder are different. In Maya, nearly every action you perform as a user is a MEL command in some form or another. When you use the Create Polygon Cube tool, the polyCube command is actually being called as a result, so Maya can happily show that to you. In MotionBuilder, however, while dragging out a cube from the Asset Browser and calling FBCube() have essentially the same effect, they are entirely separate approaches – creating a cube via the UI does not make any Python calls. The UI cuts straight to MotionBuilder’s slimy, gooey, compiled-bytecode guts, which it can’t echo to you in any helpful way.
Here is a crude and hilariously over-simplified diagram to illustrate:
On the other hand, MoBu’s API is incredibly well done compared to, say, Maya’s. You can generally figure out what you need to do (though be forewarned, you can’t do everything, but same thing in Maya).
Let me clarify- As a development platform, Maya is FAR more friendly to programming than mobu. As you said, much more of it is exposed. The problem is, Maya and MEL/Python/PyMEL still reeks from the MEL-style way of programming. It is almost impossible to program against Maya without first understanding Maya and how to do something in Maya already. On the otherhand, you can get quite far programming against MoBu because it is far more Object Oriented, named and organized better (except FBFbxSaveLoadOptions…), etc.- it is much closer to 95% of the API’s programmers work with. As opposed to Maya’s API, which is its own beast, though in the end a stronger beast than MoBu’s.
As an example, I challenge you to take a script in Maya and a script in Mobu that do the same things, and see what most programmers understand better.
[QUOTE=Rob Galanakis;15978]Let me clarify- As a development platform, Maya is FAR more friendly to programming than mobu. As you said, much more of it is exposed. The problem is, Maya and MEL/Python/PyMEL still reeks from the MEL-style way of programming. It is almost impossible to program against Maya without first understanding Maya and how to do something in Maya already. On the otherhand, you can get quite far programming against MoBu because it is far more Object Oriented, named and organized better (except FBFbxSaveLoadOptions…), etc.- it is much closer to 95% of the API’s programmers work with. As opposed to Maya’s API, which is its own beast, though in the end a stronger beast than MoBu’s.
As an example, I challenge you to take a script in Maya and a script in Mobu that do the same things, and see what most programmers understand better.[/QUOTE]