GENERATE/PREV.gifGENERATE/NEXT.gif

Calling Built-In Functions

All of the MAX operations that you can access with MAXScript are made available to you as functions. You invoke them with standard function calls, there is no special syntax or mechanisms especially for the MAX built-in functions. MAX functions make up the bulk of the built-in functions in MAXScript.

Special notes about function calls:

ยท      Functions that take no arguments need to called in a special way. For example, if you wanted to call a function get_current_target that takes no arguments, you could not simply write:

t = get_current_target

because this is a variable access that simply yields the function itself, and does not call the function. Instead, you must use the '()' nullary call operator:

t = get_current_target ()

(if a > b then sin else cos) x      -- conditional function choice

handlers[x] $box01 [1,1,1]      -- get the function out of an array