Simply put, Logic Mode is used to make assets configurable.
Logic Mode consists of three main components. The Logic Editor, which allows for creation of Visual Attributes and Visual Rules, is used to enforce configuration requirements on an Asset. The second component is the Preview Pane, which provides the visual representation and reflects changes based on manipulation of the Visual Attributes present in the Configurator Viewer, which is the third component of the Logic Mode interface. Similar to the Asset Panel, the Logic Editor and the Configurator Viewer are collapsible to allow for a larger preview area.
The Logic Editor is an extremely versatile tool, providing the artist with the ability to automate manipulation of the Asset properties, and the properties of its corresponding Operators.
Primary uses of Logic Mode
Logic Mode is used to enforce configuration requirements by mapping Item Attributes to Visual Attributes. To see some examples, check out the guides for setting up configurable, Interactive 3D experiences.
Logic Mode can also be used to make the artist workflow more efficient. For example, exposing an attribute for manipulation on a Material Asset lays the foundation for re-using the same Asset on multiple Catalog Items. An example can be seen here.
Once the Merchandiser has laid the foundation for Configuration by establishing all Catalog Item Attributes and Rules, the 3D artist will use them as a guide to ensure visual representation adjusts with fidelity. On the 3D side, the approach is similar, there are Attributes and Rules.
Visual Attributes are containers used to control what kind of information is used by one or more rules. A Visual Attribute of type boolean might be useful to control the visibility of a mesh, while a Visual Attribute of type Asset -> Material is appropriate for controlling the mesh's Material. While one can associate any Visual Attribute Type with any Visual Rule, the appropriate choice will drastically reduce the complexity of a rule.
Item Attributes of Type: Part Reference correlate with Visual Attributes of Type: Asset
It's worth remembering that limiting Attribute values is accomplished by mapping Visual Attributes to Item Attributes and setting Item Rules on the respective record. An example of this can be seen here.
Visual Attribute Types
While Catalog Item Rules support the business logic of a configurator, Visual Rules ensure the visual representation adjusts with fidelity on the basis of attribute values.
Conditions expose all local Attributes and allow the user to commit manipulation of the visual based on specific Attribute Values. By default, when many conditions are used, AND is the logical operator.
Actions manipulate the visual representation. The following Actions are supported; set attribute visible, set attribute enabled, set attribute value, set visibility, set material, set model, and set property.
set attribute visible
Nothing tricky about this Action Type, a previously unexposed attribute will become visible.
set attribute enabled
Allows a previously unconfigurable attribute to become configurable.
set attribute value
This action allows for dynamically setting the value of any attribute specific to the Asset on which it is created.
set attribute value visibility
Makes visible an attribute value to visible based on some criteria
set attribute value enabled
Sets an attribute value base on some criteria
Leverages the client-side Player API for extremely complex or parametric configuration requirements.
Used for options that may or may not be included on a given model, this action type allows for toggling visibility.
Set material will do just that, on the basis of the Attribute Value, an appropriate material may be applied to any of a given model's meshes. A tangible example is located here.
An extremely powerful action type, set model leverages a reference point such that any model from the library can be placed within the scene.
The set property action provides the ability to automate manipulation to any of the properties in a given asset view, as well as the properties of any operator. A simple example can be seen here.
set active camera
Useful for scenes with multiple cameras. set active camera allows for setting the view to any camera in the scene on the basis of some input. Perhaps there is an area of a model which should be emphasized when a given component is being configured. Setting up multiple cameras would allow for transition between these views.