Conditions Dialog
 
 
 
Command entry: Customize Ribbon dialog Highlight an element in the Existing UI list. Properties window Set Enabled, Visible, or Available property to Conditional. Click the [...] (ellipsis) button (to change conditions).

Use the Conditions dialog to set conditions for enabling ribbon elements and controls or making them visible. The full name of the dialog is Conditions For Enabled, Conditions For Visible, or Conditions for Available, depending on the Customize Ribbon dialog property from which you invoked it.

The three properties can be set to True, False, or Conditional, which returns either True or False based on the conditions. Those properties are:

If you set multiple conditions, keep in mind that when any condition for a particular state, such as the ribbon layout, is met, it causes the condition to be satisfied.

For example, the Polygon Modeling panel has two different “poly main” sub-panels available. One of the “poly main” sub-panels has its Visible property set to Conditional: Horizontal (which implies maximized) or Minimized, which applies to either horizontal or vertical.

The other sub-panel is set to Conditional: Vertical, which applies to the maximized vertical ribbon. When setting up different versions of a panel or sub-panel for different ribbon configurations, make sure the conditions for visibility don’t overlap.

However, if you set multiple conditions for different states, such as ribbon layout and active sub-object level, at least one condition in each state must be met for the condition to be satisfied.

TipYou can quickly see what the conditions are for a particular conditional control by holding the mouse over the Available or Visible setting (the Conditional button or the associated [...] button). After a brief pause, a tooltip opens that lists the conditions.
ImportantAny control set to True for Visible or Available always appears in any ribbon configuration in every state of 3ds Max.

Interface

The Conditions dialog offers a list of check boxes for choosing preset conditions for ribbon elements; you can also custom-tailor a condition using MAXScript.

Maxscript

If none of the check box options reflects a condition you want to set, and you’re familiar with MAXScript, you can create a script to specify any conditions you like.

Maxscript

Enter a short MAXScript statement or function in this field to set a condition. The statement or function must evaluate to True or False (1 or 0). If True, the condition is met; if False, the condition is not met.

To enter multiple lines after the first line, press Shift+Enter.

For longer scripts, click the Open Editor button and use the editor window to define a function in a MAXScript file, and then enter the function name in the Maxscript field. The function name as entered here must use the following format:

[if the function is defined within a struct, specify the struct name followed by “.”][function name]()

For example, you could use the function ValidSOMode to determine whether a valid sub-object level is active for the selected editable poly or Edit Poly object. This function is defined in the Ribbon_Modeling struct in the Ribbon_Modeling.ms MAXScript file, so you would enter the following in the Maxscript field:

Ribbon_Modeling.ValidSOMode()

If the function is not within a struct, you need specify only the function name followed by (). If you write a new function, be sure to evaluate the script before using the function as a condition.

Following are some examples of statements you can use in the Maxscript field to set a condition, with explanations:

  • selection.count == 1Only one object is selected in the scene. Change the numeric value to specify a different selection count.
  • selection.count > 0 AND (for o in selection where superclassof o == Light collect o).count == selection.countOne or more light objects are selected in the scene, and only light objects are selected.
  • selection.count == 1 and selection[1].isAnimatedOnly one object is selected and the object is animated.
  • selection.count == 1 and selection[1].material != undefinedOnly one object is selected and the object has a material applied.
  • animButtonStateThe state of the Auto Key button: evaluates to True or False when Auto Key is on or off, respectively.
    NoteThis statement requires a viewport selection change (for example) to be reevaluated by 3ds Max.
Open Editor

Opens a MAXScript editor window. For more information about using the editor, see the MAXScript help, available from the 3ds Max Help menu.

NoteThe script in the editor window does not define a condition. For details, see the definition of the Maxscript field, preceding.

Conditions

Action Item

Applies when a particular toggle command is active. For example, the Soft panel, which provides controls for modifying how Soft Selection works, is available only when the Use Soft Selection command is active.

When you click this item, a dialog opens that lets you choose an action item to define the condition. The dialog is organized the same way as the Action Items window on the Customize Ribbon dialog. Find the command and then double-click it to apply it to the Action Item condition. The command’s name then appears in parentheses next to “Action Item” on the dialog.

Ribbon Layout

Horizontal

Applies when the ribbon orientation is horizontal and maximized.

Vertical

Applies when the ribbon orientation is vertical and maximized.

Minimized

Applies when the ribbon is minimized.

Selection States

Typically, if you enable either of these, enable the other as well. This is the case for the Available property in most panels on the Graphite Modeling Tools, Freeform, and Selection tabs on the ribbon.

Editable Poly Selected

Applies when a single editable poly object is selected and .3ds Max is in Modify mode.

Edit Poly Selected

Applies when a single Edit Poly object (that is, an object with the Edit Poly modifier applied) is selected and .3ds Max is in Modify mode.

Selected Object States

Soft Selection Enabled

Applies when Use Soft Selection on the Polygon Modeling panel is active.

NURMS Subdivision Enabled

Applies when Use NURMS on the Edit panel is active.

Slice Mode Enabled

Applies when the Slice Plane tool on the Geometry (All) panel is active.

Tweak UVW Enabled

Applies when Tweak on the Edit panel is active.

Subdivision Displacement Enabled

Applies when Use Displacement on the Subdivision panel is active.

Sub-object Modes

Object

Applies when no sub-object level is active.

Vertex

Applies at the Vertex sub-object level of editable poly and Edit Poly objects.

Edge

Applies at the Edge sub-object level of editable poly and Edit Poly objects.

Border

Applies at the Border sub-object level of editable poly and Edit Poly objects.

Polygon

Applies at the Polygon sub-object level of editable poly and Edit Poly objects.

Element

Applies at the Element sub-object level of editable poly and Edit Poly objects.