title: How to get arguments list for a MAXScript function
body: <p>A quote from Autodesk 3DS MAX documentation:</p>
  
  <blockquote>
    <p>When you use something like 'fn test val = ...", a MAXScriptFunction
    value is created and stored in variable test. If variable test was
    passed into another method, for example as a filter function, that
    method would test the class of the value to make sure it's a
    MAXScriptFunction and then call it using apply().</p>
  </blockquote>
  
  <p><strong>My question:</strong> The functions in 3DS MAX are stored in variables, like any other values. You can store them in arrays, pass them to other functions, do what ever you do with any other value. So the question is: is there any way to get the list of arguments the function expects, from the function variable? </p>
  
  <p>Here goes a small exlplanation, to explain why I'm asking this question. </p>
  
  <p>Let's say I have a large functions library, stored in structs. For example, one of those structs is called "ModelingTools"</p>
  
  <pre><code>Struct ModelingTools
  (
      fn tool1 arg1 agr2 arg3 = (...),
      fn tool2 arg1 agr2 arg3 = (...),
      ...
  )
  
  ModelingTools = ModelingTools() --make an istance of the struct in global scope
  </code></pre>
  
  <p>And then I want to use those functions in other scripts. I write this:</p>
  
  <pre><code>ModelingTools.tool1 arg1 arg2 arg3 
  </code></pre>
  
  <p>And what if there are already tonns of those structs and tonns of functions inside them? The build-in editor doesn't have any autocomplete like Visual Studio or QT. So I decided to invent my own bicycle. Gladly, MAXScript has a build-in method to list all registered global values in MAX: globalVars.gather(). For structs defenitions it event prints all their members. I'm almost happy with this: now I can quick search throug all registered MAX structs, click on one of them in a list view and list all their member functions, quickly copy-paste the desired function call to my code. </p>
  
  <p>The only problem is with the arguments. How do I know whitch arguments do I need to provide to a specific function? </p>