hi there, I'm currently working on a project in which I'm animating a clock work shop, I already have all the clocks working I used the expression editor for this, but now I need to make a controller or an attribute in which it can let me Start or Stop the clock animation whenever I want.
great tutorial, thanks! Do you know of a good list of some of the basic mel expressions with examples showing how they can be used? I know they are all listed in the maya help document, but that can be a bit overwhelming to a rookie like me. Thanks again! :)
Unfortunately, all I use is the Maya Help. But what I would recommend is actually learning the different types so you can understand the commands. For example, by every command there is a C Q E or M. To use them, they each are slightly different.
C is Create. It's the most straight forward. When you write a command, you generally create it.
Q is Query. This can only be done when the object is created. Gets info
E is Edit. This can only be done when the object is created. Edits.
M isn't used very often unless you do some more advanced stuff. But allows the passing of multiple arguments.
Most of the examples in the Maya help are Creation based and not Query or Edit based. I do wish to create some mild scripting tutorials in the future demonstrating how to read the code.
So yeah.... I had some free time and made two videos to help you. Youtube comments disallow links, but check out my channel page and find "How to code in PyMel(Python) for Beginners (Part 1)" or do a search.
Thank you so much this is just the thing I needed. You explained so it was very easy to understand using the mx+b format. Keep up the good work. Again thanks
hi there, I'm currently working on a project in which I'm animating a clock work shop, I already have all the clocks working I used the expression editor for this, but now I need to make a controller or an attribute in which it can let me Start or Stop the clock animation whenever I want.
Any ideas?
MrNahun88 3 months ago
@MrNahun88 This type of code is largely dependent upon the name of your clock hands and groups.
Essentially you want to have an IF statement that says, IF attribute set == 1, then rotate clock hand/group == timeSlider query command.
If you have some offsets, you can add a (+ *offset number here*) to the end.
ctstealth 3 months ago
great tutorial, thanks! Do you know of a good list of some of the basic mel expressions with examples showing how they can be used? I know they are all listed in the maya help document, but that can be a bit overwhelming to a rookie like me. Thanks again! :)
cgstudent1 4 months ago
@cgstudent1
Unfortunately, all I use is the Maya Help. But what I would recommend is actually learning the different types so you can understand the commands. For example, by every command there is a C Q E or M. To use them, they each are slightly different.
C is Create. It's the most straight forward. When you write a command, you generally create it.
Q is Query. This can only be done when the object is created. Gets info
E is Edit. This can only be done when the object is created. Edits.
ctstealth 4 months ago
M isn't used very often unless you do some more advanced stuff. But allows the passing of multiple arguments.
Most of the examples in the Maya help are Creation based and not Query or Edit based. I do wish to create some mild scripting tutorials in the future demonstrating how to read the code.
ctstealth 4 months ago
@cgstudent1
So yeah.... I had some free time and made two videos to help you. Youtube comments disallow links, but check out my channel page and find "How to code in PyMel(Python) for Beginners (Part 1)" or do a search.
Hope that helps!
ctstealth 4 months ago
Very useful, thank you!
tencelribeiro 11 months ago
Thank you so much this is just the thing I needed. You explained so it was very easy to understand using the mx+b format. Keep up the good work. Again thanks
SinjinTreharne 1 year ago
thank you very much
jasamadam 1 year ago
thanks
80amnesia 1 year ago