0
Answered

Problems with Transformation of Chains

Nicola Lienhöft 2 years ago in realvirtual.io Starter and Professional updated by Support 2 years ago 5

Hello,

I created a chain with chain elements and it is working fine. Now I tried to make a copy and turn it around 90°Z. Some of the chain elements are now moving in a wrong direction, but not reproduceable. Even if I create a new spline and replace all scripts, it is not working corrrectly. Shifting along the axes works, but turning is not possible.
Does someone know a trick?

Answer

Answer

Can you send us your example and we will check it.

GOOD, I'M SATISFIED
Satisfaction mark by Nicola Lienhöft 2 years ago
Answered

Sometimes the chain aligning is a little bit complicated. Sometimes we also create an emtpy GameObject on top of the CainElement to make aligning more simplle. 


Did you tried to change the Align Vector and turn on Debug Directions?

Hi, 
I tried several options... now I have a GameObjekt on top of the chain and the chain element. Copy and moving works, turning makes weird arrangements of the chain elements (left original, right copy):

If I turn on Align Vector, this happens, chain elements are not aligned to the spline anymore..

Thankful for any help!

Answer

Can you send us your example and we will check it.

+1

Hello,

when you rotate the chain, the tangents used also change. This means that you have to adjust both the parameters of the chain element and the rotation within the chain element. To change the rotation of the two elements, proceed as follows: 

Bring both elements to one level in the hierarchy. 

Rotate both elements to the correct position. 

Move the mesh element (Kettenbaustein) back under the chain element in the hierarchy.

Below you will find the settings for the chain element and the mesh element used.