# Kinematic

Very often when importing 3D parts from external sources like CAD systems the 3D data is not structured in a kinematic manner.\
The realvirtual.io kinematic is based on the hierarchy of Gameobjects. This means, that the hierarchy defines also the kinematic chain.\
For creating a kinematic chain there are multiple ways. You could restructure the Gameobject hierarchy manually in realvirtual.io or the CAD system before exporting to Unity. But normally, it is better to leave the imported structure as it is. This facilitates the update workflow, if you reimport the 3D data again, in the case of design changes.

The Kinematic component is for restructuring the Kinematic chain and for repositioning objects without manually changing the imported 3D data (and without changing the structure of the data in the CAD system).

In this Youtube tutorial you can get an insight about defining Kinematics with realvirtual.io:\


{% embed url="https://youtu.be/u80SeJKJP1Q" %}
Tutorial CAD independent Kinematic definition
{% endembed %}

The Kinematic component offers these 4 functions. All functions are started on simulation start:\
**Repositioning and aligning the origin** to another Gameobject origin. This will also move the children of the Kinematic component.

**Move the pivot center** and keep the position of the child Gameobjects for defining a rotation point.

**Integrate parts from a defined Group** into this Kinematic component.

**Define a Kinematic parent** to move the Kinematic Gameobject and its children underneath another GameObject.

<div align="left"><figure><img src="https://260262196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpYxFg97YnJX96UzNNTSd%2Fuploads%2Fbu70VI6cX5OreshpyZ8M%2Fkinematic.png?alt=media&#x26;token=4113a3a3-6c00-4147-8b57-13b6891e814a" alt=""><figcaption></figcaption></figure></div>

### Gizmo <a href="#gizmo" id="gizmo"></a>

In large CAD designs you work very often with a lot of Kinematic Groups based on the function _Integrate Group_. Because usually the Gameobjects with the _Kinematic_ script attached to it are empty you can enable _Show Group Gizmo_. This will highlight all the meshes which are part of the defined group like shown in this picture.

<figure><img src="https://260262196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpYxFg97YnJX96UzNNTSd%2Fuploads%2FK8KWl1wBkWLMr3QvRa5y%2Fkinematic-gizmo.png?alt=media&#x26;token=9f7cbb20-e034-41ff-815a-db652a0d2edb" alt=""><figcaption></figcaption></figure>

### Reposition <a href="#reposition" id="reposition"></a>

A part might be not placed on simulation start as it should. You can reposition any GameObject if you select this option. You need to assign another reference GameObject where this part will be placed to. The Pivot origins of the part will be aligned to the defined Gameobjects pivot. The operation will be performed uppon simulation start.

### Move Center

You can move the center of a part without moving the positions of the underlying parts itself. To do this you can define a vector (in millimeters) and a rotation (in the local coordinate system) where the center of the part should be moved to. The operation will be performed uppon simulation start.

### Integrate Group

You can integrate a group into this kinematic part. To do this you need to assign the Group script to any other GameObject and give the group a name. Integrate Group will move all parts with the defined group underneath this kinematic part on the simulation start.

This is the most important function. With this method you can define CAD design structure independent Kinematic groups in parallel to the imported CAD data. For the reuse of components you can assign in _Group Name Prefix_ a part whose name is used as prefix of the group name. Please check for example the Demo model _Assets/game4automation/Scenes/DemoGripping_ for an example how to use this function.

### New Kinematic Parent

With New Kinematic Parent, you are moving this part underneath another part upon simulation start.



© 2025 realvirtual GmbH [https://realvirtual.io](https://realvirtual.io/) - All rights reserved. No part of this publication may be reproduced, distributed, or transmitted in any form or by any means, including printing, saving, photocopying, recording, or other electronic or mechanical methods, without the prior written permission of the publisher.
