I've been learning mel recently (only knew some basics till now), and have a few questions for those in the know. 1. Is their a way to lock variables? I'd like to be able to make a procedure declare variables once and never again, so they dont get reset values every time a global is called. 2.How does the tokenize command…
1. you can use optionVar for that which will add the variable to maya's dedicated list of variables (where it stores your defaults for bevel, extrude, etc) 2. hmm maybe they have better ways to do it now, but tokenize is nice when you're trying to do things like split up filepaths or something like that. It's just for…
1. Yep, what Funky Bunnies said - optionVars are the way to do it. 2. I use tokenize all the time... hopefully not because I'm doing something wrong :) But for example if you want to extract the vertex index as an int from "pCube1.vtx[21]" which is a string, so tokenize it into an array with "[]" as the split characters,…
1. Not sure exactly what you want here. Why can't you just declare a global variable in one proc, and access it in all the others? There's no reason to "lock" it - the only way to change the var is to explicitly set it. If you want it to be stored across sessions (as in, literally set it ONCE only) then you can use…