*ME_ModuleOccurrenceClone

Create a module as a copy of another. Module contents are copied unless specified otherwise.

Syntax

*ME_ModuleOccurrenceClone me_id ?options?

Type

HyperMesh Tcl Modify Command

Description

Create a module as a copy of another. Module contents are copied unless specified otherwise.

Inputs

me_id
The ID of the part or part assembly to clone.
options (optional)
List of input options, passed as a comma separated string enclosed in quotes. Valid options are:
copy_contents=<value>
0 - Do not copy contents.
1 - Default. Copy contents.
matrix=<values>
A list of 16 doubles that describe the 4x4 relative transformation matrix.
name=<value>
The name of the new module. If not specified, the new module will get a default name <orignal name>.i.<number of instances of the same prototype>.

Examples

Create a copy of module 3 with a default name and without copying the contents:

*ME_ModuleOccurrenceClone 3 "copy_contents=0"

Create a copy of module 3 named "MyClone" copying all contents, and specifiying a unit transformation matrix:

*ME_ModuleOccurrenceClone 3 "name=MyClone, copy_contents=1, matrix=1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1"

Errors

Incorrect usage results in a Tcl error. To detect errors, you can use the catch command:
if { [ catch {command_name...} ] } {
   # Handle error
}

Version History

2019