Using the DiscoveryInputHelper

The DiscoveryInputHelper enables you to pause the execution of the script to get various inputs from interactive tools, before continuing to run the script. You can set up custom workflows using the DiscoveryInputHelper functions, including creating widgets and tool guides for user input. The DiscoveryInputHelper can only be used in Debug mode.

Note: The InputHelper is still available for migrating from SpaceClaim scripts.
  • You can create tool guides and specify selections which can also be filtered based on type. For example, you can choose to filter faces, edges, or bodies. You can also specify if the selections are mandatory or optional.

  • Script variables can be added to a custom HUD as buttons, check boxes, dropdowns, or groups of such controls. You can also add tool tips for the controls created.

  • Quantities in the DiscoveryInputHelper allow you to specify values with relevant quantities, to be used in other objects such as physics conditions.

Example - Creating Tool Guides for Selection

This example shows how you can select a body to be moved and select edges to be rounded.

The script pauses to start the interactive tool, where you can select a body to be moved and two edges to be rounded.

When you finish selecting the entities, you can click Complete or Abort and resume the script. Abort doesn't necessarily act as you might expect, as it doesn't end the script execution. You will need to add some extra validation to stop the script (such as "if click.Success == True")

Example – Creating Quantity Inputs

This example shows how you can add multiply quantity inputs and receive a value and a unit for each. Once a value is received, it can be added to any condition that can accept that value.