I am trying to add a custom attribute to an object in Max, but do not want it to show in the UI, just on a track. This is because I want to be able to locate an object by its custom attributes (which I also need to know), just in case (which is the case) the object gets renamed by someone else (even though they have been…
Hey guys. I'm a beginner when it comes to maxscript and scripting in general. I've been doing some small tool scripts as a learning exercise, but I'm still having trouble understanding the order in which things are initialized and called. For example, this is my current test script: ( objCollection = $* objArray =…
haiddasalami is right. Also I would move the code above the rollout into the Open block. That way if you open the rollout from another place in your code you don't have to repeat that code. But also you don't need to declare the rollout global. Rollouts are all global once created. ( rollout nameSearchBox "Name and…
My bad, I think I encased the code in () after testing. Normally I have a bunch of rollout definitions script in a plugin directory, and my macroscripts consist only of createDialogs calls.
Hey thanks for the answers guys. I tried the updated code you provided and it does work as intended, but I'm still not quite sure I understand. Let me try and talk it out and you guys tell me if I'm wrong. So the way I had it written the functions were not in global scope? If so, why was that? I thought functions would…
@monster: Hmm tried that code and get the same scope issue unless i make the rollout global. From my understanding on the scope, anything inside the macroscript definition is considered a local or separate scope from global. In regards to scope, heres some good reading from the documentation. Generally if you just google…
Since we are asking questions anyway, something I have been wondering for a while is: What is the use of using "(" at the start and ")" at the end of a maxscript file? Does it have a purpose? :icon_question: I would make the code like so: try(destroyDialog nameSearchBox)catch()objArray = selection as arrayobjList =…
Hi EMJAY1970, feel free to create a new post when you ask a question not related to the original topic. To answer your question directly, remove the rollout from your Custom Attribute and it won't show in the UI. nodeMasterID = attributes obj_Identifier( parameters mainP ( nodeID type:#node…